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

int fontinfo_realname_compare(void *av,void *bv)

{
  uint uVar1;
  int iVar2;
  
                    /* WARNING: Load size is inaccurate */
                    /* WARNING: Load size is inaccurate */
  iVar2 = *av;
  uVar1 = (uint)(*bv == 0) - (uint)(iVar2 == 0);
  if (uVar1 == 0) {
    if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {
      return iVar2;
    }
    uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;
    if (uVar1 != 0) {
      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;
    }
  }
  return uVar1;
}



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

uint FUN_0005a150(int *param_1,int *param_2)

{
  int iVar1;
  uint uVar2;
  
  iVar1 = *param_1;
  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);
  if (uVar2 == 0) {
    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {
      return uVar2;
    }
    uVar2 = (param_1[6] ^ param_2[6]) & 7;
    if (uVar2 != 0) {
      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;
    }
  }
  return uVar2;
}


PUSH EBP
XOR EAX,EAX
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x0001a360
ADD EBX,0x5b689
SUB ESP,0xc
MOV EDI,dword ptr [ESP + 0x24]
MOV ESI,dword ptr [ESP + 0x20]
MOV EBP,dword ptr [EDI]
MOV EDX,dword ptr [ESI]
TEST EBP,EBP
SETZ AL
XOR ECX,ECX
TEST EDX,EDX
SETZ CL
SUB EAX,ECX
JNZ 0x0005a1a4
TEST EDX,EDX
JZ 0x0005a195
SUB ESP,0x8
PUSH EBP
PUSH EDX
CALL 0x000198f0
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x0005a1a4
MOV ECX,dword ptr [ESI + 0x18]
MOV EDX,dword ptr [EDI + 0x18]
MOV EAX,ECX
XOR EAX,EDX
AND EAX,0x7
JNZ 0x0005a1b0
ADD ESP,0xc
POP EBX
POP ESI
POP EDI
POP EBP
RET
AND ECX,0x7
AND EDX,0x7
XOR EAX,EAX
CMP ECX,EDX
SETGE AL
ADD ESP,0xc
POP EBX
LEA EAX,[EAX + EAX*0x1 + -0x1]
POP ESI
POP EDI
POP EBP
RET
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nuint FUN_0005a150(int *param_1,int *param_2)\n\n{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}\n\n" comment (function_definition "uint FUN_0005a150(int *param_1,int *param_2)\n\n{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}" type_identifier (function_declarator "FUN_0005a150(int *param_1,int *param_2)" identifier (parameter_list "(int *param_1,int *param_2)" ( (parameter_declaration "int *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "iVar1 = *param_1;" (assignment_expression "iVar1 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);" (assignment_expression "uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0)" identifier = (binary_expression "(uint)(*param_2 == 0) - (uint)(iVar1 == 0)" (call_expression "(uint)(*param_2 == 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(*param_2 == 0)" ( (binary_expression "*param_2 == 0" (pointer_expression "*param_2" * identifier) == number_literal) ))) - (call_expression "(uint)(iVar1 == 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) ))))) ;) (if_statement "if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }" if (parenthesized_expression "(uVar2 == 0)" ( (binary_expression "uVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }" { (if_statement "if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }" if (parenthesized_expression "((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0))" ( (binary_expression "(iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)" (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) && (parenthesized_expression "(uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)" ( (comma_expression "uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0" (assignment_expression "uVar2 = g_ascii_strcasecmp(iVar1,*param_2)" identifier = (call_expression "g_ascii_strcasecmp(iVar1,*param_2)" identifier (argument_list "(iVar1,*param_2)" ( identifier , (pointer_expression "*param_2" * identifier) )))) , (binary_expression "uVar2 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n      return uVar2;\n    }" { (return_statement "return uVar2;" return identifier ;) })) (expression_statement "uVar2 = (param_1[6] ^ param_2[6]) & 7;" (assignment_expression "uVar2 = (param_1[6] ^ param_2[6]) & 7" identifier = (binary_expression "(param_1[6] ^ param_2[6]) & 7" (parenthesized_expression "(param_1[6] ^ param_2[6])" ( (binary_expression "param_1[6] ^ param_2[6]" (subscript_expression "param_1[6]" identifier [ number_literal ]) ^ (subscript_expression "param_2[6]" identifier [ number_literal ])) )) & number_literal)) ;) (if_statement "if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }" if (parenthesized_expression "(uVar2 != 0)" ( (binary_expression "uVar2 != 0" identifier != number_literal) )) (compound_statement "{\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }" { (return_statement "return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;" return (binary_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1" (binary_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2" (call_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U))" (parenthesized_expression "(uint)" ( identifier )) (argument_list "((param_2[6] & 7U) <= (param_1[6] & 7U))" ( (binary_expression "(param_2[6] & 7U) <= (param_1[6] & 7U)" (parenthesized_expression "(param_2[6] & 7U)" ( (binary_expression "param_2[6] & 7U" (subscript_expression "param_2[6]" identifier [ number_literal ]) & number_literal) )) <= (parenthesized_expression "(param_1[6] & 7U)" ( (binary_expression "param_1[6] & 7U" (subscript_expression "param_1[6]" identifier [ number_literal ]) & number_literal) ))) ))) * number_literal) - number_literal) ;) })) })) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nint fontinfo_realname_compare(void *av,void *bv)\n\n{\n  uint uVar1;\n  int iVar2;\n  \n                    /* WARNING: Load size is inaccurate */\n                    /* WARNING: Load size is inaccurate */\n  iVar2 = *av;\n  uVar1 = (uint)(*bv == 0) - (uint)(iVar2 == 0);\n  if (uVar1 == 0) {\n    if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {\n      return iVar2;\n    }\n    uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;\n    if (uVar1 != 0) {\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }\n  }\n  return uVar1;\n}\n\n" comment comment (function_definition "int fontinfo_realname_compare(void *av,void *bv)\n\n{\n  uint uVar1;\n  int iVar2;\n  \n                    /* WARNING: Load size is inaccurate */\n                    /* WARNING: Load size is inaccurate */\n  iVar2 = *av;\n  uVar1 = (uint)(*bv == 0) - (uint)(iVar2 == 0);\n  if (uVar1 == 0) {\n    if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {\n      return iVar2;\n    }\n    uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;\n    if (uVar1 != 0) {\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }\n  }\n  return uVar1;\n}" primitive_type (function_declarator "fontinfo_realname_compare(void *av,void *bv)" identifier (parameter_list "(void *av,void *bv)" ( (parameter_declaration "void *av" primitive_type (pointer_declarator "*av" * identifier)) , (parameter_declaration "void *bv" primitive_type (pointer_declarator "*bv" * identifier)) ))) (compound_statement "{\n  uint uVar1;\n  int iVar2;\n  \n                    /* WARNING: Load size is inaccurate */\n                    /* WARNING: Load size is inaccurate */\n  iVar2 = *av;\n  uVar1 = (uint)(*bv == 0) - (uint)(iVar2 == 0);\n  if (uVar1 == 0) {\n    if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {\n      return iVar2;\n    }\n    uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;\n    if (uVar1 != 0) {\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }\n  }\n  return uVar1;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) comment comment (expression_statement "iVar2 = *av;" (assignment_expression "iVar2 = *av" identifier = (pointer_expression "*av" * identifier)) ;) (expression_statement "uVar1 = (uint)(*bv == 0) - (uint)(iVar2 == 0);" (assignment_expression "uVar1 = (uint)(*bv == 0) - (uint)(iVar2 == 0)" identifier = (binary_expression "(uint)(*bv == 0) - (uint)(iVar2 == 0)" (call_expression "(uint)(*bv == 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(*bv == 0)" ( (binary_expression "*bv == 0" (pointer_expression "*bv" * identifier) == number_literal) ))) - (call_expression "(uint)(iVar2 == 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) ))))) ;) (if_statement "if (uVar1 == 0) {\n    if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {\n      return iVar2;\n    }\n    uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;\n    if (uVar1 != 0) {\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }\n  }" if (parenthesized_expression "(uVar1 == 0)" ( (binary_expression "uVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {\n      return iVar2;\n    }\n    uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;\n    if (uVar1 != 0) {\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }\n  }" { (if_statement "if ((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)) {\n      return iVar2;\n    }" if (parenthesized_expression "((iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0))" ( (binary_expression "(iVar2 != 0) && (iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)" (parenthesized_expression "(iVar2 != 0)" ( (binary_expression "iVar2 != 0" identifier != number_literal) )) && (parenthesized_expression "(iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0)" ( (comma_expression "iVar2 = g_ascii_strcasecmp(iVar2,*bv), iVar2 != 0" (assignment_expression "iVar2 = g_ascii_strcasecmp(iVar2,*bv)" identifier = (call_expression "g_ascii_strcasecmp(iVar2,*bv)" identifier (argument_list "(iVar2,*bv)" ( identifier , (pointer_expression "*bv" * identifier) )))) , (binary_expression "iVar2 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n      return iVar2;\n    }" { (return_statement "return iVar2;" return identifier ;) })) (expression_statement "uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7;" (assignment_expression "uVar1 = (*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7" identifier = (binary_expression "(*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)) & 7" (parenthesized_expression "(*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18))" ( (binary_expression "*(uint *)((int)av + 0x18) ^ *(uint *)((int)bv + 0x18)" (pointer_expression "*(uint *)((int)av + 0x18)" * (cast_expression "(uint *)((int)av + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)av + 0x18)" ( (binary_expression "(int)av + 0x18" (cast_expression "(int)av" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) ^ (pointer_expression "*(uint *)((int)bv + 0x18)" * (cast_expression "(uint *)((int)bv + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)bv + 0x18)" ( (binary_expression "(int)bv + 0x18" (cast_expression "(int)bv" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) ))))) )) & number_literal)) ;) (if_statement "if (uVar1 != 0) {\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }" if (parenthesized_expression "(uVar1 != 0)" ( (binary_expression "uVar1 != 0" identifier != number_literal) )) (compound_statement "{\n      return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;\n    }" { (return_statement "return (uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1;" return (binary_expression "(uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2 + -1" (binary_expression "(uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)) * 2" (call_expression "(uint)((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7))" (parenthesized_expression "(uint)" ( identifier )) (argument_list "((*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7))" ( (binary_expression "(*(uint *)((int)bv + 0x18) & 7) <= (*(uint *)((int)av + 0x18) & 7)" (parenthesized_expression "(*(uint *)((int)bv + 0x18) & 7)" ( (binary_expression "*(uint *)((int)bv + 0x18) & 7" (pointer_expression "*(uint *)((int)bv + 0x18)" * (cast_expression "(uint *)((int)bv + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)bv + 0x18)" ( (binary_expression "(int)bv + 0x18" (cast_expression "(int)bv" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) & number_literal) )) <= (parenthesized_expression "(*(uint *)((int)av + 0x18) & 7)" ( (binary_expression "*(uint *)((int)av + 0x18) & 7" (pointer_expression "*(uint *)((int)av + 0x18)" * (cast_expression "(uint *)((int)av + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)av + 0x18)" ( (binary_expression "(int)av + 0x18" (cast_expression "(int)av" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal) )))) & number_literal) ))) ))) * number_literal) + number_literal) ;) })) })) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit "uint FUN_0005a150(int *param_1,int *param_2)\n\n{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}\n\n" (function_definition "uint FUN_0005a150(int *param_1,int *param_2)\n\n{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}" type_identifier (function_declarator "FUN_0005a150(int *param_1,int *param_2)" identifier (parameter_list "(int *param_1,int *param_2)" ( (parameter_declaration "int *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "iVar1 = *param_1;" (assignment_expression "iVar1 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);" (assignment_expression "uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0)" identifier = (binary_expression "(uint)(*param_2 == 0) - (uint)(iVar1 == 0)" (call_expression "(uint)(*param_2 == 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(*param_2 == 0)" ( (binary_expression "*param_2 == 0" (pointer_expression "*param_2" * identifier) == number_literal) ))) - (call_expression "(uint)(iVar1 == 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) ))))) ;) (if_statement "if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }" if (parenthesized_expression "(uVar2 == 0)" ( (binary_expression "uVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }" { (if_statement "if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }" if (parenthesized_expression "((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0))" ( (binary_expression "(iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)" (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) && (parenthesized_expression "(uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)" ( (comma_expression "uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0" (assignment_expression "uVar2 = g_ascii_strcasecmp(iVar1,*param_2)" identifier = (call_expression "g_ascii_strcasecmp(iVar1,*param_2)" identifier (argument_list "(iVar1,*param_2)" ( identifier , (pointer_expression "*param_2" * identifier) )))) , (binary_expression "uVar2 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n      return uVar2;\n    }" { (return_statement "return uVar2;" return identifier ;) })) (expression_statement "uVar2 = (param_1[6] ^ param_2[6]) & 7;" (assignment_expression "uVar2 = (param_1[6] ^ param_2[6]) & 7" identifier = (binary_expression "(param_1[6] ^ param_2[6]) & 7" (parenthesized_expression "(param_1[6] ^ param_2[6])" ( (binary_expression "param_1[6] ^ param_2[6]" (subscript_expression "param_1[6]" identifier [ number_literal ]) ^ (subscript_expression "param_2[6]" identifier [ number_literal ])) )) & number_literal)) ;) (if_statement "if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }" if (parenthesized_expression "(uVar2 != 0)" ( (binary_expression "uVar2 != 0" identifier != number_literal) )) (compound_statement "{\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }" { (return_statement "return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;" return (binary_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1" (binary_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2" (call_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U))" (parenthesized_expression "(uint)" ( identifier )) (argument_list "((param_2[6] & 7U) <= (param_1[6] & 7U))" ( (binary_expression "(param_2[6] & 7U) <= (param_1[6] & 7U)" (parenthesized_expression "(param_2[6] & 7U)" ( (binary_expression "param_2[6] & 7U" (subscript_expression "param_2[6]" identifier [ number_literal ]) & number_literal) )) <= (parenthesized_expression "(param_1[6] & 7U)" ( (binary_expression "param_1[6] & 7U" (subscript_expression "param_1[6]" identifier [ number_literal ]) & number_literal) ))) ))) * number_literal) - number_literal) ;) })) })) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (pointer_expression * IDENT) == LIT) ))) - (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT == LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * IDENT) )))) , (binary_expression IDENT != LIT)) ))) )) (compound_statement { (return_statement return IDENT ;) })) (expression_statement (assignment_expression IDENT = (binary_expression (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) ^ (subscript_expression IDENT [ LIT ])) )) & LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (return_statement return (binary_expression (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) & LIT) )) <= (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) & LIT) ))) ))) * LIT) - LIT) ;) })) })) (return_statement return IDENT ;) })))
(function_definition "uint FUN_0005a150(int *param_1,int *param_2)\n\n{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}" (type_identifier "uint") (function_declarator "FUN_0005a150(int *param_1,int *param_2)" (identifier "FUN_0005a150") (parameter_list "(int *param_1,int *param_2)" (( "(") (parameter_declaration "int *param_1" (primitive_type "int") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "int *param_2" (primitive_type "int") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")"))) (compound_statement "{\n  int iVar1;\n  uint uVar2;\n  \n  iVar1 = *param_1;\n  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);\n  if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }\n  return uVar2;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "uint uVar2;" (type_identifier "uint") (identifier "uVar2") (; ";")) (expression_statement "iVar1 = *param_1;" (assignment_expression "iVar1 = *param_1" (identifier "iVar1") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";")) (expression_statement "uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);" (assignment_expression "uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0)" (identifier "uVar2") (= "=") (binary_expression "(uint)(*param_2 == 0) - (uint)(iVar1 == 0)" (call_expression "(uint)(*param_2 == 0)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "(*param_2 == 0)" (( "(") (binary_expression "*param_2 == 0" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (== "==") (number_literal "0")) () ")"))) (- "-") (call_expression "(uint)(iVar1 == 0)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "(iVar1 == 0)" (( "(") (binary_expression "iVar1 == 0" (identifier "iVar1") (== "==") (number_literal "0")) () ")"))))) (; ";")) (if_statement "if (uVar2 == 0) {\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }" (if "if") (parenthesized_expression "(uVar2 == 0)" (( "(") (binary_expression "uVar2 == 0" (identifier "uVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }\n    uVar2 = (param_1[6] ^ param_2[6]) & 7;\n    if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }\n  }" ({ "{") (if_statement "if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {\n      return uVar2;\n    }" (if "if") (parenthesized_expression "((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0))" (( "(") (binary_expression "(iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)" (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "(uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)" (( "(") (comma_expression "uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0" (assignment_expression "uVar2 = g_ascii_strcasecmp(iVar1,*param_2)" (identifier "uVar2") (= "=") (call_expression "g_ascii_strcasecmp(iVar1,*param_2)" (identifier "g_ascii_strcasecmp") (argument_list "(iVar1,*param_2)" (( "(") (identifier "iVar1") (, ",") (pointer_expression "*param_2" (* "*") (identifier "param_2")) () ")")))) (, ",") (binary_expression "uVar2 != 0" (identifier "uVar2") (!= "!=") (number_literal "0"))) () ")"))) () ")")) (compound_statement "{\n      return uVar2;\n    }" ({ "{") (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}"))) (expression_statement "uVar2 = (param_1[6] ^ param_2[6]) & 7;" (assignment_expression "uVar2 = (param_1[6] ^ param_2[6]) & 7" (identifier "uVar2") (= "=") (binary_expression "(param_1[6] ^ param_2[6]) & 7" (parenthesized_expression "(param_1[6] ^ param_2[6])" (( "(") (binary_expression "param_1[6] ^ param_2[6]" (subscript_expression "param_1[6]" (identifier "param_1") ([ "[") (number_literal "6") (] "]")) (^ "^") (subscript_expression "param_2[6]" (identifier "param_2") ([ "[") (number_literal "6") (] "]"))) () ")")) (& "&") (number_literal "7"))) (; ";")) (if_statement "if (uVar2 != 0) {\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }" (if "if") (parenthesized_expression "(uVar2 != 0)" (( "(") (binary_expression "uVar2 != 0" (identifier "uVar2") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;\n    }" ({ "{") (return_statement "return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;" (return "return") (binary_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1" (binary_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2" (call_expression "(uint)((param_2[6] & 7U) <= (param_1[6] & 7U))" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "((param_2[6] & 7U) <= (param_1[6] & 7U))" (( "(") (binary_expression "(param_2[6] & 7U) <= (param_1[6] & 7U)" (parenthesized_expression "(param_2[6] & 7U)" (( "(") (binary_expression "param_2[6] & 7U" (subscript_expression "param_2[6]" (identifier "param_2") ([ "[") (number_literal "6") (] "]")) (& "&") (number_literal "7U")) () ")")) (<= "<=") (parenthesized_expression "(param_1[6] & 7U)" (( "(") (binary_expression "param_1[6] & 7U" (subscript_expression "param_1[6]" (identifier "param_1") ([ "[") (number_literal "6") (] "]")) (& "&") (number_literal "7U")) () ")"))) () ")"))) (* "*") (number_literal "2")) (- "-") (number_literal "1")) (; ";")) (} "}"))) (} "}"))) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}")))

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

