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

int fnmatch_no_wildcards(char *pattern,char *f,int options)

{
  size_t __n;
  int iVar1;
  char *s2;
  char *pcVar2;
  
  if ((options & 8U) == 0) {
    if ((options & 0x10U) != 0) {
      iVar1 = mbscasecmp(pattern,f);
      return iVar1;
    }
    iVar1 = strcmp(pattern,f);
    return iVar1;
  }
  if ((options & 0x10U) == 0) {
    __n = strlen(pattern);
    iVar1 = strncmp(pattern,f,__n);
    if ((iVar1 == 0) && (f[__n] != 0x2f)) {
      iVar1 = (int)f[__n];
    }
    return iVar1;
  }
  s2 = xstrdup(f);
  pcVar2 = s2;
  while( true ) {
    pcVar2 = strchr(pcVar2,0x2f);
    if (pcVar2 == (char *)0x0) break;
    *pcVar2 = '\0';
    iVar1 = mbscasecmp(pattern,s2);
    if (iVar1 < 1) goto LAB_0001545b;
    *pcVar2 = '/';
    pcVar2 = pcVar2 + 1;
  }
  iVar1 = mbscasecmp(pattern,s2);
LAB_0001545b:
  free(s2);
  return iVar1;
}



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

int FUN_000153b0(char *param_1,char *param_2,uint param_3)

