{"name": "checkError", "code": "void __fastcall checkError ( int @@a1@@ ) { int * v1 ; char * v2 ; if ( @@a1@@ < Number ) { v1 = _errno_location ( ) ; v2 = strerror ( * v1 ) ; printf ( String , v2 ) ; exit ( Number ) ; } }", "source": [{"n": "a1", "t": {"T": 1, "n": "int", "s": 4}, "location": "r56"}]}
{"name": "main", "code": "int __cdecl main ( int @@argc@@ , const char * * @@argv@@ , const char * * @@envp@@ ) { int @@result@@ ; int @@stat_loc@@ ; socklen_t @@addr_len@@ ; struct sockaddr @@v6@@ ; char @@buf@@ [ Number ] ; char @@s@@ [ Number ] ; int @@v9@@ ; struct sockaddr @@addr@@ ; int @@v11@@ ; int @@v12@@ ; int @@v13@@ ; int @@v14@@ ; int @@v15@@ ; int @@v16@@ ; int @@v17@@ ; __pid_t @@v18@@ ; int @@v19@@ ; int @@v20@@ ; int @@fd@@ ; int @@v22@@ ; unsigned int @@v23@@ ; @@fd@@ = socket ( Number , Number , Number ) ; @@addr@@ . sa_family = Number ; * ( _WORD * ) @@addr@@ . sa_data = htons ( Number ) ; * ( _DWORD * ) & @@addr@@ . sa_data [ Number ] = Number ; @@v20@@ = bind ( @@fd@@ , & @@addr@@ , Number ) ; checkError ( @@v20@@ ) ; @@v20@@ = listen ( @@fd@@ , Number ) ; checkError ( @@v20@@ ) ; @@v23@@ = Number ; @@v9@@ = Number ; @@v19@@ = accept ( @@fd@@ , & @@v6@@ , & @@addr_len@@ ) ; checkError ( @@v19@@ ) ; printf ( String , ( unsigned int ) @@v19@@ ) ; @@v18@@ = fork ( ) ; if ( @@v18@@ ) { if ( @@v18@@ > Number ) { close ( @@v19@@ ) ; @@stat_loc@@ = Number ; do { @@v17@@ = waitpid ( Number , & @@stat_loc@@ , Number ) ; checkError ( @@v17@@ ) ; if ( @@v17@@ > Number ) printf ( String , ( unsigned int ) @@v17@@ ) ; } while ( @@v17@@ > Number ) ; } close ( @@fd@@ ) ; @@result@@ = Number ; } else { snprintf ( @@s@@ , Number , String , @@v23@@ ) ; @@v16@@ = send ( @@v19@@ , @@s@@ , Number , Number ) ; checkError ( @@v16@@ ) ; @@v22@@ = Number ; while ( ! @@v22@@ ) { @@v15@@ = recv ( @@v19@@ , @@buf@@ , Number , Number ) ; checkError ( @@v15@@ ) ; printf ( String , @@buf@@ ) ; if ( strlen ( @@buf@@ ) <= Number ) { if ( atoi ( @@buf@@ ) || @@buf@@ == String ) { _isoc99_sscanf ( @@buf@@ , String , & @@v9@@ ) ; @@v23@@ += @@v9@@ ; snprintf ( @@s@@ , Number , String , @@v23@@ ) ; @@v12@@ = send ( @@v19@@ , @@s@@ , Number , Number ) ; checkError ( @@v12@@ ) ; } else if ( ! strcmp ( @@buf@@ , String ) ) { snprintf ( @@s@@ , Number , String , String , @@v23@@ ) ; @@v14@@ = send ( @@v19@@ , @@s@@ , Number , Number ) ; checkError ( @@v14@@ ) ; @@v22@@ = Number ; } else { snprintf ( @@s@@ , Number , String , String , @@v23@@ ) ; @@v13@@ = send ( @@v19@@ , @@s@@ , Number , Number ) ; checkError ( @@v13@@ ) ; } } else { snprintf ( @@s@@ , Number , String , String , @@v23@@ ) ; @@v11@@ = send ( @@v19@@ , @@s@@ , Number , Number ) ; checkError ( @@v11@@ ) ; } } close ( @@v19@@ ) ; @@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": "s", "t": {"T": 2, "n": 1036, "s": 1, "t": "char"}, "location": "s1120"}, {"n": "fd", "t": {"T": 1, "n": "int", "s": 4}, "location": "s12"}, {"n": "v20", "t": {"T": 1, "n": "int", "s": 4}, "location": "s16"}, {"n": "v19", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "buf", "t": {"T": 2, "n": 1024, "s": 1, "t": "char"}, "location": "s2144"}, {"n": "v18", "t": {"T": 1, "n": "__pid_t", "s": 4}, "location": "s24"}, {"n": "v17", "t": {"T": 1, "n": "int", "s": 4}, "location": "s28"}, {"n": "v6", "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": "s3184"}, {"n": "addr_len", "t": {"T": 1, "n": "socklen_t", "s": 4}, "location": "s3188"}, {"n": "stat_loc", "t": {"T": 1, "n": "int", "s": 4}, "location": "s3192"}, {"n": "v16", "t": {"T": 1, "n": "int", "s": 4}, "location": "s32"}, {"n": "v15", "t": {"T": 1, "n": "int", "s": 4}, "location": "s36"}, {"n": "v23", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4"}, {"n": "v14", "t": {"T": 1, "n": "int", "s": 4}, "location": "s40"}, {"n": "v13", "t": {"T": 1, "n": "int", "s": 4}, "location": "s44"}, {"n": "v12", "t": {"T": 1, "n": "int", "s": 4}, "location": "s48"}, {"n": "v11", "t": {"T": 1, "n": "int", "s": 4}, "location": "s52"}, {"n": "v22", "t": {"T": 1, "n": "int", "s": 4}, "location": "s8"}, {"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": "s80"}, {"n": "v9", "t": {"T": 1, "n": "int", "s": 4}, "location": "s84"}]}