* improve error checking (by hpoussin)
authorJohannes Anderwald <johannes.anderwald@reactos.org>
Sun, 27 Aug 2006 20:01:14 +0000 (20:01 +0000)
committerJohannes Anderwald <johannes.anderwald@reactos.org>
Sun, 27 Aug 2006 20:01:14 +0000 (20:01 +0000)
* use correct CLSID -> now auto-start apps from %ALLUSERSPROFILE% can be started too

svn path=/trunk/; revision=23753

reactos/base/system/userinit/userinit.c

index 32c6567..135dba9 100644 (file)
@@ -171,7 +171,7 @@ StartAutoApplications(int clsid)
 
     hResult = SHGetFolderPathW(NULL, clsid, NULL, SHGFP_TYPE_CURRENT, szPath);
     len = wcslen(szPath);
-    if (hResult == E_FAIL || hResult == E_INVALIDARG || len == 0)
+    if (!SUCCEEDED(hResult) || len == 0)
     {
       return;
     }
@@ -230,7 +230,7 @@ void StartShell(void)
                    &pi))
   {
     StartAutoApplications(CSIDL_STARTUP);
-    StartAutoApplications(CSIDL_ALTSTARTUP);
+    StartAutoApplications(CSIDL_COMMON_STARTUP);
     WaitForSingleObject(pi.hProcess, INFINITE);
     CloseHandle(pi.hProcess);
     CloseHandle(pi.hThread);