wordpad: Fix error handling when saving empty files.

oldstable
Alexander Nicolaysen Sørnes 2007-07-18 20:47:40 +02:00 committed by Alexandre Julliard
parent c7ca877b12
commit 09161365f9
1 changed files with 8 additions and 1 deletions

View File

@ -219,7 +219,14 @@ static void DoSaveFile(LPCWSTR wszSaveFileName)
SetFocus(hEditorWnd);
if(!ret)
return;
{
GETTEXTLENGTHEX gt;
gt.flags = GTL_DEFAULT;
gt.codepage = 1200;
if(SendMessageW(hEditorWnd, EM_GETTEXTLENGTHEX, (WPARAM)&gt, 0))
return;
}
lstrcpyW(wszFileName, wszSaveFileName);
set_caption(wszFileName);