{"name": "epoll_op", "code": "__int64 __fastcall epoll_op ( int @@a1@@ , int @@a2@@ , int @@a3@@ , uint32_t @@a4@@ , epoll_data_t @@a5@@ ) { struct epoll_event @@event@@ ; @@event@@ . events = @@a4@@ ; @@event@@ . data = @@a5@@ ; return ( unsigned int ) epoll_ctl ( @@a1@@ , @@a2@@ , @@a3@@ , & @@event@@ ) ; }", "source": [{"n": "a3", "t": {"T": 1, "n": "int", "s": 4}, "location": "r16"}, {"n": "a4", "t": {"T": 1, "n": "uint32_t", "s": 4}, "location": "r24"}, {"n": "a1", "t": {"T": 1, "n": "int", "s": 4}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "int", "s": 4}, "location": "r64"}, {"n": "a5", "t": {"T": 8}, "location": "r72"}, {"n": "event", "t": {"T": 6, "n": "struct epoll_event", "l": [{"T": 4, "n": "events", "t": "uint32_t", "s": 4}, {"T": 4, "n": "data", "t": "epoll_data_t", "s": 8}]}, "location": "s16"}]}
{"name": "RtmpEPOLLCTXFini", "code": "void __fastcall RtmpEPOLLCTXFini ( unsigned int * @@a1@@ ) { epoll_op ( ( unsigned int ) g_iEpollFd , Number L , * @@a1@@ , Number L , Number L ) ; close ( * @@a1@@ ) ; free ( * ( ( void * * ) @@a1@@ + Number ) ) ; free ( @@a1@@ ) ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "unsigned int"}, "location": "r56"}]} {"name": "ListenHandle", "code": "__int64 __fastcall ListenHandle ( int @@a1@@ ) { int * v2 ; char * v3 ; socklen_t @@addr_len@@ ; struct sockaddr @@s@@ ; _QWORD * @@v6@@ ; void * @@ptr@@ ; int @@v8@@ ; unsigned int @@v9@@ ; @@v9@@ = Number ; memset ( & @@s@@ , Number , sizeof ( @@s@@ ) ) ; @@addr_len@@ = Number ; @@v8@@ = accept ( @@a1@@ , & @@s@@ , & @@addr_len@@ ) ; if ( @@v8@@ < Number ) { v2 = _errno_location ( ) ; v3 = strerror ( * v2 ) ; printf ( String , v3 ) ; } else { @@ptr@@ = malloc ( Number ) ; if ( ! @@ptr@@ ) return Number ; * ( ( _DWORD * ) @@ptr@@ + Number ) = Number ; @@v6@@ = malloc ( Number ) ; if ( ! @@v6@@ ) { free ( @@ptr@@ ) ; return Number ; } * ( _DWORD * ) @@ptr@@ = @@v8@@ ; * ( _DWORD * ) @@v6@@ = @@v8@@ ; @@v6@@ [ Number ] = @@ptr@@ ; @@v6@@ [ Number ] = RtmpSessionHandle ; @@v9@@ = epoll_op ( ( unsigned int ) g_iEpollFd , Number L , ( unsigned int ) @@v8@@ , Number L , @@v6@@ ) ; } return @@v9@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "int", "s": 4}, "location": "r56"}, {"n": "ptr", "t": {"T": 3, "t": "void"}, "location": "s16"}, {"n": "v6", "t": {"T": 3, "t": "_QWORD"}, "location": "s24"}, {"n": "v9", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4"}, {"n": "s", "t": {"T": 6, "n": "struct sockaddr", "l": [{"T": 4, "n": "sa_family", "t": "sa_family_t", "s": 2}, {"T": 4, "n": "sa_data", "t": "char[14]", "s": 14}]}, "location": "s48"}, {"n": "addr_len", "t": {"T": 1, "n": "socklen_t", "s": 4}, "location": "s52"}, {"n": "v8", "t": {"T": 1, "n": "int", "s": 4}, "location": "s8"}]} {"name": "main", "code": "int __cdecl main ( int @@argc@@ , const char * * @@argv@@ , const char * * @@envp@@ ) { int @@result@@ ; struct sockaddr @@addr@@ ; epoll_data_t @@v5@@ ; int @@fd@@ ; puts ( String ) ; g_iEpollFd = epoll_create ( Number ) ; if ( g_iEpollFd >= Number ) { @@fd@@ = socket ( Number , Number , Number ) ; if ( @@fd@@ >= Number ) { @@addr@@ . sa_family = Number ; * ( _DWORD * ) & @@addr@@ . sa_data [ Number ] = inet_addr ( g_cRtmpSrvAddr ) ; * ( _WORD * ) @@addr@@ . sa_data = htons ( g_usRtmpSrvPort ) ; if ( bind ( @@fd@@ , & @@addr@@ , Number ) ) { @@result@@ = Number ; } else if ( listen ( @@fd@@ , Number ) ) { @@result@@ = Number ; } else { @@v5@@ . u64 = ( uint64_t ) malloc ( Number ) ; if ( @@v5@@ . u64 ) { * ( _DWORD * ) @@v5@@ . ptr = @@fd@@ ; * ( _QWORD * ) ( @@v5@@ . u64 + Number ) = ListenHandle ; * ( _QWORD * ) ( @@v5@@ . u64 + Number ) = Number L ; if ( ! ( unsigned int ) epoll_op ( g_iEpollFd , Number , @@fd@@ , Number , @@v5@@ ) ) { g_iListenFd = @@fd@@ ; epoll_loop ( g_iEpollFd ) ; } @@result@@ = Number ; } else { @@result@@ = Number ; } } } else { puts ( String ) ; @@result@@ = Number ; } } else { puts ( String ) ; @@result@@ = Number ; } return @@result@@ ; }", "source": [{"n": "envp", "t": {"T": 3, "t": "const char *"}, "location": "r16"}, {"n": "argc", "t": {"T": 1, "n": "int", "s": 4}, "location": "r56"}, {"n": "argv", "t": {"T": 3, "t": "const char *"}, "location": "r64"}, {"n": "result", "t": {"T": 1, "n": "int", "s": 4}, "location": "r8"}, {"n": "v5", "t": {"T": 8}, "location": "s16"}, {"n": "addr", "t": {"T": 6, "n": "struct sockaddr", "l": [{"T": 4, "n": "sa_family", "t": "sa_family_t", "s": 2}, {"T": 4, "n": "sa_data", "t": "char[14]", "s": 14}]}, "location": "s32"}, {"n": "fd", "t": {"T": 1, "n": "int", "s": 4}, "location": "s4"}]}