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

int until_short(argp_option *opt,argp_option *real,char *domain,void *cookie)

{
  int iVar1;
  ushort **ppuVar2;
  int iVar3;
  
  if ((opt->flags & 8U) == 0) {
    iVar1 = opt->key;
    iVar3 = 0;
    if (iVar1 - 1U < 0xff) {
      ppuVar2 = __ctype_b_loc();
      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {
        iVar3 = iVar1;
      }
    }
    return iVar3;
  }
  return 0;
}



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

int FUN_00024260(int param_1)

{
  int iVar1;
  ushort **ppuVar2;
  int iVar3;
  
  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {
    iVar1 = *(int *)(param_1 + 4);
    iVar3 = 0;
    if (iVar1 - 1U < 0xff) {
      ppuVar2 = __ctype_b_loc();
      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {
        iVar3 = iVar1;
      }
    }
    return iVar3;
  }
  return 0;
}


PUSH EDI
PUSH ESI
PUSH EBX
MOV EAX,dword ptr [ESP + 0x10]
CALL 0x00012800
ADD EBX,0x11c04
MOV ESI,dword ptr [EAX + 0xc]
AND ESI,0x8
JNZ 0x000242a0
MOV EDI,dword ptr [EAX + 0x4]
LEA EAX,[EDI + -0x1]
CMP EAX,0xfe
JA 0x00024296
CALL 0x000124a0
MOV EAX,dword ptr [EAX]
TEST byte ptr [EAX + EDI*0x2 + 0x1],0x40
CMOVNZ ESI,EDI
MOV EAX,ESI
POP EBX
POP ESI
POP EDI
RET
XOR ESI,ESI
POP EBX
MOV EAX,ESI
POP ESI
POP EDI
RET
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint FUN_00024260(int param_1)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}\n\n" comment (function_definition "int FUN_00024260(int param_1)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" primitive_type (function_declarator "FUN_00024260(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "ushort **ppuVar2;" type_identifier (pointer_declarator "**ppuVar2" * (pointer_declarator "*ppuVar2" * identifier)) ;) (declaration "int iVar3;" primitive_type identifier ;) (if_statement "if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" if (parenthesized_expression "((*(uint *)(param_1 + 0xc) & 8) == 0)" ( (binary_expression "(*(uint *)(param_1 + 0xc) & 8) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0xc) & 8)" ( (binary_expression "*(uint *)(param_1 + 0xc) & 8" (pointer_expression "*(uint *)(param_1 + 0xc)" * (cast_expression "(uint *)(param_1 + 0xc)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" { (expression_statement "iVar1 = *(int *)(param_1 + 4);" (assignment_expression "iVar1 = *(int *)(param_1 + 4)" identifier = (pointer_expression "*(int *)(param_1 + 4)" * (cast_expression "(int *)(param_1 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (if_statement "if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" if (parenthesized_expression "(iVar1 - 1U < 0xff)" ( (binary_expression "iVar1 - 1U < 0xff" (binary_expression "iVar1 - 1U" identifier - number_literal) < number_literal) )) (compound_statement "{\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" { (expression_statement "ppuVar2 = __ctype_b_loc();" (assignment_expression "ppuVar2 = __ctype_b_loc()" identifier = (call_expression "__ctype_b_loc()" identifier (argument_list "()" ( )))) ;) (if_statement "if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }" if (parenthesized_expression "((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0)" ( (binary_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0" (parenthesized_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40)" ( (binary_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" * (cast_expression "(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*ppuVar2 + iVar1 * 2 + 1)" ( (binary_expression "(int)*ppuVar2 + iVar1 * 2 + 1" (binary_expression "(int)*ppuVar2 + iVar1 * 2" (cast_expression "(int)*ppuVar2" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*ppuVar2" * identifier)) + (binary_expression "iVar1 * 2" identifier * number_literal)) + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n        iVar3 = iVar1;\n      }" { (expression_statement "iVar3 = iVar1;" (assignment_expression "iVar3 = iVar1" identifier = identifier) ;) })) })) (return_statement "return iVar3;" return identifier ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint until_short(argp_option *opt,argp_option *real,char *domain,void *cookie)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((opt->flags & 8U) == 0) {\n    iVar1 = opt->key;\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}\n\n" comment (function_definition "int until_short(argp_option *opt,argp_option *real,char *domain,void *cookie)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((opt->flags & 8U) == 0) {\n    iVar1 = opt->key;\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" primitive_type (function_declarator "until_short(argp_option *opt,argp_option *real,char *domain,void *cookie)" identifier (parameter_list "(argp_option *opt,argp_option *real,char *domain,void *cookie)" ( (parameter_declaration "argp_option *opt" type_identifier (pointer_declarator "*opt" * identifier)) , (parameter_declaration "argp_option *real" type_identifier (pointer_declarator "*real" * identifier)) , (parameter_declaration "char *domain" primitive_type (pointer_declarator "*domain" * identifier)) , (parameter_declaration "void *cookie" primitive_type (pointer_declarator "*cookie" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((opt->flags & 8U) == 0) {\n    iVar1 = opt->key;\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "ushort **ppuVar2;" type_identifier (pointer_declarator "**ppuVar2" * (pointer_declarator "*ppuVar2" * identifier)) ;) (declaration "int iVar3;" primitive_type identifier ;) (if_statement "if ((opt->flags & 8U) == 0) {\n    iVar1 = opt->key;\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" if (parenthesized_expression "((opt->flags & 8U) == 0)" ( (binary_expression "(opt->flags & 8U) == 0" (parenthesized_expression "(opt->flags & 8U)" ( (binary_expression "opt->flags & 8U" (field_expression "opt->flags" identifier -> field_identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n    iVar1 = opt->key;\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" { (expression_statement "iVar1 = opt->key;" (assignment_expression "iVar1 = opt->key" identifier = (field_expression "opt->key" identifier -> field_identifier)) ;) (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (if_statement "if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" if (parenthesized_expression "(iVar1 - 1U < 0xff)" ( (binary_expression "iVar1 - 1U < 0xff" (binary_expression "iVar1 - 1U" identifier - number_literal) < number_literal) )) (compound_statement "{\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" { (expression_statement "ppuVar2 = __ctype_b_loc();" (assignment_expression "ppuVar2 = __ctype_b_loc()" identifier = (call_expression "__ctype_b_loc()" identifier (argument_list "()" ( )))) ;) (if_statement "if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }" if (parenthesized_expression "((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0)" ( (binary_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0" (parenthesized_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40)" ( (binary_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" * (cast_expression "(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*ppuVar2 + iVar1 * 2 + 1)" ( (binary_expression "(int)*ppuVar2 + iVar1 * 2 + 1" (binary_expression "(int)*ppuVar2 + iVar1 * 2" (cast_expression "(int)*ppuVar2" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*ppuVar2" * identifier)) + (binary_expression "iVar1 * 2" identifier * number_literal)) + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n        iVar3 = iVar1;\n      }" { (expression_statement "iVar3 = iVar1;" (assignment_expression "iVar3 = iVar1" identifier = identifier) ;) })) })) (return_statement "return iVar3;" return identifier ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "int FUN_00024260(int param_1)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}\n\n" (function_definition "int FUN_00024260(int param_1)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" primitive_type (function_declarator "FUN_00024260(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "ushort **ppuVar2;" type_identifier (pointer_declarator "**ppuVar2" * (pointer_declarator "*ppuVar2" * identifier)) ;) (declaration "int iVar3;" primitive_type identifier ;) (if_statement "if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" if (parenthesized_expression "((*(uint *)(param_1 + 0xc) & 8) == 0)" ( (binary_expression "(*(uint *)(param_1 + 0xc) & 8) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0xc) & 8)" ( (binary_expression "*(uint *)(param_1 + 0xc) & 8" (pointer_expression "*(uint *)(param_1 + 0xc)" * (cast_expression "(uint *)(param_1 + 0xc)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" { (expression_statement "iVar1 = *(int *)(param_1 + 4);" (assignment_expression "iVar1 = *(int *)(param_1 + 4)" identifier = (pointer_expression "*(int *)(param_1 + 4)" * (cast_expression "(int *)(param_1 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" identifier = number_literal) ;) (if_statement "if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" if (parenthesized_expression "(iVar1 - 1U < 0xff)" ( (binary_expression "iVar1 - 1U < 0xff" (binary_expression "iVar1 - 1U" identifier - number_literal) < number_literal) )) (compound_statement "{\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" { (expression_statement "ppuVar2 = __ctype_b_loc();" (assignment_expression "ppuVar2 = __ctype_b_loc()" identifier = (call_expression "__ctype_b_loc()" identifier (argument_list "()" ( )))) ;) (if_statement "if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }" if (parenthesized_expression "((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0)" ( (binary_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0" (parenthesized_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40)" ( (binary_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" * (cast_expression "(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*ppuVar2 + iVar1 * 2 + 1)" ( (binary_expression "(int)*ppuVar2 + iVar1 * 2 + 1" (binary_expression "(int)*ppuVar2 + iVar1 * 2" (cast_expression "(int)*ppuVar2" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*ppuVar2" * identifier)) + (binary_expression "iVar1 * 2" identifier * number_literal)) + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n        iVar3 = iVar1;\n      }" { (expression_statement "iVar3 = iVar1;" (assignment_expression "iVar3 = iVar1" identifier = identifier) ;) })) })) (return_statement "return iVar3;" return identifier ;) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * (pointer_declarator * IDENT)) ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT) )) == LIT) )) (compound_statement { (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) ;) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression IDENT - LIT) < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) (pointer_expression * IDENT)) + (binary_expression IDENT * LIT)) + LIT) )))) & LIT) )) != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) })) })) (return_statement return IDENT ;) })) (return_statement return LIT ;) })))
(function_definition "int FUN_00024260(int param_1)\n\n{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" (primitive_type "int") (function_declarator "FUN_00024260(int param_1)" (identifier "FUN_00024260") (parameter_list "(int param_1)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) () ")"))) (compound_statement "{\n  int iVar1;\n  ushort **ppuVar2;\n  int iVar3;\n  \n  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }\n  return 0;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "ushort **ppuVar2;" (type_identifier "ushort") (pointer_declarator "**ppuVar2" (* "*") (pointer_declarator "*ppuVar2" (* "*") (identifier "ppuVar2"))) (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (if_statement "if ((*(uint *)(param_1 + 0xc) & 8) == 0) {\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" (if "if") (parenthesized_expression "((*(uint *)(param_1 + 0xc) & 8) == 0)" (( "(") (binary_expression "(*(uint *)(param_1 + 0xc) & 8) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0xc) & 8)" (( "(") (binary_expression "*(uint *)(param_1 + 0xc) & 8" (pointer_expression "*(uint *)(param_1 + 0xc)" (* "*") (cast_expression "(uint *)(param_1 + 0xc)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) (& "&") (number_literal "8")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    iVar1 = *(int *)(param_1 + 4);\n    iVar3 = 0;\n    if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }\n    return iVar3;\n  }" ({ "{") (expression_statement "iVar1 = *(int *)(param_1 + 4);" (assignment_expression "iVar1 = *(int *)(param_1 + 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(param_1 + 4)" (* "*") (cast_expression "(int *)(param_1 + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (expression_statement "iVar3 = 0;" (assignment_expression "iVar3 = 0" (identifier "iVar3") (= "=") (number_literal "0")) (; ";")) (if_statement "if (iVar1 - 1U < 0xff) {\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" (if "if") (parenthesized_expression "(iVar1 - 1U < 0xff)" (( "(") (binary_expression "iVar1 - 1U < 0xff" (binary_expression "iVar1 - 1U" (identifier "iVar1") (- "-") (number_literal "1U")) (< "<") (number_literal "0xff")) () ")")) (compound_statement "{\n      ppuVar2 = __ctype_b_loc();\n      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }\n    }" ({ "{") (expression_statement "ppuVar2 = __ctype_b_loc();" (assignment_expression "ppuVar2 = __ctype_b_loc()" (identifier "ppuVar2") (= "=") (call_expression "__ctype_b_loc()" (identifier "__ctype_b_loc") (argument_list "()" (( "(") () ")")))) (; ";")) (if_statement "if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {\n        iVar3 = iVar1;\n      }" (if "if") (parenthesized_expression "((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0)" (( "(") (binary_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0" (parenthesized_expression "(*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40)" (( "(") (binary_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" (* "*") (cast_expression "(byte *)((int)*ppuVar2 + iVar1 * 2 + 1)" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)*ppuVar2 + iVar1 * 2 + 1)" (( "(") (binary_expression "(int)*ppuVar2 + iVar1 * 2 + 1" (binary_expression "(int)*ppuVar2 + iVar1 * 2" (cast_expression "(int)*ppuVar2" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (pointer_expression "*ppuVar2" (* "*") (identifier "ppuVar2"))) (+ "+") (binary_expression "iVar1 * 2" (identifier "iVar1") (* "*") (number_literal "2"))) (+ "+") (number_literal "1")) () ")")))) (& "&") (number_literal "0x40")) () ")")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        iVar3 = iVar1;\n      }" ({ "{") (expression_statement "iVar3 = iVar1;" (assignment_expression "iVar3 = iVar1" (identifier "iVar3") (= "=") (identifier "iVar1")) (; ";")) (} "}"))) (} "}"))) (return_statement "return iVar3;" (return "return") (identifier "iVar3") (; ";")) (} "}"))) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}")))

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

int function_1(type_1 *opt,type_1 *real,char *domain,void *cookie)

{
  int var_1;
  type_2 **ppuVar2;
  int iVar3;
  
  if ((opt->flags & 8U) == 0) {
    var_1 = opt->key;
    iVar3 = 0;
    if (var_1 - 1U < 0xff) {
      ppuVar2 = var_2();
      if ((*(type_3 *)((int)*ppuVar2 + var_1 * 2 + 1) & 0x40) != 0) {
        iVar3 = var_1;
      }
    }
    return iVar3;
  }
  return 0;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (pointer_declarator declarator: (identifier)))) (declaration type: (primitive_type) declarator: (identifier)) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (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))) (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (pointer_expression argument: (identifier))) right: (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))))) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (identifier))))))) (return_statement (identifier)))) (return_statement (number_literal)))))

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

int MASKED(int param_1)

{
  int iVar1;
  ushort **ppuVar2;
  int iVar3;
  
  if ((*(uint *)(param_1 + 0xc) & 8) == 0) {
    iVar1 = *(int *)(param_1 + 4);
    iVar3 = 0;
    if (iVar1 - 1U < 0xff) {
      ppuVar2 = __ctype_b_loc();
      if ((*(byte *)((int)*ppuVar2 + iVar1 * 2 + 1) & 0x40) != 0) {
        iVar3 = iVar1;
      }
    }
    return iVar3;
  }
  return 0;
}

