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

char * full_pathname(char *file)

{
  size_t sVar1;
  char *pcVar2;
  char *pcVar3;
  
  if (*file == '~') {
    pcVar2 = bash_tilde_expand(file,0);
  }
  else {
    sVar1 = strlen(file);
    pcVar2 = (char *)xmalloc(sVar1 + 1);
    pcVar2 = strcpy(pcVar2,file);
  }
  pcVar3 = pcVar2;
  if (*pcVar2 != '/') {
    pcVar3 = sh_makepath((char *)0x0,pcVar2,6);
    free(pcVar2);
  }
  return pcVar3;
}



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

char * full_pathname(char *param_1)

{
  size_t sVar1;
  char *pcVar2;
  char *pcVar3;
  undefined4 uVar4;
  
  uVar4 = 0x42f2c;
  if (*param_1 == '~') {
    pcVar2 = (char *)bash_tilde_expand(param_1,0);
  }
  else {
    sVar1 = strlen(param_1);
    pcVar2 = (char *)xmalloc(sVar1 + 1);
    pcVar2 = strcpy(pcVar2,param_1);
  }
  pcVar3 = pcVar2;
  if (*pcVar2 != '/') {
    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);
    free(pcVar2);
  }
  return pcVar3;
}


PUSH EDI
PUSH ESI
PUSH EBX
MOV ESI,dword ptr [ESP + 0x10]
CALL 0x000312b0
ADD EBX,0x12f0d4
CMP byte ptr [ESI],0x7e
JZ 0x00042f80
SUB ESP,0xc
PUSH ESI
CALL 0x0002e760
ADD EAX,0x1
MOV dword ptr [ESP],EAX
CALL 0x000ad700
POP EDX
POP ECX
PUSH ESI
PUSH EAX
CALL 0x0002e580
ADD ESP,0x10
MOV ESI,EAX
CMP byte ptr [ESI],0x2f
JZ 0x00042f7a
SUB ESP,0x4
PUSH 0x6
PUSH ESI
PUSH 0x0
CALL 0x000d6af0
MOV dword ptr [ESP],ESI
MOV EDI,EAX
CALL 0x0002e200
MOV ESI,EDI
ADD ESP,0x10
MOV EAX,ESI
POP EBX
POP ESI
POP EDI
RET
SUB ESP,0x8
PUSH 0x0
PUSH ESI
CALL 0x00042df0
ADD ESP,0x10
MOV ESI,EAX
JMP 0x00042f59
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nchar * full_pathname(char *param_1)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}\n\n" comment (function_definition "char * full_pathname(char *param_1)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" primitive_type (pointer_declarator "* full_pathname(char *param_1)" * (function_declarator "full_pathname(char *param_1)" identifier (parameter_list "(char *param_1)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) )))) (compound_statement "{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (expression_statement "uVar4 = 0x42f2c;" (assignment_expression "uVar4 = 0x42f2c" identifier = number_literal) ;) (if_statement "if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" if (parenthesized_expression "(*param_1 == '~')" ( (binary_expression "*param_1 == '~'" (pointer_expression "*param_1" * identifier) == (char_literal "'~'" ' character ')) )) (compound_statement "{\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }" { (expression_statement "pcVar2 = (char *)bash_tilde_expand(param_1,0);" (assignment_expression "pcVar2 = (char *)bash_tilde_expand(param_1,0)" identifier = (cast_expression "(char *)bash_tilde_expand(param_1,0)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "bash_tilde_expand(param_1,0)" identifier (argument_list "(param_1,0)" ( identifier , number_literal ))))) ;) }) (else_clause "else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" else (compound_statement "{\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" { (expression_statement "sVar1 = strlen(param_1);" (assignment_expression "sVar1 = strlen(param_1)" identifier = (call_expression "strlen(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (expression_statement "pcVar2 = (char *)xmalloc(sVar1 + 1);" (assignment_expression "pcVar2 = (char *)xmalloc(sVar1 + 1)" identifier = (cast_expression "(char *)xmalloc(sVar1 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(sVar1 + 1)" identifier (argument_list "(sVar1 + 1)" ( (binary_expression "sVar1 + 1" identifier + number_literal) ))))) ;) (expression_statement "pcVar2 = strcpy(pcVar2,param_1);" (assignment_expression "pcVar2 = strcpy(pcVar2,param_1)" identifier = (call_expression "strcpy(pcVar2,param_1)" identifier (argument_list "(pcVar2,param_1)" ( identifier , identifier )))) ;) }))) (expression_statement "pcVar3 = pcVar2;" (assignment_expression "pcVar3 = pcVar2" identifier = identifier) ;) (if_statement "if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }" if (parenthesized_expression "(*pcVar2 != '/')" ( (binary_expression "*pcVar2 != '/'" (pointer_expression "*pcVar2" * identifier) != (char_literal "'/'" ' character ')) )) (compound_statement "{\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }" { (expression_statement "pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);" (assignment_expression "pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4)" identifier = (cast_expression "(char *)sh_makepath(0,pcVar2,6,uVar4)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "sh_makepath(0,pcVar2,6,uVar4)" identifier (argument_list "(0,pcVar2,6,uVar4)" ( number_literal , identifier , number_literal , identifier ))))) ;) (expression_statement "free(pcVar2);" (call_expression "free(pcVar2)" identifier (argument_list "(pcVar2)" ( identifier ))) ;) })) (return_statement "return pcVar3;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nchar * full_pathname(char *file)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  \n  if (*file == '~') {\n    pcVar2 = bash_tilde_expand(file,0);\n  }\n  else {\n    sVar1 = strlen(file);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,file);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = sh_makepath((char *)0x0,pcVar2,6);\n    free(pcVar2);\n  }\n  return pcVar3;\n}\n\n" comment (function_definition "char * full_pathname(char *file)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  \n  if (*file == '~') {\n    pcVar2 = bash_tilde_expand(file,0);\n  }\n  else {\n    sVar1 = strlen(file);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,file);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = sh_makepath((char *)0x0,pcVar2,6);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" primitive_type (pointer_declarator "* full_pathname(char *file)" * (function_declarator "full_pathname(char *file)" identifier (parameter_list "(char *file)" ( (parameter_declaration "char *file" primitive_type (pointer_declarator "*file" * identifier)) )))) (compound_statement "{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  \n  if (*file == '~') {\n    pcVar2 = bash_tilde_expand(file,0);\n  }\n  else {\n    sVar1 = strlen(file);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,file);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = sh_makepath((char *)0x0,pcVar2,6);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (if_statement "if (*file == '~') {\n    pcVar2 = bash_tilde_expand(file,0);\n  }\n  else {\n    sVar1 = strlen(file);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,file);\n  }" if (parenthesized_expression "(*file == '~')" ( (binary_expression "*file == '~'" (pointer_expression "*file" * identifier) == (char_literal "'~'" ' character ')) )) (compound_statement "{\n    pcVar2 = bash_tilde_expand(file,0);\n  }" { (expression_statement "pcVar2 = bash_tilde_expand(file,0);" (assignment_expression "pcVar2 = bash_tilde_expand(file,0)" identifier = (call_expression "bash_tilde_expand(file,0)" identifier (argument_list "(file,0)" ( identifier , number_literal )))) ;) }) (else_clause "else {\n    sVar1 = strlen(file);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,file);\n  }" else (compound_statement "{\n    sVar1 = strlen(file);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,file);\n  }" { (expression_statement "sVar1 = strlen(file);" (assignment_expression "sVar1 = strlen(file)" identifier = (call_expression "strlen(file)" identifier (argument_list "(file)" ( identifier )))) ;) (expression_statement "pcVar2 = (char *)xmalloc(sVar1 + 1);" (assignment_expression "pcVar2 = (char *)xmalloc(sVar1 + 1)" identifier = (cast_expression "(char *)xmalloc(sVar1 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(sVar1 + 1)" identifier (argument_list "(sVar1 + 1)" ( (binary_expression "sVar1 + 1" identifier + number_literal) ))))) ;) (expression_statement "pcVar2 = strcpy(pcVar2,file);" (assignment_expression "pcVar2 = strcpy(pcVar2,file)" identifier = (call_expression "strcpy(pcVar2,file)" identifier (argument_list "(pcVar2,file)" ( identifier , identifier )))) ;) }))) (expression_statement "pcVar3 = pcVar2;" (assignment_expression "pcVar3 = pcVar2" identifier = identifier) ;) (if_statement "if (*pcVar2 != '/') {\n    pcVar3 = sh_makepath((char *)0x0,pcVar2,6);\n    free(pcVar2);\n  }" if (parenthesized_expression "(*pcVar2 != '/')" ( (binary_expression "*pcVar2 != '/'" (pointer_expression "*pcVar2" * identifier) != (char_literal "'/'" ' character ')) )) (compound_statement "{\n    pcVar3 = sh_makepath((char *)0x0,pcVar2,6);\n    free(pcVar2);\n  }" { (expression_statement "pcVar3 = sh_makepath((char *)0x0,pcVar2,6);" (assignment_expression "pcVar3 = sh_makepath((char *)0x0,pcVar2,6)" identifier = (call_expression "sh_makepath((char *)0x0,pcVar2,6)" identifier (argument_list "((char *)0x0,pcVar2,6)" ( (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal) , identifier , number_literal )))) ;) (expression_statement "free(pcVar2);" (call_expression "free(pcVar2)" identifier (argument_list "(pcVar2)" ( identifier ))) ;) })) (return_statement "return pcVar3;" return identifier ;) })))
(translation_unit "char * full_pathname(char *param_1)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}\n\n" (function_definition "char * full_pathname(char *param_1)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" primitive_type (pointer_declarator "* full_pathname(char *param_1)" * (function_declarator "full_pathname(char *param_1)" identifier (parameter_list "(char *param_1)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) )))) (compound_statement "{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" { (declaration "size_t sVar1;" primitive_type identifier ;) (declaration "char *pcVar2;" primitive_type (pointer_declarator "*pcVar2" * identifier) ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "undefined4 uVar4;" type_identifier identifier ;) (expression_statement "uVar4 = 0x42f2c;" (assignment_expression "uVar4 = 0x42f2c" identifier = number_literal) ;) (if_statement "if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" if (parenthesized_expression "(*param_1 == '~')" ( (binary_expression "*param_1 == '~'" (pointer_expression "*param_1" * identifier) == (char_literal "'~'" ' character ')) )) (compound_statement "{\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }" { (expression_statement "pcVar2 = (char *)bash_tilde_expand(param_1,0);" (assignment_expression "pcVar2 = (char *)bash_tilde_expand(param_1,0)" identifier = (cast_expression "(char *)bash_tilde_expand(param_1,0)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "bash_tilde_expand(param_1,0)" identifier (argument_list "(param_1,0)" ( identifier , number_literal ))))) ;) }) (else_clause "else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" else (compound_statement "{\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" { (expression_statement "sVar1 = strlen(param_1);" (assignment_expression "sVar1 = strlen(param_1)" identifier = (call_expression "strlen(param_1)" identifier (argument_list "(param_1)" ( identifier )))) ;) (expression_statement "pcVar2 = (char *)xmalloc(sVar1 + 1);" (assignment_expression "pcVar2 = (char *)xmalloc(sVar1 + 1)" identifier = (cast_expression "(char *)xmalloc(sVar1 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(sVar1 + 1)" identifier (argument_list "(sVar1 + 1)" ( (binary_expression "sVar1 + 1" identifier + number_literal) ))))) ;) (expression_statement "pcVar2 = strcpy(pcVar2,param_1);" (assignment_expression "pcVar2 = strcpy(pcVar2,param_1)" identifier = (call_expression "strcpy(pcVar2,param_1)" identifier (argument_list "(pcVar2,param_1)" ( identifier , identifier )))) ;) }))) (expression_statement "pcVar3 = pcVar2;" (assignment_expression "pcVar3 = pcVar2" identifier = identifier) ;) (if_statement "if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }" if (parenthesized_expression "(*pcVar2 != '/')" ( (binary_expression "*pcVar2 != '/'" (pointer_expression "*pcVar2" * identifier) != (char_literal "'/'" ' character ')) )) (compound_statement "{\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }" { (expression_statement "pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);" (assignment_expression "pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4)" identifier = (cast_expression "(char *)sh_makepath(0,pcVar2,6,uVar4)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "sh_makepath(0,pcVar2,6,uVar4)" identifier (argument_list "(0,pcVar2,6,uVar4)" ( number_literal , identifier , number_literal , identifier ))))) ;) (expression_statement "free(pcVar2);" (call_expression "free(pcVar2)" identifier (argument_list "(pcVar2)" ( identifier ))) ;) })) (return_statement "return pcVar3;" return identifier ;) })))
(translation_unit (function_definition TYPE (pointer_declarator * (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) )))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , LIT ))))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT )))) ;) }))) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( LIT , IDENT , LIT , IDENT ))))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) })) (return_statement return IDENT ;) })))
(function_definition "char * full_pathname(char *param_1)\n\n{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" (primitive_type "char") (pointer_declarator "* full_pathname(char *param_1)" (* "*") (function_declarator "full_pathname(char *param_1)" (identifier "full_pathname") (parameter_list "(char *param_1)" (( "(") (parameter_declaration "char *param_1" (primitive_type "char") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) () ")")))) (compound_statement "{\n  size_t sVar1;\n  char *pcVar2;\n  char *pcVar3;\n  undefined4 uVar4;\n  \n  uVar4 = 0x42f2c;\n  if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }\n  pcVar3 = pcVar2;\n  if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }\n  return pcVar3;\n}" ({ "{") (declaration "size_t sVar1;" (primitive_type "size_t") (identifier "sVar1") (; ";")) (declaration "char *pcVar2;" (primitive_type "char") (pointer_declarator "*pcVar2" (* "*") (identifier "pcVar2")) (; ";")) (declaration "char *pcVar3;" (primitive_type "char") (pointer_declarator "*pcVar3" (* "*") (identifier "pcVar3")) (; ";")) (declaration "undefined4 uVar4;" (type_identifier "undefined4") (identifier "uVar4") (; ";")) (expression_statement "uVar4 = 0x42f2c;" (assignment_expression "uVar4 = 0x42f2c" (identifier "uVar4") (= "=") (number_literal "0x42f2c")) (; ";")) (if_statement "if (*param_1 == '~') {\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }\n  else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" (if "if") (parenthesized_expression "(*param_1 == '~')" (( "(") (binary_expression "*param_1 == '~'" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (== "==") (char_literal "'~'" (' "'") (character "~") (' "'"))) () ")")) (compound_statement "{\n    pcVar2 = (char *)bash_tilde_expand(param_1,0);\n  }" ({ "{") (expression_statement "pcVar2 = (char *)bash_tilde_expand(param_1,0);" (assignment_expression "pcVar2 = (char *)bash_tilde_expand(param_1,0)" (identifier "pcVar2") (= "=") (cast_expression "(char *)bash_tilde_expand(param_1,0)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "bash_tilde_expand(param_1,0)" (identifier "bash_tilde_expand") (argument_list "(param_1,0)" (( "(") (identifier "param_1") (, ",") (number_literal "0") () ")"))))) (; ";")) (} "}")) (else_clause "else {\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" (else "else") (compound_statement "{\n    sVar1 = strlen(param_1);\n    pcVar2 = (char *)xmalloc(sVar1 + 1);\n    pcVar2 = strcpy(pcVar2,param_1);\n  }" ({ "{") (expression_statement "sVar1 = strlen(param_1);" (assignment_expression "sVar1 = strlen(param_1)" (identifier "sVar1") (= "=") (call_expression "strlen(param_1)" (identifier "strlen") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")")))) (; ";")) (expression_statement "pcVar2 = (char *)xmalloc(sVar1 + 1);" (assignment_expression "pcVar2 = (char *)xmalloc(sVar1 + 1)" (identifier "pcVar2") (= "=") (cast_expression "(char *)xmalloc(sVar1 + 1)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "xmalloc(sVar1 + 1)" (identifier "xmalloc") (argument_list "(sVar1 + 1)" (( "(") (binary_expression "sVar1 + 1" (identifier "sVar1") (+ "+") (number_literal "1")) () ")"))))) (; ";")) (expression_statement "pcVar2 = strcpy(pcVar2,param_1);" (assignment_expression "pcVar2 = strcpy(pcVar2,param_1)" (identifier "pcVar2") (= "=") (call_expression "strcpy(pcVar2,param_1)" (identifier "strcpy") (argument_list "(pcVar2,param_1)" (( "(") (identifier "pcVar2") (, ",") (identifier "param_1") () ")")))) (; ";")) (} "}")))) (expression_statement "pcVar3 = pcVar2;" (assignment_expression "pcVar3 = pcVar2" (identifier "pcVar3") (= "=") (identifier "pcVar2")) (; ";")) (if_statement "if (*pcVar2 != '/') {\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }" (if "if") (parenthesized_expression "(*pcVar2 != '/')" (( "(") (binary_expression "*pcVar2 != '/'" (pointer_expression "*pcVar2" (* "*") (identifier "pcVar2")) (!= "!=") (char_literal "'/'" (' "'") (character "/") (' "'"))) () ")")) (compound_statement "{\n    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);\n    free(pcVar2);\n  }" ({ "{") (expression_statement "pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);" (assignment_expression "pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4)" (identifier "pcVar3") (= "=") (cast_expression "(char *)sh_makepath(0,pcVar2,6,uVar4)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "sh_makepath(0,pcVar2,6,uVar4)" (identifier "sh_makepath") (argument_list "(0,pcVar2,6,uVar4)" (( "(") (number_literal "0") (, ",") (identifier "pcVar2") (, ",") (number_literal "6") (, ",") (identifier "uVar4") () ")"))))) (; ";")) (expression_statement "free(pcVar2);" (call_expression "free(pcVar2)" (identifier "free") (argument_list "(pcVar2)" (( "(") (identifier "pcVar2") () ")"))) (; ";")) (} "}"))) (return_statement "return pcVar3;" (return "return") (identifier "pcVar3") (; ";")) (} "}")))

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

