Commit 307edcca authored by Stefan Leichter's avatar Stefan Leichter Committed by Alexandre Julliard

Moved stub of StopWatch from ascii to unicode.

parent d5a31871
......@@ -38,6 +38,7 @@
#include "wingdi.h"
#include "winuser.h"
#include "winreg.h"
#include "winternl.h"
#define NO_SHLWAPI_STREAM
#include "shlwapi.h"
#include "wine/debug.h"
......@@ -81,9 +82,8 @@ void WINAPI StopWatchFlush()
FIXME("() stub!\n");
}
/*************************************************************************
* @ [SHLWAPI.243]
* @ [SHLWAPI.244]
*
* Write a performance event to a log file
*
......@@ -98,28 +98,31 @@ void WINAPI StopWatchFlush()
* Success: ERROR_SUCCESS.
* Failure: A standard Win32 error code indicating the failure.
*/
DWORD WINAPI StopWatchA(DWORD dwClass, LPCSTR lpszStr, DWORD dwUnknown,
DWORD WINAPI StopWatchW(DWORD dwClass, LPCWSTR lpszStr, DWORD dwUnknown,
DWORD dwMode, DWORD dwTimeStamp)
{
FIXME("(%ld,%s,%ld,%ld,%ld) stub!\n", dwClass, debugstr_a(lpszStr),
FIXME("(%ld,%s,%ld,%ld,%ld) stub!\n", dwClass, debugstr_w(lpszStr),
dwUnknown, dwMode, dwTimeStamp);
return ERROR_SUCCESS;
}
/*************************************************************************
* @ [SHLWAPI.244]
* @ [SHLWAPI.243]
*
* See StopWatchA.
* See StopWatchW.
*/
DWORD WINAPI StopWatchW(DWORD dwClass, LPCWSTR lpszStr, DWORD dwUnknown,
DWORD WINAPI StopWatchA(DWORD dwClass, LPCSTR lpszStr, DWORD dwUnknown,
DWORD dwMode, DWORD dwTimeStamp)
{
char szBuff[MAX_PATH];
{ DWORD retval;
UNICODE_STRING szStrW;
if(lpszStr) RtlCreateUnicodeStringFromAsciiz(&szStrW, lpszStr);
else szStrW.Buffer = NULL;
if(!WideCharToMultiByte(0, 0, lpszStr, -1, szBuff, MAX_PATH, 0, 0))
return ERROR_NOT_ENOUGH_MEMORY;
retval = StopWatchW(dwClass, szStrW.Buffer, dwUnknown, dwMode, dwTimeStamp);
return StopWatchA(dwClass, szBuff, dwUnknown, dwMode, dwTimeStamp);
RtlFreeUnicodeString(&szStrW);
return retval;
}
/*************************************************************************
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment