
/* WARNING: Enum "anon_enum_32": Some values do not have unique names */

void sk_tcp_close(Socket sock)

{
  int iVar1;
  SockAddr addr;
  
  if (sock[0x1b] != (socket_function_table *)0x0) {
    sk_tcp_close((Socket)sock[0x1b]);
  }
  (*(code *)PTR_bufchain_clear_0007937c)(sock + 4);
  uxsel_del((int)sock[2]);
  del234(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock);
  (*(code *)PTR_close_00079714)(sock[2]);
  addr = (SockAddr)sock[0x17];
  if ((addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)) {
    sk_addr_free(addr);
  }
  (*(code *)PTR_delete_callbacks_for_context_00079604)(sock);
  (*(code *)PTR_safefree_000790f0)(sock);
  return;
}



void FUN_00052a38(int param_1)

{
  int iVar1;
  int *piVar2;
  
  if (*(int *)(param_1 + 0x6c) != 0) {
    FUN_00052a38();
  }
  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);
  uxsel_del(*(undefined4 *)(param_1 + 8));
  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);
  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));
  piVar2 = *(int **)(param_1 + 0x5c);
  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {
    FUN_000529e8();
  }
  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);
  (*(code *)PTR_safefree_000790f0)(param_1);
  return;
}


lui gp,0x3
addiu gp,gp,-0x19c8
addu gp,gp,t9
addiu sp,sp,-0x20
sw s0,0x18(sp)
or s0,a0,zero
sw gp,0x10(sp)
sw ra,0x1c(sp)
lw a0,0x6c(a0)
beq a0,zero,0x00052a74
_lw t9,-0x7fb4(gp)
addiu t9,t9,0x2a38
bal 0x00052a38
_nop
lw gp,0x10(sp)
lw t9,-0x7cf4(gp)
jalr t9
_addiu a0,s0,0x10
lw gp,0x10(sp)
lw t9,-0x7aa8(gp)
bal 0x00058108
_lw a0,0x8(s0)
or a1,s0,zero
lw gp,0x10(sp)
lw v0,-0x7fd8(gp)
lw t9,-0x7de0(gp)
bal 0x0004e270
_lw a0,-0x6410(v0)
lw gp,0x10(sp)
lw t9,-0x795c(gp)
jalr t9
_lw a0,0x8(s0)
lw a0,0x5c(s0)
beq a0,zero,0x00052ae8
_lw gp,0x10(sp)
lw v0,0x0(a0)
addiu v0,v0,-0x1
bgtz v0,0x00052ae8
_sw v0,0x0(a0)
lw t9,-0x7fb4(gp)
addiu t9,t9,0x29e8
bal 0x000529e8
_nop
lw gp,0x10(sp)
lw t9,-0x7a6c(gp)
jalr t9
_or a0,s0,zero
or a0,s0,zero
lw gp,0x10(sp)
lw ra,0x1c(sp)
lw s0,0x18(sp)
lw t9,-0x7f80(gp)
jr t9
_addiu sp,sp,0x20
(translation_unit "void FUN_00052a38(int param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}\n\n" (function_definition "void FUN_00052a38(int param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}" primitive_type (function_declarator "FUN_00052a38(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (if_statement "if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x6c) != 0)" ( (binary_expression "*(int *)(param_1 + 0x6c) != 0" (pointer_expression "*(int *)(param_1 + 0x6c)" * (cast_expression "(int *)(param_1 + 0x6c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x6c)" ( (binary_expression "param_1 + 0x6c" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    FUN_00052a38();\n  }" { (expression_statement "FUN_00052a38();" (call_expression "FUN_00052a38()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "(*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);" (call_expression "(*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10)" (parenthesized_expression "(*(code *)PTR_bufchain_clear_0007937c)" ( (pointer_expression "*(code *)PTR_bufchain_clear_0007937c" * (cast_expression "(code *)PTR_bufchain_clear_0007937c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))) ;) (expression_statement "uxsel_del(*(undefined4 *)(param_1 + 8));" (call_expression "uxsel_del(*(undefined4 *)(param_1 + 8))" identifier (argument_list "(*(undefined4 *)(param_1 + 8))" ( (pointer_expression "*(undefined4 *)(param_1 + 8)" * (cast_expression "(undefined4 *)(param_1 + 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) ))) ;) (expression_statement "del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);" (call_expression "del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1)" identifier (argument_list "(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1)" ( (pointer_expression "*(undefined4 *)(PTR_DAT_00079098 + -0x6410)" * (cast_expression "(undefined4 *)(PTR_DAT_00079098 + -0x6410)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_DAT_00079098 + -0x6410)" ( (binary_expression "PTR_DAT_00079098 + -0x6410" identifier + number_literal) )))) , identifier ))) ;) (expression_statement "(*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));" (call_expression "(*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8))" (parenthesized_expression "(*(code *)PTR_close_00079714)" ( (pointer_expression "*(code *)PTR_close_00079714" * (cast_expression "(code *)PTR_close_00079714" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 8))" ( (pointer_expression "*(undefined4 *)(param_1 + 8)" * (cast_expression "(undefined4 *)(param_1 + 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) ))) ;) (expression_statement "piVar2 = *(int **)(param_1 + 0x5c);" (assignment_expression "piVar2 = *(int **)(param_1 + 0x5c)" identifier = (pointer_expression "*(int **)(param_1 + 0x5c)" * (cast_expression "(int **)(param_1 + 0x5c)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x5c)" ( (binary_expression "param_1 + 0x5c" identifier + number_literal) ))))) ;) (if_statement "if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }" if (parenthesized_expression "((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1))" ( (binary_expression "(piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)" (parenthesized_expression "(piVar2 != (int *)0x0)" ( (binary_expression "piVar2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)" ( (comma_expression "iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1" (assignment_expression "iVar1 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) , (comma_expression "*piVar2 = iVar1 + -1, iVar1 + -1 < 1" (assignment_expression "*piVar2 = iVar1 + -1" (pointer_expression "*piVar2" * identifier) = (binary_expression "iVar1 + -1" identifier + number_literal)) , (binary_expression "iVar1 + -1 < 1" (binary_expression "iVar1 + -1" identifier + number_literal) < number_literal))) ))) )) (compound_statement "{\n    FUN_000529e8();\n  }" { (expression_statement "FUN_000529e8();" (call_expression "FUN_000529e8()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "(*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);" (call_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)(param_1)" (parenthesized_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)" ( (pointer_expression "*(code *)PTR_delete_callbacks_for_context_00079604" * (cast_expression "(code *)PTR_delete_callbacks_for_context_00079604" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000790f0)(param_1);" (call_expression "(*(code *)PTR_safefree_000790f0)(param_1)" (parenthesized_expression "(*(code *)PTR_safefree_000790f0)" ( (pointer_expression "*(code *)PTR_safefree_000790f0" * (cast_expression "(code *)PTR_safefree_000790f0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1)" ( identifier ))) ;) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Enum "anon_enum_32": Some values do not have unique names */\n\nvoid sk_tcp_close(Socket sock)\n\n{\n  int iVar1;\n  SockAddr addr;\n  \n  if (sock[0x1b] != (socket_function_table *)0x0) {\n    sk_tcp_close((Socket)sock[0x1b]);\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(sock + 4);\n  uxsel_del((int)sock[2]);\n  del234(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock);\n  (*(code *)PTR_close_00079714)(sock[2]);\n  addr = (SockAddr)sock[0x17];\n  if ((addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)) {\n    sk_addr_free(addr);\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(sock);\n  (*(code *)PTR_safefree_000790f0)(sock);\n  return;\n}\n\n" comment (function_definition "void sk_tcp_close(Socket sock)\n\n{\n  int iVar1;\n  SockAddr addr;\n  \n  if (sock[0x1b] != (socket_function_table *)0x0) {\n    sk_tcp_close((Socket)sock[0x1b]);\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(sock + 4);\n  uxsel_del((int)sock[2]);\n  del234(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock);\n  (*(code *)PTR_close_00079714)(sock[2]);\n  addr = (SockAddr)sock[0x17];\n  if ((addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)) {\n    sk_addr_free(addr);\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(sock);\n  (*(code *)PTR_safefree_000790f0)(sock);\n  return;\n}" primitive_type (function_declarator "sk_tcp_close(Socket sock)" identifier (parameter_list "(Socket sock)" ( (parameter_declaration "Socket sock" type_identifier identifier) ))) (compound_statement "{\n  int iVar1;\n  SockAddr addr;\n  \n  if (sock[0x1b] != (socket_function_table *)0x0) {\n    sk_tcp_close((Socket)sock[0x1b]);\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(sock + 4);\n  uxsel_del((int)sock[2]);\n  del234(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock);\n  (*(code *)PTR_close_00079714)(sock[2]);\n  addr = (SockAddr)sock[0x17];\n  if ((addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)) {\n    sk_addr_free(addr);\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(sock);\n  (*(code *)PTR_safefree_000790f0)(sock);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "SockAddr addr;" type_identifier identifier ;) (if_statement "if (sock[0x1b] != (socket_function_table *)0x0) {\n    sk_tcp_close((Socket)sock[0x1b]);\n  }" if (parenthesized_expression "(sock[0x1b] != (socket_function_table *)0x0)" ( (binary_expression "sock[0x1b] != (socket_function_table *)0x0" (subscript_expression "sock[0x1b]" identifier [ number_literal ]) != (cast_expression "(socket_function_table *)0x0" ( (type_descriptor "socket_function_table *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    sk_tcp_close((Socket)sock[0x1b]);\n  }" { (expression_statement "sk_tcp_close((Socket)sock[0x1b]);" (call_expression "sk_tcp_close((Socket)sock[0x1b])" identifier (argument_list "((Socket)sock[0x1b])" ( (cast_expression "(Socket)sock[0x1b]" ( (type_descriptor "Socket" type_identifier) ) (subscript_expression "sock[0x1b]" identifier [ number_literal ])) ))) ;) })) (expression_statement "(*(code *)PTR_bufchain_clear_0007937c)(sock + 4);" (call_expression "(*(code *)PTR_bufchain_clear_0007937c)(sock + 4)" (parenthesized_expression "(*(code *)PTR_bufchain_clear_0007937c)" ( (pointer_expression "*(code *)PTR_bufchain_clear_0007937c" * (cast_expression "(code *)PTR_bufchain_clear_0007937c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(sock + 4)" ( (binary_expression "sock + 4" identifier + number_literal) ))) ;) (expression_statement "uxsel_del((int)sock[2]);" (call_expression "uxsel_del((int)sock[2])" identifier (argument_list "((int)sock[2])" ( (cast_expression "(int)sock[2]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "sock[2]" identifier [ number_literal ])) ))) ;) (expression_statement "del234(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock);" (call_expression "del234(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock)" identifier (argument_list "(*(tree234 **)(PTR_DAT_00079098 + -0x6410),sock)" ( (pointer_expression "*(tree234 **)(PTR_DAT_00079098 + -0x6410)" * (cast_expression "(tree234 **)(PTR_DAT_00079098 + -0x6410)" ( (type_descriptor "tree234 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(PTR_DAT_00079098 + -0x6410)" ( (binary_expression "PTR_DAT_00079098 + -0x6410" identifier + number_literal) )))) , identifier ))) ;) (expression_statement "(*(code *)PTR_close_00079714)(sock[2]);" (call_expression "(*(code *)PTR_close_00079714)(sock[2])" (parenthesized_expression "(*(code *)PTR_close_00079714)" ( (pointer_expression "*(code *)PTR_close_00079714" * (cast_expression "(code *)PTR_close_00079714" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(sock[2])" ( (subscript_expression "sock[2]" identifier [ number_literal ]) ))) ;) (expression_statement "addr = (SockAddr)sock[0x17];" (assignment_expression "addr = (SockAddr)sock[0x17]" identifier = (cast_expression "(SockAddr)sock[0x17]" ( (type_descriptor "SockAddr" type_identifier) ) (subscript_expression "sock[0x17]" identifier [ number_literal ]))) ;) (if_statement "if ((addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)) {\n    sk_addr_free(addr);\n  }" if (parenthesized_expression "((addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1))" ( (binary_expression "(addr != (SockAddr)0x0) && (iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)" (parenthesized_expression "(addr != (SockAddr)0x0)" ( (binary_expression "addr != (SockAddr)0x0" identifier != (cast_expression "(SockAddr)0x0" ( (type_descriptor "SockAddr" type_identifier) ) number_literal)) )) && (parenthesized_expression "(iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1)" ( (comma_expression "iVar1 = addr->refcount + -1, addr->refcount = iVar1, iVar1 < 1" (assignment_expression "iVar1 = addr->refcount + -1" identifier = (binary_expression "addr->refcount + -1" (field_expression "addr->refcount" identifier -> field_identifier) + number_literal)) , (comma_expression "addr->refcount = iVar1, iVar1 < 1" (assignment_expression "addr->refcount = iVar1" (field_expression "addr->refcount" identifier -> field_identifier) = identifier) , (binary_expression "iVar1 < 1" identifier < number_literal))) ))) )) (compound_statement "{\n    sk_addr_free(addr);\n  }" { (expression_statement "sk_addr_free(addr);" (call_expression "sk_addr_free(addr)" identifier (argument_list "(addr)" ( identifier ))) ;) })) (expression_statement "(*(code *)PTR_delete_callbacks_for_context_00079604)(sock);" (call_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)(sock)" (parenthesized_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)" ( (pointer_expression "*(code *)PTR_delete_callbacks_for_context_00079604" * (cast_expression "(code *)PTR_delete_callbacks_for_context_00079604" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(sock)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000790f0)(sock);" (call_expression "(*(code *)PTR_safefree_000790f0)(sock)" (parenthesized_expression "(*(code *)PTR_safefree_000790f0)" ( (pointer_expression "*(code *)PTR_safefree_000790f0" * (cast_expression "(code *)PTR_safefree_000790f0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(sock)" ( identifier ))) ;) (return_statement "return;" return ;) })))
(translation_unit "void FUN_00052a38(int param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}\n\n" (function_definition "void FUN_00052a38(int param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}" primitive_type (function_declarator "FUN_00052a38(int param_1)" identifier (parameter_list "(int param_1)" ( (parameter_declaration "int param_1" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (if_statement "if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x6c) != 0)" ( (binary_expression "*(int *)(param_1 + 0x6c) != 0" (pointer_expression "*(int *)(param_1 + 0x6c)" * (cast_expression "(int *)(param_1 + 0x6c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x6c)" ( (binary_expression "param_1 + 0x6c" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n    FUN_00052a38();\n  }" { (expression_statement "FUN_00052a38();" (call_expression "FUN_00052a38()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "(*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);" (call_expression "(*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10)" (parenthesized_expression "(*(code *)PTR_bufchain_clear_0007937c)" ( (pointer_expression "*(code *)PTR_bufchain_clear_0007937c" * (cast_expression "(code *)PTR_bufchain_clear_0007937c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) ))) ;) (expression_statement "uxsel_del(*(undefined4 *)(param_1 + 8));" (call_expression "uxsel_del(*(undefined4 *)(param_1 + 8))" identifier (argument_list "(*(undefined4 *)(param_1 + 8))" ( (pointer_expression "*(undefined4 *)(param_1 + 8)" * (cast_expression "(undefined4 *)(param_1 + 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) ))) ;) (expression_statement "del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);" (call_expression "del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1)" identifier (argument_list "(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1)" ( (pointer_expression "*(undefined4 *)(PTR_DAT_00079098 + -0x6410)" * (cast_expression "(undefined4 *)(PTR_DAT_00079098 + -0x6410)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_DAT_00079098 + -0x6410)" ( (binary_expression "PTR_DAT_00079098 + -0x6410" identifier + number_literal) )))) , identifier ))) ;) (expression_statement "(*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));" (call_expression "(*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8))" (parenthesized_expression "(*(code *)PTR_close_00079714)" ( (pointer_expression "*(code *)PTR_close_00079714" * (cast_expression "(code *)PTR_close_00079714" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 8))" ( (pointer_expression "*(undefined4 *)(param_1 + 8)" * (cast_expression "(undefined4 *)(param_1 + 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 8)" ( (binary_expression "param_1 + 8" identifier + number_literal) )))) ))) ;) (expression_statement "piVar2 = *(int **)(param_1 + 0x5c);" (assignment_expression "piVar2 = *(int **)(param_1 + 0x5c)" identifier = (pointer_expression "*(int **)(param_1 + 0x5c)" * (cast_expression "(int **)(param_1 + 0x5c)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 0x5c)" ( (binary_expression "param_1 + 0x5c" identifier + number_literal) ))))) ;) (if_statement "if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }" if (parenthesized_expression "((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1))" ( (binary_expression "(piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)" (parenthesized_expression "(piVar2 != (int *)0x0)" ( (binary_expression "piVar2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)" ( (comma_expression "iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1" (assignment_expression "iVar1 = *piVar2" identifier = (pointer_expression "*piVar2" * identifier)) , (comma_expression "*piVar2 = iVar1 + -1, iVar1 + -1 < 1" (assignment_expression "*piVar2 = iVar1 + -1" (pointer_expression "*piVar2" * identifier) = (binary_expression "iVar1 + -1" identifier + number_literal)) , (binary_expression "iVar1 + -1 < 1" (binary_expression "iVar1 + -1" identifier + number_literal) < number_literal))) ))) )) (compound_statement "{\n    FUN_000529e8();\n  }" { (expression_statement "FUN_000529e8();" (call_expression "FUN_000529e8()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "(*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);" (call_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)(param_1)" (parenthesized_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)" ( (pointer_expression "*(code *)PTR_delete_callbacks_for_context_00079604" * (cast_expression "(code *)PTR_delete_callbacks_for_context_00079604" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1)" ( identifier ))) ;) (expression_statement "(*(code *)PTR_safefree_000790f0)(param_1);" (call_expression "(*(code *)PTR_safefree_000790f0)(param_1)" (parenthesized_expression "(*(code *)PTR_safefree_000790f0)" ( (pointer_expression "*(code *)PTR_safefree_000790f0" * (cast_expression "(code *)PTR_safefree_000790f0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(param_1)" ( identifier ))) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (binary_expression IDENT + LIT) ))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , IDENT ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (pointer_expression * IDENT)) , (comma_expression (assignment_expression (pointer_expression * IDENT) = (binary_expression IDENT + LIT)) , (binary_expression (binary_expression IDENT + LIT) < LIT))) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (return_statement return ;) })))
(function_definition "void FUN_00052a38(int param_1)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}" (primitive_type "void") (function_declarator "FUN_00052a38(int param_1)" (identifier "FUN_00052a38") (parameter_list "(int param_1)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) () ")"))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }\n  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);\n  uxsel_del(*(undefined4 *)(param_1 + 8));\n  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);\n  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));\n  piVar2 = *(int **)(param_1 + 0x5c);\n  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }\n  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);\n  (*(code *)PTR_safefree_000790f0)(param_1);\n  return;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int *piVar2;" (primitive_type "int") (pointer_declarator "*piVar2" (* "*") (identifier "piVar2")) (; ";")) (if_statement "if (*(int *)(param_1 + 0x6c) != 0) {\n    FUN_00052a38();\n  }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0x6c) != 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x6c) != 0" (pointer_expression "*(int *)(param_1 + 0x6c)" (* "*") (cast_expression "(int *)(param_1 + 0x6c)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x6c)" (( "(") (binary_expression "param_1 + 0x6c" (identifier "param_1") (+ "+") (number_literal "0x6c")) () ")")))) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    FUN_00052a38();\n  }" ({ "{") (expression_statement "FUN_00052a38();" (call_expression "FUN_00052a38()" (identifier "FUN_00052a38") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (expression_statement "(*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);" (call_expression "(*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10)" (parenthesized_expression "(*(code *)PTR_bufchain_clear_0007937c)" (( "(") (pointer_expression "*(code *)PTR_bufchain_clear_0007937c" (* "*") (cast_expression "(code *)PTR_bufchain_clear_0007937c" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_bufchain_clear_0007937c"))) () ")")) (argument_list "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")"))) (; ";")) (expression_statement "uxsel_del(*(undefined4 *)(param_1 + 8));" (call_expression "uxsel_del(*(undefined4 *)(param_1 + 8))" (identifier "uxsel_del") (argument_list "(*(undefined4 *)(param_1 + 8))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 8)" (* "*") (cast_expression "(undefined4 *)(param_1 + 8)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) () ")"))) (; ";")) (expression_statement "del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);" (call_expression "del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1)" (identifier "del234") (argument_list "(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1)" (( "(") (pointer_expression "*(undefined4 *)(PTR_DAT_00079098 + -0x6410)" (* "*") (cast_expression "(undefined4 *)(PTR_DAT_00079098 + -0x6410)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(PTR_DAT_00079098 + -0x6410)" (( "(") (binary_expression "PTR_DAT_00079098 + -0x6410" (identifier "PTR_DAT_00079098") (+ "+") (number_literal "-0x6410")) () ")")))) (, ",") (identifier "param_1") () ")"))) (; ";")) (expression_statement "(*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));" (call_expression "(*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8))" (parenthesized_expression "(*(code *)PTR_close_00079714)" (( "(") (pointer_expression "*(code *)PTR_close_00079714" (* "*") (cast_expression "(code *)PTR_close_00079714" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_close_00079714"))) () ")")) (argument_list "(*(undefined4 *)(param_1 + 8))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 8)" (* "*") (cast_expression "(undefined4 *)(param_1 + 8)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 8)" (( "(") (binary_expression "param_1 + 8" (identifier "param_1") (+ "+") (number_literal "8")) () ")")))) () ")"))) (; ";")) (expression_statement "piVar2 = *(int **)(param_1 + 0x5c);" (assignment_expression "piVar2 = *(int **)(param_1 + 0x5c)" (identifier "piVar2") (= "=") (pointer_expression "*(int **)(param_1 + 0x5c)" (* "*") (cast_expression "(int **)(param_1 + 0x5c)" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 0x5c)" (( "(") (binary_expression "param_1 + 0x5c" (identifier "param_1") (+ "+") (number_literal "0x5c")) () ")"))))) (; ";")) (if_statement "if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {\n    FUN_000529e8();\n  }" (if "if") (parenthesized_expression "((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1))" (( "(") (binary_expression "(piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)" (parenthesized_expression "(piVar2 != (int *)0x0)" (( "(") (binary_expression "piVar2 != (int *)0x0" (identifier "piVar2") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)" (( "(") (comma_expression "iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1" (assignment_expression "iVar1 = *piVar2" (identifier "iVar1") (= "=") (pointer_expression "*piVar2" (* "*") (identifier "piVar2"))) (, ",") (comma_expression "*piVar2 = iVar1 + -1, iVar1 + -1 < 1" (assignment_expression "*piVar2 = iVar1 + -1" (pointer_expression "*piVar2" (* "*") (identifier "piVar2")) (= "=") (binary_expression "iVar1 + -1" (identifier "iVar1") (+ "+") (number_literal "-1"))) (, ",") (binary_expression "iVar1 + -1 < 1" (binary_expression "iVar1 + -1" (identifier "iVar1") (+ "+") (number_literal "-1")) (< "<") (number_literal "1")))) () ")"))) () ")")) (compound_statement "{\n    FUN_000529e8();\n  }" ({ "{") (expression_statement "FUN_000529e8();" (call_expression "FUN_000529e8()" (identifier "FUN_000529e8") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (expression_statement "(*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);" (call_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)(param_1)" (parenthesized_expression "(*(code *)PTR_delete_callbacks_for_context_00079604)" (( "(") (pointer_expression "*(code *)PTR_delete_callbacks_for_context_00079604" (* "*") (cast_expression "(code *)PTR_delete_callbacks_for_context_00079604" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_delete_callbacks_for_context_00079604"))) () ")")) (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (expression_statement "(*(code *)PTR_safefree_000790f0)(param_1);" (call_expression "(*(code *)PTR_safefree_000790f0)(param_1)" (parenthesized_expression "(*(code *)PTR_safefree_000790f0)" (( "(") (pointer_expression "*(code *)PTR_safefree_000790f0" (* "*") (cast_expression "(code *)PTR_safefree_000790f0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_safefree_000790f0"))) () ")")) (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))
(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (expression_statement (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: (identifier) right: (number_literal))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) (identifier)))) (expression_statement (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 (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier))) right: (comma_expression left: (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (identifier) right: (number_literal))) right: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (number_literal))))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (expression_statement (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 (identifier)))) (expression_statement (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 (identifier)))) (return_statement))))

void MASKED(int param_1)

{
  int iVar1;
  int *piVar2;
  
  if (*(int *)(param_1 + 0x6c) != 0) {
    MASKED();
  }
  (*(code *)PTR_bufchain_clear_0007937c)(param_1 + 0x10);
  uxsel_del(*(undefined4 *)(param_1 + 8));
  del234(*(undefined4 *)(PTR_DAT_00079098 + -0x6410),param_1);
  (*(code *)PTR_close_00079714)(*(undefined4 *)(param_1 + 8));
  piVar2 = *(int **)(param_1 + 0x5c);
  if ((piVar2 != (int *)0x0) && (iVar1 = *piVar2, *piVar2 = iVar1 + -1, iVar1 + -1 < 1)) {
    FUN_000529e8();
  }
  (*(code *)PTR_delete_callbacks_for_context_00079604)(param_1);
  (*(code *)PTR_safefree_000790f0)(param_1);
  return;
}

