[pywin32-checkins] pywin32/win32/src win32apimodule.cpp,1.89,1.90
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2008-09-29 12:59:25
|
Update of /cvsroot/pywin32/pywin32/win32/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32067/win32/src Modified Files: win32apimodule.cpp Log Message: Yet another go at GetConsoleTitle reliable! Index: win32apimodule.cpp =================================================================== RCS file: /cvsroot/pywin32/pywin32/win32/src/win32apimodule.cpp,v retrieving revision 1.89 retrieving revision 1.90 diff -C2 -d -r1.89 -r1.90 *** win32apimodule.cpp 10 Aug 2008 13:13:21 -0000 1.89 --- win32apimodule.cpp 29 Sep 2008 12:59:13 -0000 1.90 *************** *** 895,898 **** --- 895,903 ---- // the title, the return value is zero and GetLastError returns // ERROR_SUCCESS." + // However, even on Vista, markh can observe this failing with an + // apparently stale error code - as if GetConsoleTitle assumes the + // error code is already 0 in that case. So we clear the error to + // solve that. + SetLastError(0); while (TRUE){ if (title!=NULL){ |