switch (dwInfoLevel)
{
case SERVICE_CONFIG_DESCRIPTION:
- Info.psd = (LPSERVICE_DESCRIPTIONW)&lpInfo;
+ Info.psd = (LPSERVICE_DESCRIPTIONW)lpInfo;
break;
case SERVICE_CONFIG_FAILURE_ACTIONS:
- Info.psfa = (LPSERVICE_FAILURE_ACTIONSW)&lpInfo;
+ Info.psfa = (LPSERVICE_FAILURE_ACTIONSW)lpInfo;
break;
default:
DWORD dwError;
DWORD dwDependenciesLength = 0;
DWORD dwLength;
- LPSTR lpStr;
+ LPCSTR lpStr;
TRACE("ChangeServiceConfigA() called\n");
/* Calculate the Dependencies length*/
if (lpDependencies != NULL)
{
- lpStr = (LPSTR)lpDependencies;
+ lpStr = lpDependencies;
while (*lpStr)
{
dwLength = strlen(lpStr) + 1;
DWORD dwError;
DWORD dwDependenciesLength = 0;
DWORD dwLength;
- LPWSTR lpStr;
+ LPCWSTR lpStr;
TRACE("ChangeServiceConfigW() called\n");
/* Calculate the Dependencies length*/
if (lpDependencies != NULL)
{
- lpStr = (LPWSTR)lpDependencies;
+ lpStr = lpDependencies;
while (*lpStr)
{
dwLength = wcslen(lpStr) + 1;
DWORD dwDependenciesLength = 0;
DWORD dwError;
DWORD dwLength;
- LPSTR lpStr;
+ LPCSTR lpStr;
TRACE("CreateServiceA() called\n");
- TRACE("%p %s %s\n", hSCManager,
+ TRACE("%p %s %s\n", hSCManager,
lpServiceName, lpDisplayName);
if (!hSCManager)
return NULL;
}
- /* Calculate the Dependencies length*/
+ /* Calculate the Dependencies length */
if (lpDependencies != NULL)
{
- lpStr = (LPSTR)lpDependencies;
+ lpStr = lpDependencies;
while (*lpStr)
{
dwLength = strlen(lpStr) + 1;
DWORD dwDependenciesLength = 0;
DWORD dwError;
DWORD dwLength;
- LPWSTR lpStr;
+ LPCWSTR lpStr;
TRACE("CreateServiceW() called\n");
- TRACE("%p %S %S\n", hSCManager,
+ TRACE("%p %S %S\n", hSCManager,
lpServiceName, lpDisplayName);
if (!hSCManager)
return NULL;
}
- /* Calculate the Dependencies length*/
+ /* Calculate the Dependencies length */
if (lpDependencies != NULL)
{
- lpStr = (LPWSTR)lpDependencies;
+ lpStr = lpDependencies;
while (*lpStr)
{
dwLength = wcslen(lpStr) + 1;
if (lpPtr->lpDescription != NULL)
lpPtr->lpDescription =
- (LPSTR)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpDescription);
+ (LPSTR)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpDescription);
}
break;
if (lpPtr->lpRebootMsg != NULL)
lpPtr->lpRebootMsg =
- (LPSTR)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpRebootMsg);
+ (LPSTR)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpRebootMsg);
if (lpPtr->lpCommand != NULL)
lpPtr->lpCommand =
- (LPSTR)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpCommand);
+ (LPSTR)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpCommand);
if (lpPtr->lpsaActions != NULL)
lpPtr->lpsaActions =
- (SC_ACTION*)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpsaActions);
+ (LPSC_ACTION)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpsaActions);
}
break;
}
if (lpPtr->lpDescription != NULL)
lpPtr->lpDescription =
- (LPWSTR)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpDescription);
+ (LPWSTR)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpDescription);
}
break;
if (lpPtr->lpRebootMsg != NULL)
lpPtr->lpRebootMsg =
- (LPWSTR)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpRebootMsg);
+ (LPWSTR)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpRebootMsg);
if (lpPtr->lpCommand != NULL)
lpPtr->lpCommand =
- (LPWSTR)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpCommand);
+ (LPWSTR)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpCommand);
if (lpPtr->lpsaActions != NULL)
lpPtr->lpsaActions =
- (SC_ACTION*)((UINT_PTR)lpPtr + (UINT_PTR)lpPtr->lpsaActions);
+ (LPSC_ACTION)((ULONG_PTR)lpPtr + (ULONG_PTR)lpPtr->lpsaActions);
}
break;
}
if (lpStatusPtr->lpLockOwner != NULL)
{
lpStatusPtr->lpLockOwner =
- (LPSTR)((UINT_PTR)lpStatusPtr + (UINT_PTR)lpStatusPtr->lpLockOwner);
+ (LPSTR)((ULONG_PTR)lpStatusPtr + (ULONG_PTR)lpStatusPtr->lpLockOwner);
}
TRACE("QueryServiceLockStatusA() done\n");
if (lpStatusPtr->lpLockOwner != NULL)
{
lpStatusPtr->lpLockOwner =
- (LPWSTR)((UINT_PTR)lpStatusPtr + (UINT_PTR)lpStatusPtr->lpLockOwner);
+ (LPWSTR)((ULONG_PTR)lpStatusPtr + (ULONG_PTR)lpStatusPtr->lpLockOwner);
}
TRACE("QueryServiceLockStatusW() done\n");