char * function_1(char *file)

{
  size_t var_4;
  char *pcVar2;
  char *pcVar3;
  
  if (*file == '~') {
    pcVar2 = var_1(file,0);
  }
  else {
    var_4 = var_2(file);
    pcVar2 = (char *)var_3(var_4 + 1);
    pcVar2 = var_5(pcVar2,file);
  }
  pcVar3 = pcVar2;
  if (*pcVar2 != '/') {
    pcVar3 = var_6((char *)0x0,pcVar2,6);
    var_7(pcVar2);
  }
  return pcVar3;
}


(translation_unit (function_definition type: (primitive_type) declarator: (pointer_declarator declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier)))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (character)))) consequence: (compound_statement (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) (number_literal))))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (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 (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (character)))) consequence: (compound_statement (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 (number_literal) (identifier) (number_literal) (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 */

char * MASKED(char *param_1)

{
  size_t sVar1;
  char *pcVar2;
  char *pcVar3;
  undefined4 uVar4;
  
  uVar4 = 0x42f2c;
  if (*param_1 == '~') {
    pcVar2 = (char *)bash_tilde_expand(param_1,0);
  }
  else {
    sVar1 = strlen(param_1);
    pcVar2 = (char *)xmalloc(sVar1 + 1);
    pcVar2 = strcpy(pcVar2,param_1);
  }
  pcVar3 = pcVar2;
  if (*pcVar2 != '/') {
    pcVar3 = (char *)sh_makepath(0,pcVar2,6,uVar4);
    free(pcVar2);
  }
  return pcVar3;
}

