Fixed Unicode conversion in GetAtomNameA (thanks to Gerard Patel).

This commit is contained in:
Alexandre Julliard 2000-09-04 20:21:48 +00:00
parent 6e740b5b46
commit 942dcb1df6
1 changed files with 2 additions and 1 deletions

View File

@ -690,7 +690,8 @@ static UINT ATOM_GetAtomNameA( ATOM atom, LPSTR buffer, INT count, BOOL local )
req->local = local;
if (!server_call( REQ_GET_ATOM_NAME ))
{
len = WideCharToMultiByte( CP_ACP, 0, server_data_ptr(req), server_data_size(req),
len = WideCharToMultiByte( CP_ACP, 0, server_data_ptr(req),
server_data_size(req) / sizeof(WCHAR),
buffer, count - 1, NULL, NULL );
if (!len) len = count; /* overflow */
else buffer[len] = 0;