{
  size_t __n;
  int iVar1;
  char *__ptr;
  char *pcVar2;
  
  if ((param_3 & 8) == 0) {
    if ((param_3 & 0x10) != 0) {
      iVar1 = FUN_0001b2c0(param_1,param_2);
      return iVar1;
    }
    iVar1 = strcmp(param_1,param_2);
    return iVar1;
  }
  if ((param_3 & 0x10) == 0) {
    __n = strlen(param_1);
    iVar1 = strncmp(param_1,param_2,__n);
    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {
      iVar1 = (int)param_2[__n];
    }
    return iVar1;
  }
  __ptr = (char *)FUN_0001e5e0(param_2);
  pcVar2 = __ptr;
  while( true ) {
    pcVar2 = strchr(pcVar2,0x2f);
    if (pcVar2 == (char *)0x0) break;
    *pcVar2 = '\0';
    iVar1 = FUN_0001b2c0(param_1,__ptr);
    if (iVar1 < 1) goto LAB_0001545b;
    *pcVar2 = '/';
    pcVar2 = pcVar2 + 1;
  }
  iVar1 = FUN_0001b2c0(param_1,__ptr);
LAB_0001545b:
  free(__ptr);
  return iVar1;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00014080
ADD EBX,0x37c47
SUB ESP,0x1c
MOV EAX,dword ptr [ESP + 0x38]
MOV EDI,dword ptr [ESP + 0x30]
MOV ESI,dword ptr [ESP + 0x34]
MOV EDX,EAX
AND EDX,0x10
TEST AL,0x8
JZ 0x00015480
TEST EDX,EDX
JNZ 0x00015410
SUB ESP,0xc
PUSH EDI
CALL 0x000123c0
ADD ESP,0xc
PUSH EAX
MOV EBP,EAX
PUSH ESI
PUSH EDI
CALL 0x00012600
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x00015406
MOVSX EDX,byte ptr [ESI + EBP*0x1]
CMP EDX,0x2f
CMOVNZ EAX,EDX
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0xc
PUSH ESI
CALL 0x0001e5e0
ADD ESP,0x10
MOV EBP,EAX
JMP 0x0001543a
SUB ESP,0x8
MOV byte ptr [EAX],0x0
PUSH EBP
PUSH EDI
CALL 0x0001b2c0
ADD ESP,0x10
TEST EAX,EAX
JLE 0x0001545b
MOV byte ptr [ESI],0x2f
LEA EAX,[ESI + 0x1]
SUB ESP,0x8
PUSH 0x2f
PUSH EAX
CALL 0x000123b0
ADD ESP,0x10
MOV ESI,EAX
TEST EAX,EAX
JNZ 0x00015420
SUB ESP,0x8
PUSH EBP
PUSH EDI
CALL 0x0001b2c0
ADD ESP,0x10
MOV dword ptr [ESP + 0xc],EAX
SUB ESP,0xc
PUSH EBP
CALL 0x000126c0
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0xc]
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
TEST EDX,EDX
JZ 0x000154a0
SUB ESP,0x8
PUSH ESI
PUSH EDI
CALL 0x0001b2c0
ADD ESP,0x10
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
SUB ESP,0x8
PUSH ESI
PUSH EDI
CALL 0x000120a0
ADD ESP,0x10
ADD ESP,0x1c
POP EBX
POP ESI
POP EDI
POP EBP
RET
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint FUN_000153b0(char *param_1,char *param_2,uint param_3)\n\n{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}\n\n" comment (function_definition "int FUN_000153b0(char *param_1,char *param_2,uint param_3)\n\n{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}" primitive_type (function_declarator "FUN_000153b0(char *param_1,char *param_2,uint param_3)" identifier (parameter_list "(char *param_1,char *param_2,uint param_3)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "uint param_3" type_identifier identifier) ))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (declaration "char *__ptr;" primitive_type (pointer_declarator "*__ptr" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }" if (parenthesized_expression "((param_3 & 8) == 0)" ( (binary_expression "(param_3 & 8) == 0" (parenthesized_expression "(param_3 & 8)" ( (binary_expression "param_3 & 8" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }" { (if_statement "if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }" if (parenthesized_expression "((param_3 & 0x10) != 0)" ( (binary_expression "(param_3 & 0x10) != 0" (parenthesized_expression "(param_3 & 0x10)" ( (binary_expression "param_3 & 0x10" identifier & number_literal) )) != number_literal) )) (compound_statement "{\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }" { (expression_statement "iVar1 = FUN_0001b2c0(param_1,param_2);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,param_2)" identifier = (call_expression "FUN_0001b2c0(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })) (expression_statement "iVar1 = strcmp(param_1,param_2);" (assignment_expression "iVar1 = strcmp(param_1,param_2)" identifier = (call_expression "strcmp(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })) (if_statement "if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }" if (parenthesized_expression "((param_3 & 0x10) == 0)" ( (binary_expression "(param_3 & 0x10) == 0" (parenthesized_expression "(param_3 & 0x10)" ( (binary_expression "param_3 & 0x10" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }" { (expression_statement "__n = strlen(param_1);" (assignment_expression "__n = strlen(param_1)" identifier = (call_expression "strlen(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (expression_statement "iVar1 = strncmp(param_1,param_2,__n);" (assignment_expression "iVar1 = strncmp(param_1,param_2,__n)" identifier = (call_expression "strncmp(param_1,param_2,__n)" identifier (argument_list "(param_1,param_2,__n)" ( identifier , identifier , identifier )))) ;) (if_statement "if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }" if (parenthesized_expression "((iVar1 == 0) && (param_2[__n] != 0x2f))" ( (binary_expression "(iVar1 == 0) && (param_2[__n] != 0x2f)" (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) && (parenthesized_expression "(param_2[__n] != 0x2f)" ( (binary_expression "param_2[__n] != 0x2f" (subscript_expression "param_2[__n]" identifier [ identifier ]) != number_literal) ))) )) (compound_statement "{\n      iVar1 = (int)param_2[__n];\n    }" { (expression_statement "iVar1 = (int)param_2[__n];" (assignment_expression "iVar1 = (int)param_2[__n]" identifier = (cast_expression "(int)param_2[__n]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "param_2[__n]" identifier [ identifier ]))) ;) })) (return_statement "return iVar1;" return identifier ;) })) (expression_statement "__ptr = (char *)FUN_0001e5e0(param_2);" (assignment_expression "__ptr = (char *)FUN_0001e5e0(param_2)" identifier = (cast_expression "(char *)FUN_0001e5e0(param_2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001e5e0(param_2)" identifier (argument_list "(param_2)" ( identifier ))))) ;) (expression_statement "pcVar2 = __ptr;" (assignment_expression "pcVar2 = __ptr" identifier = identifier) ;) (while_statement "while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" { (expression_statement "pcVar2 = strchr(pcVar2,0x2f);" (assignment_expression "pcVar2 = strchr(pcVar2,0x2f)" identifier = (call_expression "strchr(pcVar2,0x2f)" identifier (argument_list "(pcVar2,0x2f)" ( identifier , number_literal )))) ;) (if_statement "if (pcVar2 == (char *)0x0) break;" if (parenthesized_expression "(pcVar2 == (char *)0x0)" ( (binary_expression "pcVar2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (break_statement "break;" break ;)) (expression_statement "*pcVar2 = '\0';" (assignment_expression "*pcVar2 = '\0'" (pointer_expression "*pcVar2" * identifier) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "iVar1 = FUN_0001b2c0(param_1,__ptr);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,__ptr)" identifier = (call_expression "FUN_0001b2c0(param_1,__ptr)" identifier (argument_list "(param_1,__ptr)" ( identifier , identifier )))) ;) (if_statement "if (iVar1 < 1) goto LAB_0001545b;" if (parenthesized_expression "(iVar1 < 1)" ( (binary_expression "iVar1 < 1" identifier < number_literal) )) (goto_statement "goto LAB_0001545b;" goto statement_identifier ;)) (expression_statement "*pcVar2 = '/';" (assignment_expression "*pcVar2 = '/'" (pointer_expression "*pcVar2" * identifier) = (char_literal "'/'" ' character ')) ;) (expression_statement "pcVar2 = pcVar2 + 1;" (assignment_expression "pcVar2 = pcVar2 + 1" identifier = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) })) (expression_statement "iVar1 = FUN_0001b2c0(param_1,__ptr);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,__ptr)" identifier = (call_expression "FUN_0001b2c0(param_1,__ptr)" identifier (argument_list "(param_1,__ptr)" ( identifier , identifier )))) ;) (labeled_statement "LAB_0001545b:\n  free(__ptr);" statement_identifier : (expression_statement "free(__ptr);" (call_expression "free(__ptr)" identifier (argument_list "(__ptr)" ( identifier ))) ;)) (return_statement "return iVar1;" 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 fnmatch_no_wildcards(char *pattern,char *f,int options)\n\n{\n  size_t __n;\n  int iVar1;\n  char *s2;\n  char *pcVar2;\n  \n  if ((options & 8U) == 0) {\n    if ((options & 0x10U) != 0) {\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }\n    iVar1 = strcmp(pattern,f);\n    return iVar1;\n  }\n  if ((options & 0x10U) == 0) {\n    __n = strlen(pattern);\n    iVar1 = strncmp(pattern,f,__n);\n    if ((iVar1 == 0) && (f[__n] != 0x2f)) {\n      iVar1 = (int)f[__n];\n    }\n    return iVar1;\n  }\n  s2 = xstrdup(f);\n  pcVar2 = s2;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = mbscasecmp(pattern,s2);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = mbscasecmp(pattern,s2);\nLAB_0001545b:\n  free(s2);\n  return iVar1;\n}\n\n" comment comment (function_definition "int fnmatch_no_wildcards(char *pattern,char *f,int options)\n\n{\n  size_t __n;\n  int iVar1;\n  char *s2;\n  char *pcVar2;\n  \n  if ((options & 8U) == 0) {\n    if ((options & 0x10U) != 0) {\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }\n    iVar1 = strcmp(pattern,f);\n    return iVar1;\n  }\n  if ((options & 0x10U) == 0) {\n    __n = strlen(pattern);\n    iVar1 = strncmp(pattern,f,__n);\n    if ((iVar1 == 0) && (f[__n] != 0x2f)) {\n      iVar1 = (int)f[__n];\n    }\n    return iVar1;\n  }\n  s2 = xstrdup(f);\n  pcVar2 = s2;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = mbscasecmp(pattern,s2);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = mbscasecmp(pattern,s2);\nLAB_0001545b:\n  free(s2);\n  return iVar1;\n}" primitive_type (function_declarator "fnmatch_no_wildcards(char *pattern,char *f,int options)" identifier (parameter_list "(char *pattern,char *f,int options)" ( (parameter_declaration "char *pattern" primitive_type (pointer_declarator "*pattern" * identifier)) , (parameter_declaration "char *f" primitive_type (pointer_declarator "*f" * identifier)) , (parameter_declaration "int options" primitive_type identifier) ))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  char *s2;\n  char *pcVar2;\n  \n  if ((options & 8U) == 0) {\n    if ((options & 0x10U) != 0) {\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }\n    iVar1 = strcmp(pattern,f);\n    return iVar1;\n  }\n  if ((options & 0x10U) == 0) {\n    __n = strlen(pattern);\n    iVar1 = strncmp(pattern,f,__n);\n    if ((iVar1 == 0) && (f[__n] != 0x2f)) {\n      iVar1 = (int)f[__n];\n    }\n    return iVar1;\n  }\n  s2 = xstrdup(f);\n  pcVar2 = s2;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = mbscasecmp(pattern,s2);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = mbscasecmp(pattern,s2);\nLAB_0001545b:\n  free(s2);\n  return iVar1;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (declaration "char *s2;" primitive_type (pointer_declarator "*s2" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if ((options & 8U) == 0) {\n    if ((options & 0x10U) != 0) {\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }\n    iVar1 = strcmp(pattern,f);\n    return iVar1;\n  }" if (parenthesized_expression "((options & 8U) == 0)" ( (binary_expression "(options & 8U) == 0" (parenthesized_expression "(options & 8U)" ( (binary_expression "options & 8U" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    if ((options & 0x10U) != 0) {\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }\n    iVar1 = strcmp(pattern,f);\n    return iVar1;\n  }" { (if_statement "if ((options & 0x10U) != 0) {\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }" if (parenthesized_expression "((options & 0x10U) != 0)" ( (binary_expression "(options & 0x10U) != 0" (parenthesized_expression "(options & 0x10U)" ( (binary_expression "options & 0x10U" identifier & number_literal) )) != number_literal) )) (compound_statement "{\n      iVar1 = mbscasecmp(pattern,f);\n      return iVar1;\n    }" { (expression_statement "iVar1 = mbscasecmp(pattern,f);" (assignment_expression "iVar1 = mbscasecmp(pattern,f)" identifier = (call_expression "mbscasecmp(pattern,f)" identifier (argument_list "(pattern,f)" ( identifier , identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })) (expression_statement "iVar1 = strcmp(pattern,f);" (assignment_expression "iVar1 = strcmp(pattern,f)" identifier = (call_expression "strcmp(pattern,f)" identifier (argument_list "(pattern,f)" ( identifier , identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })) (if_statement "if ((options & 0x10U) == 0) {\n    __n = strlen(pattern);\n    iVar1 = strncmp(pattern,f,__n);\n    if ((iVar1 == 0) && (f[__n] != 0x2f)) {\n      iVar1 = (int)f[__n];\n    }\n    return iVar1;\n  }" if (parenthesized_expression "((options & 0x10U) == 0)" ( (binary_expression "(options & 0x10U) == 0" (parenthesized_expression "(options & 0x10U)" ( (binary_expression "options & 0x10U" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    __n = strlen(pattern);\n    iVar1 = strncmp(pattern,f,__n);\n    if ((iVar1 == 0) && (f[__n] != 0x2f)) {\n      iVar1 = (int)f[__n];\n    }\n    return iVar1;\n  }" { (expression_statement "__n = strlen(pattern);" (assignment_expression "__n = strlen(pattern)" identifier = (call_expression "strlen(pattern)" identifier (argument_list "(pattern)" ( identifier )))) ;) (expression_statement "iVar1 = strncmp(pattern,f,__n);" (assignment_expression "iVar1 = strncmp(pattern,f,__n)" identifier = (call_expression "strncmp(pattern,f,__n)" identifier (argument_list "(pattern,f,__n)" ( identifier , identifier , identifier )))) ;) (if_statement "if ((iVar1 == 0) && (f[__n] != 0x2f)) {\n      iVar1 = (int)f[__n];\n    }" if (parenthesized_expression "((iVar1 == 0) && (f[__n] != 0x2f))" ( (binary_expression "(iVar1 == 0) && (f[__n] != 0x2f)" (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) && (parenthesized_expression "(f[__n] != 0x2f)" ( (binary_expression "f[__n] != 0x2f" (subscript_expression "f[__n]" identifier [ identifier ]) != number_literal) ))) )) (compound_statement "{\n      iVar1 = (int)f[__n];\n    }" { (expression_statement "iVar1 = (int)f[__n];" (assignment_expression "iVar1 = (int)f[__n]" identifier = (cast_expression "(int)f[__n]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "f[__n]" identifier [ identifier ]))) ;) })) (return_statement "return iVar1;" return identifier ;) })) (expression_statement "s2 = xstrdup(f);" (assignment_expression "s2 = xstrdup(f)" identifier = (call_expression "xstrdup(f)" identifier (argument_list "(f)" ( identifier )))) ;) (expression_statement "pcVar2 = s2;" (assignment_expression "pcVar2 = s2" identifier = identifier) ;) (while_statement "while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = mbscasecmp(pattern,s2);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = mbscasecmp(pattern,s2);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" { (expression_statement "pcVar2 = strchr(pcVar2,0x2f);" (assignment_expression "pcVar2 = strchr(pcVar2,0x2f)" identifier = (call_expression "strchr(pcVar2,0x2f)" identifier (argument_list "(pcVar2,0x2f)" ( identifier , number_literal )))) ;) (if_statement "if (pcVar2 == (char *)0x0) break;" if (parenthesized_expression "(pcVar2 == (char *)0x0)" ( (binary_expression "pcVar2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (break_statement "break;" break ;)) (expression_statement "*pcVar2 = '\0';" (assignment_expression "*pcVar2 = '\0'" (pointer_expression "*pcVar2" * identifier) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "iVar1 = mbscasecmp(pattern,s2);" (assignment_expression "iVar1 = mbscasecmp(pattern,s2)" identifier = (call_expression "mbscasecmp(pattern,s2)" identifier (argument_list "(pattern,s2)" ( identifier , identifier )))) ;) (if_statement "if (iVar1 < 1) goto LAB_0001545b;" if (parenthesized_expression "(iVar1 < 1)" ( (binary_expression "iVar1 < 1" identifier < number_literal) )) (goto_statement "goto LAB_0001545b;" goto statement_identifier ;)) (expression_statement "*pcVar2 = '/';" (assignment_expression "*pcVar2 = '/'" (pointer_expression "*pcVar2" * identifier) = (char_literal "'/'" ' character ')) ;) (expression_statement "pcVar2 = pcVar2 + 1;" (assignment_expression "pcVar2 = pcVar2 + 1" identifier = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) })) (expression_statement "iVar1 = mbscasecmp(pattern,s2);" (assignment_expression "iVar1 = mbscasecmp(pattern,s2)" identifier = (call_expression "mbscasecmp(pattern,s2)" identifier (argument_list "(pattern,s2)" ( identifier , identifier )))) ;) (labeled_statement "LAB_0001545b:\n  free(s2);" statement_identifier : (expression_statement "free(s2);" (call_expression "free(s2)" identifier (argument_list "(s2)" ( identifier ))) ;)) (return_statement "return iVar1;" return identifier ;) })))
(translation_unit "int FUN_000153b0(char *param_1,char *param_2,uint param_3)\n\n{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}\n\n" (function_definition "int FUN_000153b0(char *param_1,char *param_2,uint param_3)\n\n{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}" primitive_type (function_declarator "FUN_000153b0(char *param_1,char *param_2,uint param_3)" identifier (parameter_list "(char *param_1,char *param_2,uint param_3)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "uint param_3" type_identifier identifier) ))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}" { (declaration "size_t __n;" primitive_type identifier ;) (declaration "int iVar1;" primitive_type identifier ;) (declaration "char *__ptr;" primitive_type (pointer_declarator "*__ptr" * identifier) ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (if_statement "if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }" if (parenthesized_expression "((param_3 & 8) == 0)" ( (binary_expression "(param_3 & 8) == 0" (parenthesized_expression "(param_3 & 8)" ( (binary_expression "param_3 & 8" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }" { (if_statement "if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }" if (parenthesized_expression "((param_3 & 0x10) != 0)" ( (binary_expression "(param_3 & 0x10) != 0" (parenthesized_expression "(param_3 & 0x10)" ( (binary_expression "param_3 & 0x10" identifier & number_literal) )) != number_literal) )) (compound_statement "{\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }" { (expression_statement "iVar1 = FUN_0001b2c0(param_1,param_2);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,param_2)" identifier = (call_expression "FUN_0001b2c0(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })) (expression_statement "iVar1 = strcmp(param_1,param_2);" (assignment_expression "iVar1 = strcmp(param_1,param_2)" identifier = (call_expression "strcmp(param_1,param_2)" identifier (argument_list "(param_1,param_2)" ( identifier , identifier )))) ;) (return_statement "return iVar1;" return identifier ;) })) (if_statement "if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }" if (parenthesized_expression "((param_3 & 0x10) == 0)" ( (binary_expression "(param_3 & 0x10) == 0" (parenthesized_expression "(param_3 & 0x10)" ( (binary_expression "param_3 & 0x10" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }" { (expression_statement "__n = strlen(param_1);" (assignment_expression "__n = strlen(param_1)" identifier = (call_expression "strlen(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (expression_statement "iVar1 = strncmp(param_1,param_2,__n);" (assignment_expression "iVar1 = strncmp(param_1,param_2,__n)" identifier = (call_expression "strncmp(param_1,param_2,__n)" identifier (argument_list "(param_1,param_2,__n)" ( identifier , identifier , identifier )))) ;) (if_statement "if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }" if (parenthesized_expression "((iVar1 == 0) && (param_2[__n] != 0x2f))" ( (binary_expression "(iVar1 == 0) && (param_2[__n] != 0x2f)" (parenthesized_expression "(iVar1 == 0)" ( (binary_expression "iVar1 == 0" identifier == number_literal) )) && (parenthesized_expression "(param_2[__n] != 0x2f)" ( (binary_expression "param_2[__n] != 0x2f" (subscript_expression "param_2[__n]" identifier [ identifier ]) != number_literal) ))) )) (compound_statement "{\n      iVar1 = (int)param_2[__n];\n    }" { (expression_statement "iVar1 = (int)param_2[__n];" (assignment_expression "iVar1 = (int)param_2[__n]" identifier = (cast_expression "(int)param_2[__n]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "param_2[__n]" identifier [ identifier ]))) ;) })) (return_statement "return iVar1;" return identifier ;) })) (expression_statement "__ptr = (char *)FUN_0001e5e0(param_2);" (assignment_expression "__ptr = (char *)FUN_0001e5e0(param_2)" identifier = (cast_expression "(char *)FUN_0001e5e0(param_2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0001e5e0(param_2)" identifier (argument_list "(param_2)" ( identifier ))))) ;) (expression_statement "pcVar2 = __ptr;" (assignment_expression "pcVar2 = __ptr" identifier = identifier) ;) (while_statement "while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" { (expression_statement "pcVar2 = strchr(pcVar2,0x2f);" (assignment_expression "pcVar2 = strchr(pcVar2,0x2f)" identifier = (call_expression "strchr(pcVar2,0x2f)" identifier (argument_list "(pcVar2,0x2f)" ( identifier , number_literal )))) ;) (if_statement "if (pcVar2 == (char *)0x0) break;" if (parenthesized_expression "(pcVar2 == (char *)0x0)" ( (binary_expression "pcVar2 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (break_statement "break;" break ;)) (expression_statement "*pcVar2 = '\0';" (assignment_expression "*pcVar2 = '\0'" (pointer_expression "*pcVar2" * identifier) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "iVar1 = FUN_0001b2c0(param_1,__ptr);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,__ptr)" identifier = (call_expression "FUN_0001b2c0(param_1,__ptr)" identifier (argument_list "(param_1,__ptr)" ( identifier , identifier )))) ;) (if_statement "if (iVar1 < 1) goto LAB_0001545b;" if (parenthesized_expression "(iVar1 < 1)" ( (binary_expression "iVar1 < 1" identifier < number_literal) )) (goto_statement "goto LAB_0001545b;" goto statement_identifier ;)) (expression_statement "*pcVar2 = '/';" (assignment_expression "*pcVar2 = '/'" (pointer_expression "*pcVar2" * identifier) = (char_literal "'/'" ' character ')) ;) (expression_statement "pcVar2 = pcVar2 + 1;" (assignment_expression "pcVar2 = pcVar2 + 1" identifier = (binary_expression "pcVar2 + 1" identifier + number_literal)) ;) })) (expression_statement "iVar1 = FUN_0001b2c0(param_1,__ptr);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,__ptr)" identifier = (call_expression "FUN_0001b2c0(param_1,__ptr)" identifier (argument_list "(param_1,__ptr)" ( identifier , identifier )))) ;) (labeled_statement "LAB_0001545b:\n  free(__ptr);" statement_identifier : (expression_statement "free(__ptr);" (call_expression "free(__ptr)" identifier (argument_list "(__ptr)" ( identifier ))) ;)) (return_statement "return iVar1;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (return_statement return IDENT ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (return_statement return IDENT ;) })) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT == LIT) )) && (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ IDENT ]) != LIT) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ IDENT ]))) ;) })) (return_statement return IDENT ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT ))))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (break_statement break ;)) (expression_statement (assignment_expression (pointer_expression * IDENT) = (char_literal ' escape_sequence ')) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression (pointer_expression * IDENT) = (char_literal ' character ')) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;)) (return_statement return IDENT ;) })))
(function_definition "int FUN_000153b0(char *param_1,char *param_2,uint param_3)\n\n{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}" (primitive_type "int") (function_declarator "FUN_000153b0(char *param_1,char *param_2,uint param_3)" (identifier "FUN_000153b0") (parameter_list "(char *param_1,char *param_2,uint param_3)" (( "(") (parameter_declaration "char *param_1" (primitive_type "char") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "char *param_2" (primitive_type "char") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "uint param_3" (type_identifier "uint") (identifier "param_3")) () ")"))) (compound_statement "{\n  size_t __n;\n  int iVar1;\n  char *__ptr;\n  char *pcVar2;\n  \n  if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }\n  if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }\n  __ptr = (char *)FUN_0001e5e0(param_2);\n  pcVar2 = __ptr;\n  while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }\n  iVar1 = FUN_0001b2c0(param_1,__ptr);\nLAB_0001545b:\n  free(__ptr);\n  return iVar1;\n}" ({ "{") (declaration "size_t __n;" (primitive_type "size_t") (identifier "__n") (; ";")) (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "char *__ptr;" (primitive_type "char") (pointer_declarator "*__ptr" (* "*") (identifier "__ptr")) (; ";")) (declaration "char *pcVar2;" (primitive_type "char") (pointer_declarator "*pcVar2" (* "*") (identifier "pcVar2")) (; ";")) (if_statement "if ((param_3 & 8) == 0) {\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }" (if "if") (parenthesized_expression "((param_3 & 8) == 0)" (( "(") (binary_expression "(param_3 & 8) == 0" (parenthesized_expression "(param_3 & 8)" (( "(") (binary_expression "param_3 & 8" (identifier "param_3") (& "&") (number_literal "8")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }\n    iVar1 = strcmp(param_1,param_2);\n    return iVar1;\n  }" ({ "{") (if_statement "if ((param_3 & 0x10) != 0) {\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }" (if "if") (parenthesized_expression "((param_3 & 0x10) != 0)" (( "(") (binary_expression "(param_3 & 0x10) != 0" (parenthesized_expression "(param_3 & 0x10)" (( "(") (binary_expression "param_3 & 0x10" (identifier "param_3") (& "&") (number_literal "0x10")) () ")")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      iVar1 = FUN_0001b2c0(param_1,param_2);\n      return iVar1;\n    }" ({ "{") (expression_statement "iVar1 = FUN_0001b2c0(param_1,param_2);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,param_2)" (identifier "iVar1") (= "=") (call_expression "FUN_0001b2c0(param_1,param_2)" (identifier "FUN_0001b2c0") (argument_list "(param_1,param_2)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") () ")")))) (; ";")) (return_statement "return iVar1;" (return "return") (identifier "iVar1") (; ";")) (} "}"))) (expression_statement "iVar1 = strcmp(param_1,param_2);" (assignment_expression "iVar1 = strcmp(param_1,param_2)" (identifier "iVar1") (= "=") (call_expression "strcmp(param_1,param_2)" (identifier "strcmp") (argument_list "(param_1,param_2)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") () ")")))) (; ";")) (return_statement "return iVar1;" (return "return") (identifier "iVar1") (; ";")) (} "}"))) (if_statement "if ((param_3 & 0x10) == 0) {\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }" (if "if") (parenthesized_expression "((param_3 & 0x10) == 0)" (( "(") (binary_expression "(param_3 & 0x10) == 0" (parenthesized_expression "(param_3 & 0x10)" (( "(") (binary_expression "param_3 & 0x10" (identifier "param_3") (& "&") (number_literal "0x10")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    __n = strlen(param_1);\n    iVar1 = strncmp(param_1,param_2,__n);\n    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }\n    return iVar1;\n  }" ({ "{") (expression_statement "__n = strlen(param_1);" (assignment_expression "__n = strlen(param_1)" (identifier "__n") (= "=") (call_expression "strlen(param_1)" (identifier "strlen") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (; ";")) (expression_statement "iVar1 = strncmp(param_1,param_2,__n);" (assignment_expression "iVar1 = strncmp(param_1,param_2,__n)" (identifier "iVar1") (= "=") (call_expression "strncmp(param_1,param_2,__n)" (identifier "strncmp") (argument_list "(param_1,param_2,__n)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (identifier "__n") () ")")))) (; ";")) (if_statement "if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {\n      iVar1 = (int)param_2[__n];\n    }" (if "if") (parenthesized_expression "((iVar1 == 0) && (param_2[__n] != 0x2f))" (( "(") (binary_expression "(iVar1 == 0) && (param_2[__n] != 0x2f)" (parenthesized_expression "(iVar1 == 0)" (( "(") (binary_expression "iVar1 == 0" (identifier "iVar1") (== "==") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "(param_2[__n] != 0x2f)" (( "(") (binary_expression "param_2[__n] != 0x2f" (subscript_expression "param_2[__n]" (identifier "param_2") ([ "[") (identifier "__n") (] "]")) (!= "!=") (number_literal "0x2f")) () ")"))) () ")")) (compound_statement "{\n      iVar1 = (int)param_2[__n];\n    }" ({ "{") (expression_statement "iVar1 = (int)param_2[__n];" (assignment_expression "iVar1 = (int)param_2[__n]" (identifier "iVar1") (= "=") (cast_expression "(int)param_2[__n]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "param_2[__n]" (identifier "param_2") ([ "[") (identifier "__n") (] "]")))) (; ";")) (} "}"))) (return_statement "return iVar1;" (return "return") (identifier "iVar1") (; ";")) (} "}"))) (expression_statement "__ptr = (char *)FUN_0001e5e0(param_2);" (assignment_expression "__ptr = (char *)FUN_0001e5e0(param_2)" (identifier "__ptr") (= "=") (cast_expression "(char *)FUN_0001e5e0(param_2)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0001e5e0(param_2)" (identifier "FUN_0001e5e0") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")"))))) (; ";")) (expression_statement "pcVar2 = __ptr;" (assignment_expression "pcVar2 = __ptr" (identifier "pcVar2") (= "=") (identifier "__ptr")) (; ";")) (while_statement "while( true ) {\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n    pcVar2 = strchr(pcVar2,0x2f);\n    if (pcVar2 == (char *)0x0) break;\n    *pcVar2 = '\0';\n    iVar1 = FUN_0001b2c0(param_1,__ptr);\n    if (iVar1 < 1) goto LAB_0001545b;\n    *pcVar2 = '/';\n    pcVar2 = pcVar2 + 1;\n  }" ({ "{") (expression_statement "pcVar2 = strchr(pcVar2,0x2f);" (assignment_expression "pcVar2 = strchr(pcVar2,0x2f)" (identifier "pcVar2") (= "=") (call_expression "strchr(pcVar2,0x2f)" (identifier "strchr") (argument_list "(pcVar2,0x2f)" (( "(") (identifier "pcVar2") (, ",") (number_literal "0x2f") () ")")))) (; ";")) (if_statement "if (pcVar2 == (char *)0x0) break;" (if "if") (parenthesized_expression "(pcVar2 == (char *)0x0)" (( "(") (binary_expression "pcVar2 == (char *)0x0" (identifier "pcVar2") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "*pcVar2 = '\0';" (assignment_expression "*pcVar2 = '\0'" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) (; ";")) (expression_statement "iVar1 = FUN_0001b2c0(param_1,__ptr);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,__ptr)" (identifier "iVar1") (= "=") (call_expression "FUN_0001b2c0(param_1,__ptr)" (identifier "FUN_0001b2c0") (argument_list "(param_1,__ptr)" (( "(") (identifier "param_1") (, ",") (identifier "__ptr") () ")")))) (; ";")) (if_statement "if (iVar1 < 1) goto LAB_0001545b;" (if "if") (parenthesized_expression "(iVar1 < 1)" (( "(") (binary_expression "iVar1 < 1" (identifier "iVar1") (< "<") (number_literal "1")) () ")")) (goto_statement "goto LAB_0001545b;" (goto "goto") (statement_identifier "LAB_0001545b") (; ";"))) (expression_statement "*pcVar2 = '/';" (assignment_expression "*pcVar2 = '/'" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (= "=") (char_literal "'/'" (' "'") (character "/") (' "'"))) (; ";")) (expression_statement "pcVar2 = pcVar2 + 1;" (assignment_expression "pcVar2 = pcVar2 + 1" (identifier "pcVar2") (= "=") (binary_expression "pcVar2 + 1" (identifier "pcVar2") (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (expression_statement "iVar1 = FUN_0001b2c0(param_1,__ptr);" (assignment_expression "iVar1 = FUN_0001b2c0(param_1,__ptr)" (identifier "iVar1") (= "=") (call_expression "FUN_0001b2c0(param_1,__ptr)" (identifier "FUN_0001b2c0") (argument_list "(param_1,__ptr)" (( "(") (identifier "param_1") (, ",") (identifier "__ptr") () ")")))) (; ";")) (labeled_statement "LAB_0001545b:\n  free(__ptr);" (statement_identifier "LAB_0001545b") (: ":") (expression_statement "free(__ptr);" (call_expression "free(__ptr)" (identifier "free") (argument_list "(__ptr)" (( "(") (identifier "__ptr") () ")"))) (; ";"))) (return_statement "return iVar1;" (return "return") (identifier "iVar1") (; ";")) (} "}")))

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

int function_1(char *pattern,char *f,int var_1)

{
  size_t __n;
  int var_6;
  char *s2;
  char *var_9;
  
  if ((var_1 & 8U) == 0) {
    if ((var_1 & 0x10U) != 0) {
      var_6 = var_2(pattern,f);
      return var_6;
    }
    var_6 = var_3(pattern,f);
    return var_6;
  }
  if ((var_1 & 0x10U) == 0) {
    __n = var_4(pattern);
    var_6 = var_5(pattern,f,__n);
    if ((var_6 == 0) && (f[__n] != 0x2f)) {
      var_6 = (int)f[__n];
    }
    return var_6;
  }
  s2 = var_7(f);
  var_9 = s2;
  while( true ) {
    var_9 = var_8(var_9,0x2f);
    if (var_9 == (char *)0x0) break;
    *var_9 = '\0';
    var_6 = var_2(pattern,s2);
    if (var_6 < 1) goto LAB_0001545b;
    *var_9 = '/';
    var_9 = var_9 + 1;
  }
  var_6 = var_2(pattern,s2);
LAB_0001545b:
  var_10(s2);
  return var_6;
}


(translation_unit (function_definition type: (primitive_type) 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))) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (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 (identifier) (identifier))))) (return_statement (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier))))) (return_statement (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (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 (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (identifier)) right: (number_literal))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (identifier))))))) (return_statement (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (while_statement condition: (parenthesized_expression (true)) body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (break_statement)) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (char_literal (escape_sequence)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (char_literal (character)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier))))) (labeled_statement label: (statement_identifier) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier))))) (return_statement (identifier)))))

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

int MASKED(char *param_1,char *param_2,uint param_3)

{
  size_t __n;
  int iVar1;
  char *__ptr;
  char *pcVar2;
  
  if ((param_3 & 8) == 0) {
    if ((param_3 & 0x10) != 0) {
      iVar1 = FUN_0001b2c0(param_1,param_2);
      return iVar1;
    }
    iVar1 = strcmp(param_1,param_2);
    return iVar1;
  }
  if ((param_3 & 0x10) == 0) {
    __n = strlen(param_1);
    iVar1 = strncmp(param_1,param_2,__n);
    if ((iVar1 == 0) && (param_2[__n] != 0x2f)) {
      iVar1 = (int)param_2[__n];
    }
    return iVar1;
  }
  __ptr = (char *)FUN_0001e5e0(param_2);
  pcVar2 = __ptr;
  while( true ) {
    pcVar2 = strchr(pcVar2,0x2f);
    if (pcVar2 == (char *)0x0) break;
    *pcVar2 = '\0';
    iVar1 = FUN_0001b2c0(param_1,__ptr);
    if (iVar1 < 1) goto LAB_0001545b;
    *pcVar2 = '/';
    pcVar2 = pcVar2 + 1;
  }
  iVar1 = FUN_0001b2c0(param_1,__ptr);
LAB_0001545b:
  free(__ptr);
  return iVar1;
}

