Commit 11f2cb18 authored by Ulrich Czekalla's avatar Ulrich Czekalla Committed by Alexandre Julliard

GetCPInfo should return FALSE if called with NULL info buffer.

parent e10b5842
......@@ -1302,9 +1302,15 @@ BOOL WINAPI IsDBCSLeadByte( BYTE testchar )
*/
BOOL WINAPI GetCPInfo( UINT codepage, LPCPINFO cpinfo )
{
const union cptable *table = get_codepage_table( codepage );
const union cptable *table;
if (!cpinfo)
{
SetLastError( ERROR_INVALID_PARAMETER );
return FALSE;
}
if (!table)
if (!(table = get_codepage_table( codepage )))
{
switch(codepage)
{
......
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