kernel32: Don't get the profile string if the buffer length is zero.

This commit is contained in:
James Hawkins 2008-07-17 12:27:14 -05:00 committed by Alexandre Julliard
parent 97429b32f8
commit 978a931781
1 changed files with 1 additions and 1 deletions

View File

@ -957,7 +957,7 @@ static INT PROFILE_GetString( LPCWSTR section, LPCWSTR key_name,
PROFILEKEY *key = NULL;
static const WCHAR empty_strW[] = { 0 };
if(!buffer) return 0;
if(!buffer || !len) return 0;
if (!def_val) def_val = empty_strW;
if (key_name)