Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
50ce0844
Commit
50ce0844
authored
Apr 23, 2004
by
Jon Griffiths
Committed by
Alexandre Julliard
Apr 23, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Documentation fixes.
parent
61daaf8b
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
89 additions
and
79 deletions
+89
-79
registry.c
dlls/advapi32/registry.c
+0
-0
security.c
dlls/advapi32/security.c
+2
-2
service.c
dlls/advapi32/service.c
+87
-77
No files found.
dlls/advapi32/registry.c
View file @
50ce0844
This diff is collapsed.
Click to expand it.
dlls/advapi32/security.c
View file @
50ce0844
...
@@ -903,10 +903,10 @@ LookupPrivilegeValueW( LPCWSTR lpSystemName, LPCWSTR lpName, PLUID lpLuid )
...
@@ -903,10 +903,10 @@ LookupPrivilegeValueW( LPCWSTR lpSystemName, LPCWSTR lpName, PLUID lpLuid )
* PARAMS
* PARAMS
* lpSystemName [I] Name of the system
* lpSystemName [I] Name of the system
* lpName [I] Name of the privilege
* lpName [I] Name of the privilege
*
pLuid
[O] Destination for the resulting LUID
*
lpLuid
[O] Destination for the resulting LUID
*
*
* RETURNS
* RETURNS
* Success: TRUE. pLuid contains the requested LUID.
* Success: TRUE.
l
pLuid contains the requested LUID.
* Failure: FALSE.
* Failure: FALSE.
*/
*/
BOOL
WINAPI
BOOL
WINAPI
...
...
dlls/advapi32/service.c
View file @
50ce0844
...
@@ -240,10 +240,20 @@ SetServiceStatus( SERVICE_STATUS_HANDLE hService, LPSERVICE_STATUS lpStatus )
...
@@ -240,10 +240,20 @@ SetServiceStatus( SERVICE_STATUS_HANDLE hService, LPSERVICE_STATUS lpStatus )
/******************************************************************************
/******************************************************************************
* OpenSCManagerA [ADVAPI32.@]
* OpenSCManagerA [ADVAPI32.@]
*
* Establish a connection to the service control manager and open its database.
*
* PARAMS
* lpMachineName [I] Pointer to machine name string
* lpDatabaseName [I] Pointer to database name string
* dwDesiredAccess [I] Type of access
*
* RETURNS
* Success: A Handle to the service control manager database
* Failure: NULL
*/
*/
SC_HANDLE
WINAPI
SC_HANDLE
WINAPI
OpenSCManagerA
(
LPCSTR
lpMachineName
,
LPCSTR
lpDatabaseName
,
OpenSCManagerA
(
LPCSTR
lpMachineName
,
LPCSTR
lpDatabaseName
,
DWORD
dwDesiredAccess
)
DWORD
dwDesiredAccess
)
{
{
UNICODE_STRING
lpMachineNameW
;
UNICODE_STRING
lpMachineNameW
;
UNICODE_STRING
lpDatabaseNameW
;
UNICODE_STRING
lpDatabaseNameW
;
...
@@ -259,23 +269,11 @@ OpenSCManagerA( LPCSTR lpMachineName, LPCSTR lpDatabaseName,
...
@@ -259,23 +269,11 @@ OpenSCManagerA( LPCSTR lpMachineName, LPCSTR lpDatabaseName,
/******************************************************************************
/******************************************************************************
* OpenSCManagerW [ADVAPI32.@]
* OpenSCManagerW [ADVAPI32.@]
* Establishes a connection to the service control manager and opens database
*
* NOTES
* This should return a SC_HANDLE
*
* PARAMS
* lpMachineName [I] Pointer to machine name string
* lpDatabaseName [I] Pointer to database name string
* dwDesiredAccess [I] Type of access
*
*
* RETURNS
* See OpenSCManagerA.
* Success: Handle to service control manager database
* Failure: NULL
*/
*/
SC_HANDLE
WINAPI
SC_HANDLE
WINAPI
OpenSCManagerW
(
LPCWSTR
lpMachineName
,
LPCWSTR
lpDatabaseName
,
OpenSCManagerW
(
LPCWSTR
lpMachineName
,
LPCWSTR
lpDatabaseName
,
DWORD
dwDesiredAccess
)
DWORD
dwDesiredAccess
)
{
{
HKEY
hReg
,
hKey
=
NULL
;
HKEY
hReg
,
hKey
=
NULL
;
LONG
r
;
LONG
r
;
...
@@ -319,18 +317,20 @@ AllocateLocallyUniqueId( PLUID lpluid )
...
@@ -319,18 +317,20 @@ AllocateLocallyUniqueId( PLUID lpluid )
/******************************************************************************
/******************************************************************************
* ControlService [ADVAPI32.@]
* ControlService [ADVAPI32.@]
* Sends a control code to a Win32-based service.
*
* Send a control code to a service.
*
*
* PARAMS
* PARAMS
* hService [
]
* hService [
I] Handle of the service control manager database
* dwControl [
]
* dwControl [
I] Control code to send (SERVICE_CONTROL_* flags from "winsvc.h")
* lpServiceStatus [
]
* lpServiceStatus [
O] Destination for the status of the service, if available
*
*
* RETURNS STD
* RETURNS
* Success: TRUE.
* Failure: FALSE.
*/
*/
BOOL
WINAPI
BOOL
WINAPI
ControlService
(
SC_HANDLE
hService
,
DWORD
dwControl
,
ControlService
(
SC_HANDLE
hService
,
DWORD
dwControl
,
LPSERVICE_STATUS
lpServiceStatus
)
LPSERVICE_STATUS
lpServiceStatus
)
{
{
FIXME
(
"(%p,%ld,%p): stub
\n
"
,
hService
,
dwControl
,
lpServiceStatus
);
FIXME
(
"(%p,%ld,%p): stub
\n
"
,
hService
,
dwControl
,
lpServiceStatus
);
return
TRUE
;
return
TRUE
;
...
@@ -339,12 +339,15 @@ ControlService( SC_HANDLE hService, DWORD dwControl,
...
@@ -339,12 +339,15 @@ ControlService( SC_HANDLE hService, DWORD dwControl,
/******************************************************************************
/******************************************************************************
* CloseServiceHandle [ADVAPI32.@]
* CloseServiceHandle [ADVAPI32.@]
* Close handle to service or service control manager
*
* Close a handle to a service or the service control manager database.
*
*
* PARAMS
* PARAMS
* hSCObject [I] Handle to service or service control manager database
* hSCObject [I] Handle to service or service control manager database
*
*
* RETURNS STD
* RETURNS
* Success: TRUE
* Failure: FALSE
*/
*/
BOOL
WINAPI
BOOL
WINAPI
CloseServiceHandle
(
SC_HANDLE
hSCObject
)
CloseServiceHandle
(
SC_HANDLE
hSCObject
)
...
@@ -359,10 +362,20 @@ CloseServiceHandle( SC_HANDLE hSCObject )
...
@@ -359,10 +362,20 @@ CloseServiceHandle( SC_HANDLE hSCObject )
/******************************************************************************
/******************************************************************************
* OpenServiceA [ADVAPI32.@]
* OpenServiceA [ADVAPI32.@]
*
* Open a handle to a service.
*
* PARAMS
* hSCManager [I] Handle of the service control manager database
* lpServiceName [I] Name of the service to open
* dwDesiredAccess [I] Access required to the service
*
* RETURNS
* Success: Handle to the service
* Failure: NULL
*/
*/
SC_HANDLE
WINAPI
SC_HANDLE
WINAPI
OpenServiceA
(
SC_HANDLE
hSCManager
,
LPCSTR
lpServiceName
,
OpenServiceA
(
SC_HANDLE
hSCManager
,
LPCSTR
lpServiceName
,
DWORD
dwDesiredAccess
)
DWORD
dwDesiredAccess
)
{
{
UNICODE_STRING
lpServiceNameW
;
UNICODE_STRING
lpServiceNameW
;
SC_HANDLE
ret
;
SC_HANDLE
ret
;
...
@@ -379,20 +392,11 @@ OpenServiceA( SC_HANDLE hSCManager, LPCSTR lpServiceName,
...
@@ -379,20 +392,11 @@ OpenServiceA( SC_HANDLE hSCManager, LPCSTR lpServiceName,
/******************************************************************************
/******************************************************************************
* OpenServiceW [ADVAPI32.@]
* OpenServiceW [ADVAPI32.@]
* Opens a handle to an existing service
*
* PARAMS
* hSCManager []
* lpServiceName []
* dwDesiredAccess []
*
*
* RETURNS
* See OpenServiceA.
* Success: Handle to the service
* Failure: NULL
*/
*/
SC_HANDLE
WINAPI
SC_HANDLE
WINAPI
OpenServiceW
(
SC_HANDLE
hSCManager
,
LPCWSTR
lpServiceName
,
OpenServiceW
(
SC_HANDLE
hSCManager
,
LPCWSTR
lpServiceName
,
DWORD
dwDesiredAccess
)
DWORD
dwDesiredAccess
)
{
{
HKEY
hKey
;
HKEY
hKey
;
long
r
;
long
r
;
...
@@ -593,14 +597,16 @@ CreateServiceA( SC_HANDLE hSCManager, LPCSTR lpServiceName,
...
@@ -593,14 +597,16 @@ CreateServiceA( SC_HANDLE hSCManager, LPCSTR lpServiceName,
/******************************************************************************
/******************************************************************************
* DeleteService [ADVAPI32.@]
* DeleteService [ADVAPI32.@]
*
*
* PARAMS
* Delete a service from the service control manager database.
* hService [I] Handle to service
*
*
* RETURNS STD
* PARAMS
* hService [I] Handle of the service to delete
*
*
* RETURNS
* Success: TRUE
* Failure: FALSE
*/
*/
BOOL
WINAPI
BOOL
WINAPI
DeleteService
(
SC_HANDLE
hService
)
DeleteService
(
SC_HANDLE
hService
)
{
{
WCHAR
valname
[
MAX_PATH
+
1
];
WCHAR
valname
[
MAX_PATH
+
1
];
INT
index
=
0
;
INT
index
=
0
;
...
@@ -667,6 +673,25 @@ DeleteService( SC_HANDLE hService )
...
@@ -667,6 +673,25 @@ DeleteService( SC_HANDLE hService )
/******************************************************************************
/******************************************************************************
* StartServiceA [ADVAPI32.@]
* StartServiceA [ADVAPI32.@]
*
*
* Start a service
*
* PARAMS
* hService [I] Handle of service
* dwNumServiceArgs [I] Number of arguments
* lpServiceArgVectors [I] Address of array of argument strings
*
* NOTES
* - NT implements this function using an obscure RPC call.
* - You might need to do a "setenv SystemRoot \\WINNT" in your .cshrc
* to get things like "%SystemRoot%\\System32\\service.exe" to load.
* - This will only work for shared address space. How should the service
* args be transferred when address spaces are separated?
* - Can only start one service at a time.
* - Has no concept of privilege.
*
* RETURNS
* Success: TRUE.
* Failure: FALSE
*/
*/
BOOL
WINAPI
BOOL
WINAPI
StartServiceA
(
SC_HANDLE
hService
,
DWORD
dwNumServiceArgs
,
StartServiceA
(
SC_HANDLE
hService
,
DWORD
dwNumServiceArgs
,
...
@@ -705,29 +730,8 @@ StartServiceA( SC_HANDLE hService, DWORD dwNumServiceArgs,
...
@@ -705,29 +730,8 @@ StartServiceA( SC_HANDLE hService, DWORD dwNumServiceArgs,
/******************************************************************************
/******************************************************************************
* StartServiceW [ADVAPI32.@]
* StartServiceW [ADVAPI32.@]
* Starts a service
*
*
* See StartServiceA.
* PARAMS
* hService [I] Handle of service
* dwNumServiceArgs [I] Number of arguments
* lpServiceArgVectors [I] Address of array of argument string pointers
*
* NOTES
*
* NT implements this function using an obscure RPC call...
*
* Might need to do a "setenv SystemRoot \\WINNT" in your .cshrc
* to get things like %SystemRoot%\\System32\\service.exe to load.
*
* Will only work for shared address space. How should the service
* args be transferred when address spaces are separated?
*
* Can only start one service at a time.
*
* Has no concept of privilege.
*
* RETURNS STD
*
*/
*/
BOOL
WINAPI
BOOL
WINAPI
StartServiceW
(
SC_HANDLE
hService
,
DWORD
dwNumServiceArgs
,
StartServiceW
(
SC_HANDLE
hService
,
DWORD
dwNumServiceArgs
,
...
@@ -857,13 +861,19 @@ QueryServiceStatus( SC_HANDLE hService, LPSERVICE_STATUS lpservicestatus )
...
@@ -857,13 +861,19 @@ QueryServiceStatus( SC_HANDLE hService, LPSERVICE_STATUS lpservicestatus )
/******************************************************************************
/******************************************************************************
* QueryServiceStatusEx [ADVAPI32.@]
* QueryServiceStatusEx [ADVAPI32.@]
*
*
* Get information about a service.
*
* PARAMS
* PARAMS
* hService [handle to service]
* hService [I] Handle to service to get information about
* InfoLevel [information level]
* InfoLevel [I] Level of information to get
* lpBuffer [buffer]
* lpBuffer [O] Destination for requested information
* cbBufSize [size of buffer]
* cbBufSize [I] Size of lpBuffer in bytes
* pcbBytesNeeded [bytes needed]
* pcbBytesNeeded [O] Destination for number of bytes needed, if cbBufSize is too small
*/
*
* RETURNS
* Success: TRUE
* FAILURE: FALSE
*/
BOOL
WINAPI
QueryServiceStatusEx
(
SC_HANDLE
hService
,
SC_STATUS_TYPE
InfoLevel
,
BOOL
WINAPI
QueryServiceStatusEx
(
SC_HANDLE
hService
,
SC_STATUS_TYPE
InfoLevel
,
LPBYTE
lpBuffer
,
DWORD
cbBufSize
,
LPBYTE
lpBuffer
,
DWORD
cbBufSize
,
LPDWORD
pcbBytesNeeded
)
LPDWORD
pcbBytesNeeded
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment