
char * sh_single_quote(char *string)

{
  char cVar1;
  int iVar2;
  char *pcVar3;
  char *pcVar4;
  char *pcVar5;
  
  iVar2 = (*(code *)PTR_strlen_00146390)();
  pcVar3 = (char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);
  if ((*string == '\'') && (string[1] == '\0')) {
    pcVar3[1] = '\'';
    pcVar3[2] = '\0';
    *pcVar3 = '\\';
    return pcVar3;
  }
  *pcVar3 = '\'';
  pcVar4 = pcVar3 + 1;
  do {
    while( true ) {
      cVar1 = *string;
      if (cVar1 == '\0') goto LAB_000dad1c;
      *pcVar4 = cVar1;
      if (cVar1 != '\'') break;
      pcVar4[1] = '\\';
      pcVar5 = pcVar4 + 4;
      string = string + 1;
      pcVar4[2] = '\'';
      pcVar4[3] = '\'';
      pcVar4 = pcVar5;
      if (string == (char *)0x0) goto LAB_000dad1c;
    }
    string = string + 1;
    pcVar4 = pcVar4 + 1;
  } while (string != (char *)0x0);
LAB_000dad1c:
  pcVar4[1] = '\0';
  *pcVar4 = '\'';
  return pcVar3;
}



void sh_single_quote(char *param_1)

{
  char cVar1;
  int iVar2;
  undefined1 *puVar3;
  char *pcVar4;
  char *pcVar5;
  
  iVar2 = (*(code *)PTR_strlen_00146390)();
  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);
  if ((*param_1 == '\'') && (param_1[1] == '\0')) {
    puVar3[1] = 0x27;
    puVar3[2] = 0;
    *puVar3 = 0x5c;
    return;
  }
  *puVar3 = 0x27;
  pcVar4 = puVar3 + 1;
  do {
    while( true ) {
      cVar1 = *param_1;
      if (cVar1 == '\0') goto LAB_000dad1c;
      *pcVar4 = cVar1;
      if (cVar1 != '\'') break;
      pcVar4[1] = '\\';
      pcVar5 = pcVar4 + 4;
      param_1 = param_1 + 1;
      pcVar4[2] = '\'';
      pcVar4[3] = '\'';
      pcVar4 = pcVar5;
      if (param_1 == (char *)0x0) goto LAB_000dad1c;
    }
    param_1 = param_1 + 1;
    pcVar4 = pcVar4 + 1;
  } while (param_1 != (char *)0x0);
LAB_000dad1c:
  pcVar4[1] = '\0';
  *pcVar4 = '\'';
  return;
}