int function_1(void *av,void *bv)

{
  type_1 var_2;
  int var_1;
  
                    /* WARNING: Load size is inaccurate */
                    /* WARNING: Load size is inaccurate */
  var_1 = *av;
  var_2 = (type_1)(*bv == 0) - (type_1)(var_1 == 0);
  if (var_2 == 0) {
    if ((var_1 != 0) && (var_1 = var_3(var_1,*bv), var_1 != 0)) {
      return var_1;
    }
    var_2 = (*(type_1 *)((int)av + 0x18) ^ *(type_1 *)((int)bv + 0x18)) & 7;
    if (var_2 != 0) {
      return (type_1)((*(type_1 *)((int)bv + 0x18) & 7) <= (*(type_1 *)((int)av + 0x18) & 7)) * 2 + -1;
    }
  }
  return var_2;
}


(translation_unit (function_definition type: (type_identifier) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal)))) right: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier))))) right: (binary_expression left: (identifier) right: (number_literal)))))) consequence: (compound_statement (return_statement (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (subscript_expression argument: (identifier) index: (number_literal)))) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (binary_expression left: (binary_expression left: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)))))) right: (number_literal)) right: (number_literal))))))) (return_statement (identifier)))))

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

uint MASKED(int *param_1,int *param_2)

{
  int iVar1;
  uint uVar2;
  
  iVar1 = *param_1;
  uVar2 = (uint)(*param_2 == 0) - (uint)(iVar1 == 0);
  if (uVar2 == 0) {
    if ((iVar1 != 0) && (uVar2 = g_ascii_strcasecmp(iVar1,*param_2), uVar2 != 0)) {
      return uVar2;
    }
    uVar2 = (param_1[6] ^ param_2[6]) & 7;
    if (uVar2 != 0) {
      return (uint)((param_2[6] & 7U) <= (param_1[6] & 7U)) * 2 - 1;
    }
  }
  return uVar2;
}

