You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
_procOut.Append("Trying to bind to detected processes at PIDs: ");
84
-
85
-
foreach(Processprocin_procTree)
86
-
{
87
-
_procOut.Append(proc.Id+" ");
88
-
}
89
-
ProcessUtils.Logger("DEBUG",_procOut.ToString());
90
-
}
91
-
#endif
92
-
93
-
if(_result>0)
94
-
{// rebind our process handle using our validated PID
95
-
_retProc=ProcessUtils.RebindProcessByID(_result);
96
-
processType=WindowUtils.DetectWindowType(_retProc);// pass our process type out by ref
97
-
ProcessUtils.Logger("OSOL",String.Format("Bound to a valid process at PID: {0} [{1}] in {2} seconds",_result,String.Format("{0}.exe",procName),sanity_counter));
54
+
if(_result>0)
55
+
{// rebind our process handle using our validated PID
56
+
_retProc=ProcessUtils.RebindProcessByID(_result);
57
+
processType=WindowUtils.DetectWindowType(_retProc);// pass our process type out by ref
98
58
99
-
if(processType==-1)
100
-
ProcessUtils.Logger("WARNING",String.Format("Could not find MainWindowHandle of PID [{0}], fell back to ModuleHandle instead...",_retProc.Id));
101
-
102
-
break;
103
-
}
59
+
if(processType==-1)
60
+
ProcessUtils.Logger("WARNING",String.Format("Could not find MainWindowHandle of PID [{0}], fell back to ModuleHandle instead...",_retProc.Id));
104
61
}
105
62
106
63
return_retProc;// returns null if nothing matched or we timed out, otherwise reports a validated Process handle
@@ -208,7 +165,7 @@ public void ProcessLauncher(Settings setHnd, IniFile iniHnd)
208
165
if(launcherType>-1)
209
166
{// we can only send window messages if we have a window handle
0 commit comments