lui gp,0x7
addiu gp,gp,0x18c0
addu gp,gp,t9
addiu sp,sp,-0x20
lw t9,-0x61b0(gp)
sw gp,0x10(sp)
sw ra,0x1c(sp)
sw s0,0x18(sp)
jalr t9
_or s0,a0,zero
lw gp,0x10(sp)
sll v0,v0,0x2
lw t9,-0x7f90(gp)
jalr t9
_addiu a0,v0,0x3
li a0,0x27
lb v1,0x0(s0)
beq v1,a0,0x000dad38
_nop
li a0,0x27
addiu v1,v0,0x1
sb a0,0x0(v0)
li a1,0x27
b 0x000dacf0
_li a2,0x5c
addiu s0,s0,0x1
beq s0,zero,0x000dad1c
_addiu v1,v1,0x1
lb a0,0x0(s0)
beq a0,zero,0x000dad1c
_nop
bne a0,a1,0x000dace4
_sb a0,0x0(v1)
sb a2,0x1(v1)
addiu v1,v1,0x4
addiu s0,s0,0x1
sb a1,-0x2(v1)
bne s0,zero,0x000dacf0
_sb a1,-0x1(v1)
li a0,0x27
sb zero,0x1(v1)
sb a0,0x0(v1)
lw ra,0x1c(sp)
lw s0,0x18(sp)
jr ra
_addiu sp,sp,0x20
lb a0,0x1(s0)
bne a0,zero,0x000daccc
_nop
sb v1,0x1(v0)
li v1,0x5c
sb zero,0x2(v0)
sb v1,0x0(v0)
lw ra,0x1c(sp)
lw s0,0x18(sp)
jr ra
_addiu sp,sp,0x20
(translation_unit "void sh_single_quote(char *param_1)\n\n{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}\n\n" (function_definition "void sh_single_quote(char *param_1)\n\n{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}" primitive_type (function_declarator "sh_single_quote(char *param_1)" identifier (parameter_list "(char *param_1)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "undefined1 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (declaration "char *pcVar5;" primitive_type (pointer_declarator "*pcVar5" * identifier) ;) (expression_statement "iVar2 = (*(code *)PTR_strlen_00146390)();" (assignment_expression "iVar2 = (*(code *)PTR_strlen_00146390)()" identifier = (call_expression "(*(code *)PTR_strlen_00146390)()" (parenthesized_expression "(*(code *)PTR_strlen_00146390)" ( (pointer_expression "*(code *)PTR_strlen_00146390" * (cast_expression "(code *)PTR_strlen_00146390" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( )))) ;) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" identifier = (cast_expression "(undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" (parenthesized_expression "(*(code *)PTR_xmalloc_001445b0)" ( (pointer_expression "*(code *)PTR_xmalloc_001445b0" * (cast_expression "(code *)PTR_xmalloc_001445b0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2 * 4 + 3)" ( (binary_expression "iVar2 * 4 + 3" (binary_expression "iVar2 * 4" identifier * number_literal) + number_literal) ))))) ;) (if_statement "if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }" if (parenthesized_expression "((*param_1 == '\'') && (param_1[1] == '\0'))" ( (binary_expression "(*param_1 == '\'') && (param_1[1] == '\0')" (parenthesized_expression "(*param_1 == '\'')" ( (binary_expression "*param_1 == '\''" (pointer_expression "*param_1" * identifier) == (char_literal "'\''" ' escape_sequence ')) )) && (parenthesized_expression "(param_1[1] == '\0')" ( (binary_expression "param_1[1] == '\0'" (subscript_expression "param_1[1]" identifier [ number_literal ]) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }" { (expression_statement "puVar3[1] = 0x27;" (assignment_expression "puVar3[1] = 0x27" (subscript_expression "puVar3[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "puVar3[2] = 0;" (assignment_expression "puVar3[2] = 0" (subscript_expression "puVar3[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "*puVar3 = 0x5c;" (assignment_expression "*puVar3 = 0x5c" (pointer_expression "*puVar3" * identifier) = number_literal) ;) (return_statement "return;" return ;) })) (expression_statement "*puVar3 = 0x27;" (assignment_expression "*puVar3 = 0x27" (pointer_expression "*puVar3" * identifier) = number_literal) ;) (expression_statement "pcVar4 = puVar3 + 1;" (assignment_expression "pcVar4 = puVar3 + 1" identifier = (binary_expression "puVar3 + 1" identifier + number_literal)) ;) (do_statement "do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);" do (compound_statement "{\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  }" { (while_statement "while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }" { (expression_statement "cVar1 = *param_1;" (assignment_expression "cVar1 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (if_statement "if (cVar1 == '\0') goto LAB_000dad1c;" if (parenthesized_expression "(cVar1 == '\0')" ( (binary_expression "cVar1 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (goto_statement "goto LAB_000dad1c;" goto statement_identifier ;)) (expression_statement "*pcVar4 = cVar1;" (assignment_expression "*pcVar4 = cVar1" (pointer_expression "*pcVar4" * identifier) = identifier) ;) (if_statement "if (cVar1 != '\'') break;" if (parenthesized_expression "(cVar1 != '\'')" ( (binary_expression "cVar1 != '\''" identifier != (char_literal "'\''" ' escape_sequence ')) )) (break_statement "break;" break ;)) (expression_statement "pcVar4[1] = '\\';" (assignment_expression "pcVar4[1] = '\\'" (subscript_expression "pcVar4[1]" identifier [ number_literal ]) = (char_literal "'\\'" ' escape_sequence ')) ;) (expression_statement "pcVar5 = pcVar4 + 4;" (assignment_expression "pcVar5 = pcVar4 + 4" identifier = (binary_expression "pcVar4 + 4" identifier + number_literal)) ;) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "pcVar4[2] = '\'';" (assignment_expression "pcVar4[2] = '\''" (subscript_expression "pcVar4[2]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4[3] = '\'';" (assignment_expression "pcVar4[3] = '\''" (subscript_expression "pcVar4[3]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4 = pcVar5;" (assignment_expression "pcVar4 = pcVar5" identifier = identifier) ;) (if_statement "if (param_1 == (char *)0x0) goto LAB_000dad1c;" if (parenthesized_expression "(param_1 == (char *)0x0)" ( (binary_expression "param_1 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_000dad1c;" goto statement_identifier ;)) })) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_1 != (char *)0x0)" ( (binary_expression "param_1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) (labeled_statement "LAB_000dad1c:\n  pcVar4[1] = '\0';" statement_identifier : (expression_statement "pcVar4[1] = '\0';" (assignment_expression "pcVar4[1] = '\0'" (subscript_expression "pcVar4[1]" identifier [ number_literal ]) = (char_literal "'\0'" ' escape_sequence ')) ;)) (expression_statement "*pcVar4 = '\'';" (assignment_expression "*pcVar4 = '\''" (pointer_expression "*pcVar4" * identifier) = (char_literal "'\''" ' escape_sequence ')) ;) (return_statement "return;" return ;) })))
(translation_unit "char * sh_single_quote(char *string)\n\n{\n  char cVar1;\n  int iVar2;\n  char *pcVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  pcVar3 = (char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*string == '\'') && (string[1] == '\0')) {\n    pcVar3[1] = '\'';\n    pcVar3[2] = '\0';\n    *pcVar3 = '\\';\n    return pcVar3;\n  }\n  *pcVar3 = '\'';\n  pcVar4 = pcVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }\n    string = string + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (string != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return pcVar3;\n}\n\n" (function_definition "char * sh_single_quote(char *string)\n\n{\n  char cVar1;\n  int iVar2;\n  char *pcVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  pcVar3 = (char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*string == '\'') && (string[1] == '\0')) {\n    pcVar3[1] = '\'';\n    pcVar3[2] = '\0';\n    *pcVar3 = '\\';\n    return pcVar3;\n  }\n  *pcVar3 = '\'';\n  pcVar4 = pcVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }\n    string = string + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (string != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return pcVar3;\n}" primitive_type (pointer_declarator "* sh_single_quote(char *string)" * (function_declarator "sh_single_quote(char *string)" identifier (parameter_list "(char *string)" ( (parameter_declaration "char *string" primitive_type (pointer_declarator "*string" * identifier)) )))) (compound_statement "{\n  char cVar1;\n  int iVar2;\n  char *pcVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  pcVar3 = (char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*string == '\'') && (string[1] == '\0')) {\n    pcVar3[1] = '\'';\n    pcVar3[2] = '\0';\n    *pcVar3 = '\\';\n    return pcVar3;\n  }\n  *pcVar3 = '\'';\n  pcVar4 = pcVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }\n    string = string + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (string != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return pcVar3;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (declaration "char *pcVar5;" primitive_type (pointer_declarator "*pcVar5" * identifier) ;) (expression_statement "iVar2 = (*(code *)PTR_strlen_00146390)();" (assignment_expression "iVar2 = (*(code *)PTR_strlen_00146390)()" identifier = (call_expression "(*(code *)PTR_strlen_00146390)()" (parenthesized_expression "(*(code *)PTR_strlen_00146390)" ( (pointer_expression "*(code *)PTR_strlen_00146390" * (cast_expression "(code *)PTR_strlen_00146390" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( )))) ;) (expression_statement "pcVar3 = (char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);" (assignment_expression "pcVar3 = (char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" identifier = (cast_expression "(char *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" (parenthesized_expression "(*(code *)PTR_xmalloc_001445b0)" ( (pointer_expression "*(code *)PTR_xmalloc_001445b0" * (cast_expression "(code *)PTR_xmalloc_001445b0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2 * 4 + 3)" ( (binary_expression "iVar2 * 4 + 3" (binary_expression "iVar2 * 4" identifier * number_literal) + number_literal) ))))) ;) (if_statement "if ((*string == '\'') && (string[1] == '\0')) {\n    pcVar3[1] = '\'';\n    pcVar3[2] = '\0';\n    *pcVar3 = '\\';\n    return pcVar3;\n  }" if (parenthesized_expression "((*string == '\'') && (string[1] == '\0'))" ( (binary_expression "(*string == '\'') && (string[1] == '\0')" (parenthesized_expression "(*string == '\'')" ( (binary_expression "*string == '\''" (pointer_expression "*string" * identifier) == (char_literal "'\''" ' escape_sequence ')) )) && (parenthesized_expression "(string[1] == '\0')" ( (binary_expression "string[1] == '\0'" (subscript_expression "string[1]" identifier [ number_literal ]) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n    pcVar3[1] = '\'';\n    pcVar3[2] = '\0';\n    *pcVar3 = '\\';\n    return pcVar3;\n  }" { (expression_statement "pcVar3[1] = '\'';" (assignment_expression "pcVar3[1] = '\''" (subscript_expression "pcVar3[1]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar3[2] = '\0';" (assignment_expression "pcVar3[2] = '\0'" (subscript_expression "pcVar3[2]" identifier [ number_literal ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "*pcVar3 = '\\';" (assignment_expression "*pcVar3 = '\\'" (pointer_expression "*pcVar3" * identifier) = (char_literal "'\\'" ' escape_sequence ')) ;) (return_statement "return pcVar3;" return identifier ;) })) (expression_statement "*pcVar3 = '\'';" (assignment_expression "*pcVar3 = '\''" (pointer_expression "*pcVar3" * identifier) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4 = pcVar3 + 1;" (assignment_expression "pcVar4 = pcVar3 + 1" identifier = (binary_expression "pcVar3 + 1" identifier + number_literal)) ;) (do_statement "do {\n    while( true ) {\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }\n    string = string + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (string != (char *)0x0);" do (compound_statement "{\n    while( true ) {\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }\n    string = string + 1;\n    pcVar4 = pcVar4 + 1;\n  }" { (while_statement "while( true ) {\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n      cVar1 = *string;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      string = string + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (string == (char *)0x0) goto LAB_000dad1c;\n    }" { (expression_statement "cVar1 = *string;" (assignment_expression "cVar1 = *string" identifier = (pointer_expression "*string" * identifier)) ;) (if_statement "if (cVar1 == '\0') goto LAB_000dad1c;" if (parenthesized_expression "(cVar1 == '\0')" ( (binary_expression "cVar1 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (goto_statement "goto LAB_000dad1c;" goto statement_identifier ;)) (expression_statement "*pcVar4 = cVar1;" (assignment_expression "*pcVar4 = cVar1" (pointer_expression "*pcVar4" * identifier) = identifier) ;) (if_statement "if (cVar1 != '\'') break;" if (parenthesized_expression "(cVar1 != '\'')" ( (binary_expression "cVar1 != '\''" identifier != (char_literal "'\''" ' escape_sequence ')) )) (break_statement "break;" break ;)) (expression_statement "pcVar4[1] = '\\';" (assignment_expression "pcVar4[1] = '\\'" (subscript_expression "pcVar4[1]" identifier [ number_literal ]) = (char_literal "'\\'" ' escape_sequence ')) ;) (expression_statement "pcVar5 = pcVar4 + 4;" (assignment_expression "pcVar5 = pcVar4 + 4" identifier = (binary_expression "pcVar4 + 4" identifier + number_literal)) ;) (expression_statement "string = string + 1;" (assignment_expression "string = string + 1" identifier = (binary_expression "string + 1" identifier + number_literal)) ;) (expression_statement "pcVar4[2] = '\'';" (assignment_expression "pcVar4[2] = '\''" (subscript_expression "pcVar4[2]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4[3] = '\'';" (assignment_expression "pcVar4[3] = '\''" (subscript_expression "pcVar4[3]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4 = pcVar5;" (assignment_expression "pcVar4 = pcVar5" identifier = identifier) ;) (if_statement "if (string == (char *)0x0) goto LAB_000dad1c;" if (parenthesized_expression "(string == (char *)0x0)" ( (binary_expression "string == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_000dad1c;" goto statement_identifier ;)) })) (expression_statement "string = string + 1;" (assignment_expression "string = string + 1" identifier = (binary_expression "string + 1" identifier + number_literal)) ;) (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(string != (char *)0x0)" ( (binary_expression "string != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) (labeled_statement "LAB_000dad1c:\n  pcVar4[1] = '\0';" statement_identifier : (expression_statement "pcVar4[1] = '\0';" (assignment_expression "pcVar4[1] = '\0'" (subscript_expression "pcVar4[1]" identifier [ number_literal ]) = (char_literal "'\0'" ' escape_sequence ')) ;)) (expression_statement "*pcVar4 = '\'';" (assignment_expression "*pcVar4 = '\''" (pointer_expression "*pcVar4" * identifier) = (char_literal "'\''" ' escape_sequence ')) ;) (return_statement "return pcVar3;" return identifier ;) })))
(translation_unit "void sh_single_quote(char *param_1)\n\n{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}\n\n" (function_definition "void sh_single_quote(char *param_1)\n\n{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}" primitive_type (function_declarator "sh_single_quote(char *param_1)" identifier (parameter_list "(char *param_1)" ( (parameter_declaration "char *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}" { (declaration "char cVar1;" primitive_type identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "undefined1 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "char *pcVar4;" primitive_type (pointer_declarator "*pcVar4" * identifier) ;) (declaration "char *pcVar5;" primitive_type (pointer_declarator "*pcVar5" * identifier) ;) (expression_statement "iVar2 = (*(code *)PTR_strlen_00146390)();" (assignment_expression "iVar2 = (*(code *)PTR_strlen_00146390)()" identifier = (call_expression "(*(code *)PTR_strlen_00146390)()" (parenthesized_expression "(*(code *)PTR_strlen_00146390)" ( (pointer_expression "*(code *)PTR_strlen_00146390" * (cast_expression "(code *)PTR_strlen_00146390" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( )))) ;) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" identifier = (cast_expression "(undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" (parenthesized_expression "(*(code *)PTR_xmalloc_001445b0)" ( (pointer_expression "*(code *)PTR_xmalloc_001445b0" * (cast_expression "(code *)PTR_xmalloc_001445b0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar2 * 4 + 3)" ( (binary_expression "iVar2 * 4 + 3" (binary_expression "iVar2 * 4" identifier * number_literal) + number_literal) ))))) ;) (if_statement "if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }" if (parenthesized_expression "((*param_1 == '\'') && (param_1[1] == '\0'))" ( (binary_expression "(*param_1 == '\'') && (param_1[1] == '\0')" (parenthesized_expression "(*param_1 == '\'')" ( (binary_expression "*param_1 == '\''" (pointer_expression "*param_1" * identifier) == (char_literal "'\''" ' escape_sequence ')) )) && (parenthesized_expression "(param_1[1] == '\0')" ( (binary_expression "param_1[1] == '\0'" (subscript_expression "param_1[1]" identifier [ number_literal ]) == (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }" { (expression_statement "puVar3[1] = 0x27;" (assignment_expression "puVar3[1] = 0x27" (subscript_expression "puVar3[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "puVar3[2] = 0;" (assignment_expression "puVar3[2] = 0" (subscript_expression "puVar3[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "*puVar3 = 0x5c;" (assignment_expression "*puVar3 = 0x5c" (pointer_expression "*puVar3" * identifier) = number_literal) ;) (return_statement "return;" return ;) })) (expression_statement "*puVar3 = 0x27;" (assignment_expression "*puVar3 = 0x27" (pointer_expression "*puVar3" * identifier) = number_literal) ;) (expression_statement "pcVar4 = puVar3 + 1;" (assignment_expression "pcVar4 = puVar3 + 1" identifier = (binary_expression "puVar3 + 1" identifier + number_literal)) ;) (do_statement "do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);" do (compound_statement "{\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  }" { (while_statement "while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }" { (expression_statement "cVar1 = *param_1;" (assignment_expression "cVar1 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (if_statement "if (cVar1 == '\0') goto LAB_000dad1c;" if (parenthesized_expression "(cVar1 == '\0')" ( (binary_expression "cVar1 == '\0'" identifier == (char_literal "'\0'" ' escape_sequence ')) )) (goto_statement "goto LAB_000dad1c;" goto statement_identifier ;)) (expression_statement "*pcVar4 = cVar1;" (assignment_expression "*pcVar4 = cVar1" (pointer_expression "*pcVar4" * identifier) = identifier) ;) (if_statement "if (cVar1 != '\'') break;" if (parenthesized_expression "(cVar1 != '\'')" ( (binary_expression "cVar1 != '\''" identifier != (char_literal "'\''" ' escape_sequence ')) )) (break_statement "break;" break ;)) (expression_statement "pcVar4[1] = '\\';" (assignment_expression "pcVar4[1] = '\\'" (subscript_expression "pcVar4[1]" identifier [ number_literal ]) = (char_literal "'\\'" ' escape_sequence ')) ;) (expression_statement "pcVar5 = pcVar4 + 4;" (assignment_expression "pcVar5 = pcVar4 + 4" identifier = (binary_expression "pcVar4 + 4" identifier + number_literal)) ;) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "pcVar4[2] = '\'';" (assignment_expression "pcVar4[2] = '\''" (subscript_expression "pcVar4[2]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4[3] = '\'';" (assignment_expression "pcVar4[3] = '\''" (subscript_expression "pcVar4[3]" identifier [ number_literal ]) = (char_literal "'\''" ' escape_sequence ')) ;) (expression_statement "pcVar4 = pcVar5;" (assignment_expression "pcVar4 = pcVar5" identifier = identifier) ;) (if_statement "if (param_1 == (char *)0x0) goto LAB_000dad1c;" if (parenthesized_expression "(param_1 == (char *)0x0)" ( (binary_expression "param_1 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (goto_statement "goto LAB_000dad1c;" goto statement_identifier ;)) })) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" identifier = (binary_expression "pcVar4 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_1 != (char *)0x0)" ( (binary_expression "param_1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) ;) (labeled_statement "LAB_000dad1c:\n  pcVar4[1] = '\0';" statement_identifier : (expression_statement "pcVar4[1] = '\0';" (assignment_expression "pcVar4[1] = '\0'" (subscript_expression "pcVar4[1]" identifier [ number_literal ]) = (char_literal "'\0'" ' escape_sequence ')) ;)) (expression_statement "*pcVar4 = '\'';" (assignment_expression "*pcVar4 = '\''" (pointer_expression "*pcVar4" * identifier) = (char_literal "'\''" ' escape_sequence ')) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression (binary_expression IDENT * LIT) + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == (char_literal ' escape_sequence ')) )) && (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == (char_literal ' escape_sequence ')) ))) )) (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (return_statement return ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (do_statement do (compound_statement { (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' escape_sequence ')) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (char_literal ' escape_sequence ')) )) (break_statement break ;)) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (char_literal ' escape_sequence ')) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (char_literal ' escape_sequence ')) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (char_literal ' escape_sequence ')) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (goto_statement goto statement_identifier ;)) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (char_literal ' escape_sequence ')) ;)) (expression_statement (assignment_expression (pointer_expression * IDENT) = (char_literal ' escape_sequence ')) ;) (return_statement return ;) })))
(function_definition "void sh_single_quote(char *param_1)\n\n{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}" (primitive_type "void") (function_declarator "sh_single_quote(char *param_1)" (identifier "sh_single_quote") (parameter_list "(char *param_1)" (( "(") (parameter_declaration "char *param_1" (primitive_type "char") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) () ")"))) (compound_statement "{\n  char cVar1;\n  int iVar2;\n  undefined1 *puVar3;\n  char *pcVar4;\n  char *pcVar5;\n  \n  iVar2 = (*(code *)PTR_strlen_00146390)();\n  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);\n  if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }\n  *puVar3 = 0x27;\n  pcVar4 = puVar3 + 1;\n  do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);\nLAB_000dad1c:\n  pcVar4[1] = '\0';\n  *pcVar4 = '\'';\n  return;\n}" ({ "{") (declaration "char cVar1;" (primitive_type "char") (identifier "cVar1") (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "undefined1 *puVar3;" (type_identifier "undefined1") (pointer_declarator "*puVar3" (* "*") (identifier "puVar3")) (; ";")) (declaration "char *pcVar4;" (primitive_type "char") (pointer_declarator "*pcVar4" (* "*") (identifier "pcVar4")) (; ";")) (declaration "char *pcVar5;" (primitive_type "char") (pointer_declarator "*pcVar5" (* "*") (identifier "pcVar5")) (; ";")) (expression_statement "iVar2 = (*(code *)PTR_strlen_00146390)();" (assignment_expression "iVar2 = (*(code *)PTR_strlen_00146390)()" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_strlen_00146390)()" (parenthesized_expression "(*(code *)PTR_strlen_00146390)" (( "(") (pointer_expression "*(code *)PTR_strlen_00146390" (* "*") (cast_expression "(code *)PTR_strlen_00146390" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_strlen_00146390"))) () ")")) (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);" (assignment_expression "puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" (identifier "puVar3") (= "=") (cast_expression "(undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3)" (parenthesized_expression "(*(code *)PTR_xmalloc_001445b0)" (( "(") (pointer_expression "*(code *)PTR_xmalloc_001445b0" (* "*") (cast_expression "(code *)PTR_xmalloc_001445b0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_xmalloc_001445b0"))) () ")")) (argument_list "(iVar2 * 4 + 3)" (( "(") (binary_expression "iVar2 * 4 + 3" (binary_expression "iVar2 * 4" (identifier "iVar2") (* "*") (number_literal "4")) (+ "+") (number_literal "3")) () ")"))))) (; ";")) (if_statement "if ((*param_1 == '\'') && (param_1[1] == '\0')) {\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }" (if "if") (parenthesized_expression "((*param_1 == '\'') && (param_1[1] == '\0'))" (( "(") (binary_expression "(*param_1 == '\'') && (param_1[1] == '\0')" (parenthesized_expression "(*param_1 == '\'')" (( "(") (binary_expression "*param_1 == '\''" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (== "==") (char_literal "'\''" (' "'") (escape_sequence "\'") (' "'"))) () ")")) (&& "&&") (parenthesized_expression "(param_1[1] == '\0')" (( "(") (binary_expression "param_1[1] == '\0'" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")"))) () ")")) (compound_statement "{\n    puVar3[1] = 0x27;\n    puVar3[2] = 0;\n    *puVar3 = 0x5c;\n    return;\n  }" ({ "{") (expression_statement "puVar3[1] = 0x27;" (assignment_expression "puVar3[1] = 0x27" (subscript_expression "puVar3[1]" (identifier "puVar3") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0x27")) (; ";")) (expression_statement "puVar3[2] = 0;" (assignment_expression "puVar3[2] = 0" (subscript_expression "puVar3[2]" (identifier "puVar3") ([ "[") (number_literal "2") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "*puVar3 = 0x5c;" (assignment_expression "*puVar3 = 0x5c" (pointer_expression "*puVar3" (* "*") (identifier "puVar3")) (= "=") (number_literal "0x5c")) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "*puVar3 = 0x27;" (assignment_expression "*puVar3 = 0x27" (pointer_expression "*puVar3" (* "*") (identifier "puVar3")) (= "=") (number_literal "0x27")) (; ";")) (expression_statement "pcVar4 = puVar3 + 1;" (assignment_expression "pcVar4 = puVar3 + 1" (identifier "pcVar4") (= "=") (binary_expression "puVar3 + 1" (identifier "puVar3") (+ "+") (number_literal "1"))) (; ";")) (do_statement "do {\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  } while (param_1 != (char *)0x0);" (do "do") (compound_statement "{\n    while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }\n    param_1 = param_1 + 1;\n    pcVar4 = pcVar4 + 1;\n  }" ({ "{") (while_statement "while( true ) {\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n      cVar1 = *param_1;\n      if (cVar1 == '\0') goto LAB_000dad1c;\n      *pcVar4 = cVar1;\n      if (cVar1 != '\'') break;\n      pcVar4[1] = '\\';\n      pcVar5 = pcVar4 + 4;\n      param_1 = param_1 + 1;\n      pcVar4[2] = '\'';\n      pcVar4[3] = '\'';\n      pcVar4 = pcVar5;\n      if (param_1 == (char *)0x0) goto LAB_000dad1c;\n    }" ({ "{") (expression_statement "cVar1 = *param_1;" (assignment_expression "cVar1 = *param_1" (identifier "cVar1") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";")) (if_statement "if (cVar1 == '\0') goto LAB_000dad1c;" (if "if") (parenthesized_expression "(cVar1 == '\0')" (( "(") (binary_expression "cVar1 == '\0'" (identifier "cVar1") (== "==") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (goto_statement "goto LAB_000dad1c;" (goto "goto") (statement_identifier "LAB_000dad1c") (; ";"))) (expression_statement "*pcVar4 = cVar1;" (assignment_expression "*pcVar4 = cVar1" (pointer_expression "*pcVar4" (* "*") (identifier "pcVar4")) (= "=") (identifier "cVar1")) (; ";")) (if_statement "if (cVar1 != '\'') break;" (if "if") (parenthesized_expression "(cVar1 != '\'')" (( "(") (binary_expression "cVar1 != '\''" (identifier "cVar1") (!= "!=") (char_literal "'\''" (' "'") (escape_sequence "\'") (' "'"))) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "pcVar4[1] = '\\';" (assignment_expression "pcVar4[1] = '\\'" (subscript_expression "pcVar4[1]" (identifier "pcVar4") ([ "[") (number_literal "1") (] "]")) (= "=") (char_literal "'\\'" (' "'") (escape_sequence "\\") (' "'"))) (; ";")) (expression_statement "pcVar5 = pcVar4 + 4;" (assignment_expression "pcVar5 = pcVar4 + 4" (identifier "pcVar5") (= "=") (binary_expression "pcVar4 + 4" (identifier "pcVar4") (+ "+") (number_literal "4"))) (; ";")) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" (identifier "param_1") (= "=") (binary_expression "param_1 + 1" (identifier "param_1") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "pcVar4[2] = '\'';" (assignment_expression "pcVar4[2] = '\''" (subscript_expression "pcVar4[2]" (identifier "pcVar4") ([ "[") (number_literal "2") (] "]")) (= "=") (char_literal "'\''" (' "'") (escape_sequence "\'") (' "'"))) (; ";")) (expression_statement "pcVar4[3] = '\'';" (assignment_expression "pcVar4[3] = '\''" (subscript_expression "pcVar4[3]" (identifier "pcVar4") ([ "[") (number_literal "3") (] "]")) (= "=") (char_literal "'\''" (' "'") (escape_sequence "\'") (' "'"))) (; ";")) (expression_statement "pcVar4 = pcVar5;" (assignment_expression "pcVar4 = pcVar5" (identifier "pcVar4") (= "=") (identifier "pcVar5")) (; ";")) (if_statement "if (param_1 == (char *)0x0) goto LAB_000dad1c;" (if "if") (parenthesized_expression "(param_1 == (char *)0x0)" (( "(") (binary_expression "param_1 == (char *)0x0" (identifier "param_1") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (goto_statement "goto LAB_000dad1c;" (goto "goto") (statement_identifier "LAB_000dad1c") (; ";"))) (} "}"))) (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" (identifier "param_1") (= "=") (binary_expression "param_1 + 1" (identifier "param_1") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "pcVar4 = pcVar4 + 1;" (assignment_expression "pcVar4 = pcVar4 + 1" (identifier "pcVar4") (= "=") (binary_expression "pcVar4 + 1" (identifier "pcVar4") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(param_1 != (char *)0x0)" (( "(") (binary_expression "param_1 != (char *)0x0" (identifier "param_1") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (; ";")) (labeled_statement "LAB_000dad1c:\n  pcVar4[1] = '\0';" (statement_identifier "LAB_000dad1c") (: ":") (expression_statement "pcVar4[1] = '\0';" (assignment_expression "pcVar4[1] = '\0'" (subscript_expression "pcVar4[1]" (identifier "pcVar4") ([ "[") (number_literal "1") (] "]")) (= "=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) (; ";"))) (expression_statement "*pcVar4 = '\'';" (assignment_expression "*pcVar4 = '\''" (pointer_expression "*pcVar4" (* "*") (identifier "pcVar4")) (= "=") (char_literal "'\''" (' "'") (escape_sequence "\'") (' "'"))) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

char * function_1(char *var_5)

{
  char var_3;
  int var_1;
  char *var_2;
  char *var_4;
  char *pcVar5;
  
  var_1 = (*(type_1 *)PTR_strlen_00146390)();
  var_2 = (char *)(*(type_1 *)PTR_xmalloc_001445b0)(var_1 * 4 + 3);
  if ((*var_5 == '\'') && (var_5[1] == '\0')) {
    var_2[1] = '\'';
    var_2[2] = '\0';
    *var_2 = '\\';
    return var_2;
  }
  *var_2 = '\'';
  var_4 = var_2 + 1;
  do {
    while( true ) {
      var_3 = *var_5;
      if (var_3 == '\0') goto LAB_000dad1c;
      *var_4 = var_3;
      if (var_3 != '\'') break;
      var_4[1] = '\\';
      pcVar5 = var_4 + 4;
      var_5 = var_5 + 1;
      var_4[2] = '\'';
      var_4[3] = '\'';
      var_4 = pcVar5;
      if (var_5 == (char *)0x0) goto LAB_000dad1c;
    }
    var_5 = var_5 + 1;
    var_4 = var_4 + 1;
  } while (var_5 != (char *)0x0);
LAB_000dad1c:
  var_4[1] = '\0';
  *var_4 = '\'';
  return var_2;
}


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

void MASKED(char *param_1)

{
  char cVar1;
  int iVar2;
  undefined1 *puVar3;
  char *pcVar4;
  char *pcVar5;
  
  iVar2 = (*(code *)PTR_strlen_00146390)();
  puVar3 = (undefined1 *)(*(code *)PTR_xmalloc_001445b0)(iVar2 * 4 + 3);
  if ((*param_1 == '\'') && (param_1[1] == '\0')) {
    puVar3[1] = 0x27;
    puVar3[2] = 0;
    *puVar3 = 0x5c;
    return;
  }
  *puVar3 = 0x27;
  pcVar4 = puVar3 + 1;
  do {
    while( true ) {
      cVar1 = *param_1;
      if (cVar1 == '\0') goto LAB_000dad1c;
      *pcVar4 = cVar1;
      if (cVar1 != '\'') break;
      pcVar4[1] = '\\';
      pcVar5 = pcVar4 + 4;
      param_1 = param_1 + 1;
      pcVar4[2] = '\'';
      pcVar4[3] = '\'';
      pcVar4 = pcVar5;
      if (param_1 == (char *)0x0) goto LAB_000dad1c;
    }
    param_1 = param_1 + 1;
    pcVar4 = pcVar4 + 1;
  } while (param_1 != (char *)0x0);
LAB_000dad1c:
  pcVar4[1] = '\0';
  *pcVar4 = '\'';
  return;
}

