
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Unknown calling convention */

int png_check_fp_string(png_const_charp string,size_t size)

{
  int iVar1;
  int in_GS_OFFSET;
  int state;
  size_t char_index;
  int local_10;
  
  local_10 = *(int *)(in_GS_OFFSET + 0x14);
  state = 0;
  char_index = 0;
  iVar1 = png_check_fp_number(string,size,&state,&char_index);
  if ((iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0')))) {
    iVar1 = state;
  }
  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {
    return iVar1;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail_local();
}



/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

int FUN_00016ce0(int param_1,int param_2)

{
  int iVar1;
  int in_GS_OFFSET;
  int local_18;
  int local_14;
  int local_10;
  
  local_10 = *(int *)(in_GS_OFFSET + 0x14);
  local_18 = 0;
  local_14 = 0;
  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);
  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))
  {
    iVar1 = local_18;
  }
  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {
    return iVar1;
  }
                    /* WARNING: Subroutine does not return */
  FUN_0003a600();
}


PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00014970
ADD EBX,0x37098
SUB ESP,0x10
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0xc],EAX
XOR EAX,EAX
LEA EAX,[ESP + 0x8]
MOV EDI,dword ptr [ESP + 0x20]
MOV ESI,dword ptr [ESP + 0x24]
MOV dword ptr [ESP + 0x4],0x0
MOV dword ptr [ESP + 0x8],0x0
PUSH EAX
LEA EAX,[ESP + 0x8]
PUSH EAX
PUSH ESI
PUSH EDI
CALL 0x00016b60
ADD ESP,0x10
TEST EAX,EAX
JZ 0x00016d3d
MOV EDX,dword ptr [ESP + 0x8]
CMP EDX,ESI
JZ 0x00016d58
XOR EAX,EAX
CMP byte ptr [EDI + EDX*0x1],0x0
JZ 0x00016d58
MOV ECX,dword ptr [ESP + 0xc]
XOR ECX,dword ptr GS:[0x14]
JNZ 0x00016d5e
ADD ESP,0x10
POP EBX
POP ESI
POP EDI
RET
MOV EAX,dword ptr [ESP + 0x4]
JMP 0x00016d3d
CALL 0x0003a600
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint FUN_00016ce0(int param_1,int param_2)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0003a600();\n}\n\n" comment (function_definition "int FUN_00016ce0(int param_1,int param_2)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0003a600();\n}" primitive_type (function_declarator "FUN_00016ce0(int param_1,int param_2)" identifier (parameter_list "(int param_1,int param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    /* WARNING: Subroutine does not return */\n  FUN_0003a600();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "int local_18;" primitive_type identifier ;) (declaration "int local_14;" primitive_type identifier ;) (declaration "int local_10;" primitive_type identifier ;) (expression_statement "local_10 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_10 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "local_18 = 0;" (assignment_expression "local_18 = 0" identifier = number_literal) ;) (expression_statement "local_14 = 0;" (assignment_expression "local_14 = 0" identifier = number_literal) ;) (expression_statement "iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);" (assignment_expression "iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14)" identifier = (call_expression "FUN_00016b60(param_1,param_2,&local_18,&local_14)" identifier (argument_list "(param_1,param_2,&local_18,&local_14)" ( identifier , identifier , (pointer_expression "&local_18" & identifier) , (pointer_expression "&local_14" & identifier) )))) ;) (if_statement "if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }" if (parenthesized_expression "((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))" ( (binary_expression "(iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')))" (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) && (parenthesized_expression "((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')))" ( (parenthesized_expression "(local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))" ( (binary_expression "local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')" (binary_expression "local_14 == param_2" identifier == identifier) || (parenthesized_expression "(iVar1 = 0, *(char *)(param_1 + local_14) == '\0')" ( (comma_expression "iVar1 = 0, *(char *)(param_1 + local_14) == '\0'" (assignment_expression "iVar1 = 0" identifier = number_literal) , (binary_expression "*(char *)(param_1 + local_14) == '\0'" (pointer_expression "*(char *)(param_1 + local_14)" * (cast_expression "(char *)(param_1 + local_14)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + local_14)" ( (binary_expression "param_1 + local_14" identifier + identifier) )))) == (char_literal "'\0'" ' escape_sequence '))) ))) )) ))) )) (compound_statement "{\n    iVar1 = local_18;\n  }" { (expression_statement "iVar1 = local_18;" (assignment_expression "iVar1 = local_18" identifier = identifier) ;) })) (if_statement "if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }" if (parenthesized_expression "(local_10 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_10 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return iVar1;\n  }" { (return_statement "return iVar1;" return identifier ;) })) comment (expression_statement "FUN_0003a600();" (call_expression "FUN_0003a600()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nint png_check_fp_string(png_const_charp string,size_t size)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int state;\n  size_t char_index;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  state = 0;\n  char_index = 0;\n  iVar1 = png_check_fp_number(string,size,&state,&char_index);\n  if ((iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0')))) {\n    iVar1 = state;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}\n\n" comment comment (function_definition "int png_check_fp_string(png_const_charp string,size_t size)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int state;\n  size_t char_index;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  state = 0;\n  char_index = 0;\n  iVar1 = png_check_fp_number(string,size,&state,&char_index);\n  if ((iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0')))) {\n    iVar1 = state;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" primitive_type (function_declarator "png_check_fp_string(png_const_charp string,size_t size)" identifier (parameter_list "(png_const_charp string,size_t size)" ( (parameter_declaration "png_const_charp string" type_identifier identifier) , (parameter_declaration "size_t size" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int in_GS_OFFSET;\n  int state;\n  size_t char_index;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  state = 0;\n  char_index = 0;\n  iVar1 = png_check_fp_number(string,size,&state,&char_index);\n  if ((iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0')))) {\n    iVar1 = state;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail_local();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "int state;" primitive_type identifier ;) (declaration "size_t char_index;" primitive_type identifier ;) (declaration "int local_10;" primitive_type identifier ;) (expression_statement "local_10 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_10 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "state = 0;" (assignment_expression "state = 0" identifier = number_literal) ;) (expression_statement "char_index = 0;" (assignment_expression "char_index = 0" identifier = number_literal) ;) (expression_statement "iVar1 = png_check_fp_number(string,size,&state,&char_index);" (assignment_expression "iVar1 = png_check_fp_number(string,size,&state,&char_index)" identifier = (call_expression "png_check_fp_number(string,size,&state,&char_index)" identifier (argument_list "(string,size,&state,&char_index)" ( identifier , identifier , (pointer_expression "&state" & identifier) , (pointer_expression "&char_index" & identifier) )))) ;) (if_statement "if ((iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0')))) {\n    iVar1 = state;\n  }" if (parenthesized_expression "((iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0'))))" ( (binary_expression "(iVar1 != 0) && ((char_index == size || (iVar1 = 0, string[char_index] == '\0')))" (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) && (parenthesized_expression "((char_index == size || (iVar1 = 0, string[char_index] == '\0')))" ( (parenthesized_expression "(char_index == size || (iVar1 = 0, string[char_index] == '\0'))" ( (binary_expression "char_index == size || (iVar1 = 0, string[char_index] == '\0')" (binary_expression "char_index == size" identifier == identifier) || (parenthesized_expression "(iVar1 = 0, string[char_index] == '\0')" ( (comma_expression "iVar1 = 0, string[char_index] == '\0'" (assignment_expression "iVar1 = 0" identifier = number_literal) , (binary_expression "string[char_index] == '\0'" (subscript_expression "string[char_index]" identifier [ identifier ]) == (char_literal "'\0'" ' escape_sequence '))) ))) )) ))) )) (compound_statement "{\n    iVar1 = state;\n  }" { (expression_statement "iVar1 = state;" (assignment_expression "iVar1 = state" identifier = identifier) ;) })) (if_statement "if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }" if (parenthesized_expression "(local_10 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_10 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return iVar1;\n  }" { (return_statement "return iVar1;" return identifier ;) })) comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "int FUN_00016ce0(int param_1,int param_2)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    \n  FUN_0003a600();\n}\n\n" (function_definition "int FUN_00016ce0(int param_1,int param_2)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    \n  FUN_0003a600();\n}" primitive_type (function_declarator "FUN_00016ce0(int param_1,int param_2)" identifier (parameter_list "(int param_1,int param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    \n  FUN_0003a600();\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "int local_18;" primitive_type identifier ;) (declaration "int local_14;" primitive_type identifier ;) (declaration "int local_10;" primitive_type identifier ;) (expression_statement "local_10 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_10 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "local_18 = 0;" (assignment_expression "local_18 = 0" identifier = number_literal) ;) (expression_statement "local_14 = 0;" (assignment_expression "local_14 = 0" identifier = number_literal) ;) (expression_statement "iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);" (assignment_expression "iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14)" identifier = (call_expression "FUN_00016b60(param_1,param_2,&local_18,&local_14)" identifier (argument_list "(param_1,param_2,&local_18,&local_14)" ( identifier , identifier , (pointer_expression "&local_18" & identifier) , (pointer_expression "&local_14" & identifier) )))) ;) (if_statement "if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }" if (parenthesized_expression "((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))" ( (binary_expression "(iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')))" (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) && (parenthesized_expression "((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')))" ( (parenthesized_expression "(local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))" ( (binary_expression "local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')" (binary_expression "local_14 == param_2" identifier == identifier) || (parenthesized_expression "(iVar1 = 0, *(char *)(param_1 + local_14) == '\0')" ( (comma_expression "iVar1 = 0, *(char *)(param_1 + local_14) == '\0'" (assignment_expression "iVar1 = 0" identifier = number_literal) , (binary_expression "*(char *)(param_1 + local_14) == '\0'" (pointer_expression "*(char *)(param_1 + local_14)" * (cast_expression "(char *)(param_1 + local_14)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + local_14)" ( (binary_expression "param_1 + local_14" identifier + identifier) )))) == (char_literal "'\0'" ' escape_sequence '))) ))) )) ))) )) (compound_statement "{\n    iVar1 = local_18;\n  }" { (expression_statement "iVar1 = local_18;" (assignment_expression "iVar1 = local_18" identifier = identifier) ;) })) (if_statement "if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }" if (parenthesized_expression "(local_10 == *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_10 == *(int *)(in_GS_OFFSET + 0x14)" identifier == (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n    return iVar1;\n  }" { (return_statement "return iVar1;" return identifier ;) })) (expression_statement "FUN_0003a600();" (call_expression "FUN_0003a600()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , (pointer_expression & IDENT) , (pointer_expression & IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) && (parenthesized_expression ( (parenthesized_expression ( (binary_expression (binary_expression IDENT == IDENT) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = LIT) , (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + IDENT) )))) == (char_literal ' escape_sequence '))) ))) )) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (return_statement return IDENT ;) })) (expression_statement (call_expression IDENT (argument_list ( ))) ;) })))
(function_definition "int FUN_00016ce0(int param_1,int param_2)\n\n{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    \n  FUN_0003a600();\n}" (primitive_type "int") (function_declarator "FUN_00016ce0(int param_1,int param_2)" (identifier "FUN_00016ce0") (parameter_list "(int param_1,int param_2)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) () ")"))) (compound_statement "{\n  int iVar1;\n  int in_GS_OFFSET;\n  int local_18;\n  int local_14;\n  int local_10;\n  \n  local_10 = *(int *)(in_GS_OFFSET + 0x14);\n  local_18 = 0;\n  local_14 = 0;\n  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);\n  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }\n  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }\n                    \n  FUN_0003a600();\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "int local_18;" (primitive_type "int") (identifier "local_18") (; ";")) (declaration "int local_14;" (primitive_type "int") (identifier "local_14") (; ";")) (declaration "int local_10;" (primitive_type "int") (identifier "local_10") (; ";")) (expression_statement "local_10 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_10 = *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_10") (= "=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (expression_statement "local_18 = 0;" (assignment_expression "local_18 = 0" (identifier "local_18") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_14 = 0;" (assignment_expression "local_14 = 0" (identifier "local_14") (= "=") (number_literal "0")) (; ";")) (expression_statement "iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);" (assignment_expression "iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14)" (identifier "iVar1") (= "=") (call_expression "FUN_00016b60(param_1,param_2,&local_18,&local_14)" (identifier "FUN_00016b60") (argument_list "(param_1,param_2,&local_18,&local_14)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (pointer_expression "&local_18" (& "&") (identifier "local_18")) (, ",") (pointer_expression "&local_14" (& "&") (identifier "local_14")) () ")")))) (; ";")) (if_statement "if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))\n  {\n    iVar1 = local_18;\n  }" (if "if") (parenthesized_expression "((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))" (( "(") (binary_expression "(iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')))" (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')))" (( "(") (parenthesized_expression "(local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))" (( "(") (binary_expression "local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0')" (binary_expression "local_14 == param_2" (identifier "local_14") (== "==") (identifier "param_2")) (|| "||") (parenthesized_expression "(iVar1 = 0, *(char *)(param_1 + local_14) == '\0')" (( "(") (comma_expression "iVar1 = 0, *(char *)(param_1 + local_14) == '\0'" (assignment_expression "iVar1 = 0" (identifier "iVar1") (= "=") (number_literal "0")) (, ",") (binary_expression "*(char *)(param_1 + local_14) == '\0'" (pointer_expression "*(char *)(param_1 + local_14)" (* "*") (cast_expression "(char *)(param_1 + local_14)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + local_14)" (( "(") (binary_expression "param_1 + local_14" (identifier "param_1") (+ "+") (identifier "local_14")) () ")")))) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'")))) () ")"))) () ")")) () ")"))) () ")")) (compound_statement "{\n    iVar1 = local_18;\n  }" ({ "{") (expression_statement "iVar1 = local_18;" (assignment_expression "iVar1 = local_18" (identifier "iVar1") (= "=") (identifier "local_18")) (; ";")) (} "}"))) (if_statement "if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {\n    return iVar1;\n  }" (if "if") (parenthesized_expression "(local_10 == *(int *)(in_GS_OFFSET + 0x14))" (( "(") (binary_expression "local_10 == *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_10") (== "==") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n    return iVar1;\n  }" ({ "{") (return_statement "return iVar1;" (return "return") (identifier "iVar1") (; ";")) (} "}"))) (expression_statement "FUN_0003a600();" (call_expression "FUN_0003a600()" (identifier "FUN_0003a600") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* WARNING: Unknown calling convention */

int function_1(type_1 string,size_t var_5)

{
  int var_3;
  int var_1;
  int state;
  size_t var_4;
  int var_6;
  
  var_6 = *(int *)(var_1 + 0x14);
  state = 0;
  var_4 = 0;
  var_3 = var_2(string,var_5,&state,&var_4);
  if ((var_3 != 0) && ((var_4 == var_5 || (var_3 = 0, string[var_4] == '\0')))) {
    var_3 = state;
  }
  if (var_6 == *(int *)(var_1 + 0x14)) {
    return var_3;
  }
                    /* WARNING: Subroutine does not return */
  var_7();
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (pointer_expression argument: (identifier)) (pointer_expression argument: (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (identifier)) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))))) right: (char_literal (escape_sequence)))))))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) consequence: (compound_statement (return_statement (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list))))))

/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */

int MASKED(int param_1,int param_2)

{
  int iVar1;
  int in_GS_OFFSET;
  int local_18;
  int local_14;
  int local_10;
  
  local_10 = *(int *)(in_GS_OFFSET + 0x14);
  local_18 = 0;
  local_14 = 0;
  iVar1 = FUN_00016b60(param_1,param_2,&local_18,&local_14);
  if ((iVar1 != 0) && ((local_14 == param_2 || (iVar1 = 0, *(char *)(param_1 + local_14) == '\0'))))
  {
    iVar1 = local_18;
  }
  if (local_10 == *(int *)(in_GS_OFFSET + 0x14)) {
    return iVar1;
  }
                    /* WARNING: Subroutine does not return */
  FUN_0003a600();
}

