Advertisement
es3n1n

spotify debugger fix

Feb 26th, 2022
737
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. void* oDuplicateHandle;
  2. BOOL __stdcall hkDuplicateHandle(
  3.     HANDLE hSourceProcessHandle,
  4.     HANDLE hSourceHandle,
  5.     HANDLE hTargetProcessHandle,
  6.     LPHANDLE lpTargetHandle,
  7.     DWORD dwDesiredAccess,
  8.     BOOL bInheritHandle,
  9.     DWORD dwOptions
  10. ) {
  11.     auto ret = reinterpret_cast< decltype( &hkDuplicateHandle ) >( oDuplicateHandle )( hSourceProcessHandle, hSourceHandle, hTargetProcessHandle, lpTargetHandle, dwDesiredAccess, bInheritHandle, dwOptions );
  12.     if ( !ret )
  13.         SetLastError( 0 );
  14.     return TRUE;
  15. }
  16.  
  17.  
  18. if ( !util::hooking::detour::create( DuplicateHandle, hkDuplicateHandle, &oDuplicateHandle ) )
  19.     util::logger::fatal( "ya upal" );
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement