Andreas Rosenberg wrote:
+ TRACE("%p %s %p\n", hToken, debugstr_w(lpProfileDir), lpcchSize );
+ /* profile specific tokens not supported, so hToken ignored */
+
+ SetLastError(0);
+ res = RegOpenKeyExW(HKEY_LOCAL_MACHINE,profile_pathname,0L,KEY_QUERY_VALUE,&keyProfileDir);
Why do you need this SetLastError(0)?
+ res = RegGetValueW(keyProfileDir,profile_subkey,profile_keyname,RRF_RT_ANY,
+ NULL,buffer,&sizePath); /* RegGetValue expects pcbData in bytes */
+ error = GetLastError();
+ RegCloseKey(keyProfileDir);
error isn't used after that.
+ /* else ("GetUserNameW failed\n"); */
+ }
+ /* else ("RegGetValueW failed - %d %d %d\n",res,error,sizePath); */
+ }
+ /* else ("RegOpenKeyExW failed\n"); */
return FALSE;
What do these debug-comment lines mean?