Advertisement
Guest User

Untitled

a guest
Feb 22nd, 2012
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.41 KB | None | 0 0
  1. #include <windows.h>
  2. int main(int argc, char* argv[])
  3. {
  4.     STARTUPINFO si;
  5.     PROCESS_INFORMATION pi;
  6.     ZeroMemory( &si, sizeof(si) );
  7.     si.cb = sizeof(si);
  8.     ZeroMemory( &pi, sizeof(pi) );
  9.     if( !CreateProcess( NULL, "c:/windows/regedit.exe", NULL, NULL, FALSE,
  10.         0, NULL, NULL, &si, &pi))
  11.         {system("pause");return 0;}
  12.     //Close process and thread handles.
  13.     CloseHandle( pi.hProcess );
  14.     CloseHandle( pi.hThread );
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement