Author: rharabien
Date: Sun Jan 15 13:37:25 2012
New Revision: 54972

URL: http://svn.reactos.org/svn/reactos?rev=54972&view=rev
Log:
[INTL]
- Add DPRINTs to track possible unattended setup timeouts

Modified:
    trunk/reactos/dll/cpl/intl/CMakeLists.txt
    trunk/reactos/dll/cpl/intl/generalp.c
    trunk/reactos/dll/cpl/intl/intl.c
    trunk/reactos/dll/cpl/intl/intl.h

Modified: trunk/reactos/dll/cpl/intl/CMakeLists.txt
URL: 
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/intl/CMakeLists.txt?rev=54972&r1=54971&r2=54972&view=diff
==============================================================================
--- trunk/reactos/dll/cpl/intl/CMakeLists.txt [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/intl/CMakeLists.txt [iso-8859-1] Sun Jan 15 13:37:25 
2012
@@ -28,7 +28,8 @@
     advapi32
     setupapi
     shell32
-    kernel32)
+    kernel32
+    ntdll)
 
 add_pch(intl intl.h)
 add_cd_file(TARGET intl DESTINATION reactos/system32 FOR all)

Modified: trunk/reactos/dll/cpl/intl/generalp.c
URL: 
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/intl/generalp.c?rev=54972&r1=54971&r2=54972&view=diff
==============================================================================
--- trunk/reactos/dll/cpl/intl/generalp.c [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/intl/generalp.c [iso-8859-1] Sun Jan 15 13:37:25 2012
@@ -331,7 +331,8 @@
                 {
                     SetNewLocale(UnattendLCID);
                     PostQuitMessage(0);
-                }
+                } else
+                    DPRINT1("VerifyUnattendLCID failed\n");
                 return TRUE;
             }
             break;

Modified: trunk/reactos/dll/cpl/intl/intl.c
URL: 
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/intl/intl.c?rev=54972&r1=54971&r2=54972&view=diff
==============================================================================
--- trunk/reactos/dll/cpl/intl/intl.c [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/intl/intl.c [iso-8859-1] Sun Jan 15 13:37:25 2012
@@ -67,29 +67,26 @@
     lpCmdLine = GetCommandLine();
 
     lpSwitch = _tcsstr(lpCmdLine, _T("/f:\""));
-
-    if(!lpSwitch)
-    {
+    if (!lpSwitch)
         return FALSE;
-    }
 
     len = _tcslen(lpSwitch);
-    if (len < 5)
-    {
+    if (len < 5 || lpSwitch[len-1] != _T('\"'))
+    {
+        DPRINT1("Invalid switch: %ls\n", lpSwitch);
         return FALSE;
     }
 
-    if(lpSwitch[len-1] != _T('\"'))
-    {
+    lpSwitch[len-1] = _T('\0');
+
+    hSetupInf = SetupOpenInfFile(&lpSwitch[4], NULL, INF_STYLE_OLDNT, NULL);
+    if (hSetupInf == INVALID_HANDLE_VALUE)
+    {
+        DPRINT1("Failed to open INF file: %ls\n", &lpSwitch[4]);
         return FALSE;
     }
 
-    lpSwitch[len-1] = _T('\0');
-
-    hSetupInf = SetupOpenInfFile(&lpSwitch[4], NULL,
-                                 INF_STYLE_OLDNT, NULL);
-
-    return (hSetupInf != INVALID_HANDLE_VALUE);
+    return TRUE;
 }
 
 VOID
@@ -104,6 +101,7 @@
                             &InfContext))
     {
         SetupCloseInfFile(hSetupInf);
+        DPRINT1("SetupFindFirstLine failed\n");
         return;
     }
 
@@ -111,6 +109,7 @@
                              sizeof(szBuffer) / sizeof(TCHAR), NULL))
     {
         SetupCloseInfFile(hSetupInf);
+        DPRINT1("SetupGetStringField failed\n");
         return;
     }
 

Modified: trunk/reactos/dll/cpl/intl/intl.h
URL: 
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/intl/intl.h?rev=54972&r1=54971&r2=54972&view=diff
==============================================================================
--- trunk/reactos/dll/cpl/intl/intl.h [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/intl/intl.h [iso-8859-1] Sun Jan 15 13:37:25 2012
@@ -7,6 +7,7 @@
 #include <tchar.h>
 #include <prsht.h>
 #include <malloc.h>
+#include <debug.h>
 
 #include "resource.h"
 


Reply via email to