mirror of
https://github.com/rapid7/metasploit-payloads
synced 2025-01-02 11:36:22 +01:00
Updated meterpreter binaries with a slight change to the thread schedule (solves a looping problem when the socket is dead).
git-svn-id: file:///home/svn/framework3/trunk@7793 4d416f70-5f16-0410-b530-b9f4589650da
This commit is contained in:
parent
4fbd5b4983
commit
49b712c2c8
@ -210,26 +210,25 @@ DWORD THREADCALL scheduler_waitable_thread( THREAD * thread )
|
||||
|
||||
list_add( schedulerThreadList, thread );
|
||||
|
||||
waitableHandles[0] = entry->waitable;
|
||||
|
||||
waitableHandles[1] = thread->sigterm->handle;
|
||||
waitableHandles[0] = thread->sigterm->handle;
|
||||
waitableHandles[1] = entry->waitable;
|
||||
|
||||
dprintf( "[SCHEDULER] entering scheduler_waitable_thread( 0x%08X )", thread );
|
||||
|
||||
while( !terminate )
|
||||
{
|
||||
dprintf( "[SCHEDULER] scheduler_waitable_thread( 0x%08X ) waiting on 0x%08X and 0x%08X", thread, waitableHandles[0], waitableHandles[1]);
|
||||
|
||||
result = WaitForMultipleObjects( 2, (HANDLE *)&waitableHandles, FALSE, INFINITE );
|
||||
dprintf( "[SCHEDULER] scheduler_waitable_thread( 0x%08X ) waiting on 0x%08X and 0x%08X returned %d", thread, waitableHandles[0], waitableHandles[1], result - WAIT_OBJECT_0);
|
||||
switch( result - WAIT_OBJECT_0 )
|
||||
{
|
||||
case 0:
|
||||
entry->routine( entry->remote, entry->context );
|
||||
break;
|
||||
case 1:
|
||||
dprintf( "[SCHEDULER] scheduler_waitable_thread( 0x%08X ), signaled to terminate...", thread );
|
||||
terminate = TRUE;
|
||||
break;
|
||||
case 1:
|
||||
dprintf( "[SCHEDULER] scheduler_waitable_thread( 0x%08X ), signaled on waitable...", thread );
|
||||
entry->routine( entry->remote, entry->context );
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -32,7 +32,7 @@
|
||||
#include "list.h"
|
||||
|
||||
|
||||
// #define DEBUGTRACE
|
||||
//#define DEBUGTRACE
|
||||
|
||||
#ifdef DEBUGTRACE
|
||||
#define dprintf(...) real_dprintf(__VA_ARGS__)
|
||||
|
Loading…
Reference in New Issue
Block a user