Module: wine Branch: master Commit: af8228f02a6cc3b05028f29a8f2621f847e85f7c URL: http://source.winehq.org/git/wine.git/?a=commit;h=af8228f02a6cc3b05028f29a8f...
Author: Huw Davies huw@codeweavers.com Date: Wed Jun 13 16:29:26 2012 +0100
localspl: Remove a bunch of casts.
---
dlls/localspl/provider.c | 11 ++++++----- 1 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/dlls/localspl/provider.c b/dlls/localspl/provider.c index a599113..4a6e2d2 100644 --- a/dlls/localspl/provider.c +++ b/dlls/localspl/provider.c @@ -1059,6 +1059,7 @@ static BOOL WINAPI fpGetPrinterDriverDirectory(LPWSTR pName, LPWSTR pEnvironment { DWORD needed; const printenv_t * env; + WCHAR * const dir = (WCHAR *)pDriverDirectory;
TRACE("(%s, %s, %d, %p, %d, %p)\n", debugstr_w(pName), debugstr_w(pEnvironment), Level, pDriverDirectory, cbBuf, pcbNeeded); @@ -1087,18 +1088,18 @@ static BOOL WINAPI fpGetPrinterDriverDirectory(LPWSTR pName, LPWSTR pEnvironment return FALSE; }
- if (pDriverDirectory == NULL) { + if (dir == NULL) { /* ERROR_INVALID_USER_BUFFER is NT, ERROR_INVALID_PARAMETER is win9x */ SetLastError(ERROR_INVALID_USER_BUFFER); return FALSE; }
- GetSystemDirectoryW((LPWSTR) pDriverDirectory, cbBuf/sizeof(WCHAR)); + GetSystemDirectoryW( dir, cbBuf / sizeof(WCHAR) ); /* add the Subdirectories */ - lstrcatW((LPWSTR) pDriverDirectory, spooldriversW); - lstrcatW((LPWSTR) pDriverDirectory, env->subdir); + lstrcatW( dir, spooldriversW ); + lstrcatW( dir, env->subdir );
- TRACE("=> %s\n", debugstr_w((LPWSTR) pDriverDirectory)); + TRACE( "=> %s\n", debugstr_w( dir ) ); return TRUE; }