
/* std::fstream::fstream(std::string const&, std::_Ios_Openmode) */

void __thiscall std::fstream::fstream(fstream *this,string *param_1,_Ios_Openmode param_2)

{
  ios_base *this_00;
  int iVar1;
  int unaff_EDI;
  
  __x86_get_pc_thunk_di();
  this_00 = (ios_base *)(this + 0x94);
  ios_base::ios_base(this_00);
  *(undefined4 *)(this + 0x104) = 0;
  *(undefined2 *)(this + 0x108) = 0;
  *(undefined4 *)(this + 0x10c) = 0;
  *(undefined4 *)(this + 0x110) = 0;
  *(undefined4 *)(this + 0x114) = 0;
  *(undefined4 *)(this + 0x118) = 0;
  *(undefined **)this = &UNK_002087f3 + unaff_EDI;
  *(undefined **)(this + 0x94) = &UNK_00208807 + unaff_EDI;
  *(undefined4 *)(this + 4) = 0;
                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */
  ios::init((streambuf *)this_00);
  *(undefined **)(this + 0x94) = &UNK_002087df + unaff_EDI;
  *(undefined **)(this + 8) = &UNK_002087cb + unaff_EDI;
                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */
  ios::init((streambuf *)this_00);
  *(undefined **)this = &UNK_0020887f + unaff_EDI;
  *(undefined **)(this + 0x94) = &UNK_002088a7 + unaff_EDI;
  *(undefined **)(this + 8) = &UNK_00208893 + unaff_EDI;
                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */
  filebuf::filebuf((filebuf *)(this + 0xc));
                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */
  ios::init((streambuf *)this_00);
  iVar1 = filebuf::open((char *)(this + 0xc),*(_Ios_Openmode *)param_1);
  if (iVar1 != 0) {
    ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));
    return;
  }
  ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));
  return;
}



void FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)

{
  int *piVar1;
  int *piVar2;
  int iVar3;
  int iVar4;
  int unaff_EDI;
  
  FUN_00074f0a();
  piVar2 = param_1 + 0x25;
  FUN_003f2f70(piVar2);
  param_1[0x41] = 0;
  *(undefined2 *)(param_1 + 0x42) = 0;
  param_1[0x43] = 0;
  param_1[0x44] = 0;
  param_1[0x45] = 0;
  param_1[0x46] = 0;
  *param_1 = unaff_EDI + 0x2087f3;
  param_1[0x25] = unaff_EDI + 0x208807;
  param_1[1] = 0;
                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */
  FUN_003d8720(piVar2,0);
  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);
  param_1[2] = unaff_EDI + 0x2087cb;
                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */
  FUN_003d8720(piVar2,0);
  piVar1 = param_1 + 3;
  *param_1 = unaff_EDI + 0x20887f;
  param_1[0x25] = unaff_EDI + 0x2088a7;
  param_1[2] = unaff_EDI + 0x208893;
                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */
  FUN_003da940(piVar1);
                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */
  FUN_003d8720(piVar2,piVar1);
  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);
  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;
  if (iVar3 != 0) {
    FUN_003d7ed0(iVar4,0);
    return;
  }
  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);
  return;
}


PUSH EBP
MOV EBP,ESP
PUSH EDI
CALL 0x00074f0a
ADD EDI,0x20ae77
PUSH ESI
PUSH EBX
SUB ESP,0x38
MOV ESI,dword ptr [EBP + 0x8]
LEA EAX,[ESI + 0x94]
MOV EBX,EDI
PUSH EAX
MOV dword ptr [EBP + -0x1c],EAX
CALL 0x003f2f70
XOR EAX,EAX
LEA ECX,[EDI + 0xffffd97c]
MOV dword ptr [ESI + 0x104],0x0
MOV word ptr [ESI + 0x108],AX
LEA EAX,[EDI + 0xffffd990]
MOV dword ptr [ESI + 0x10c],0x0
MOV dword ptr [ESI + 0x110],0x0
MOV dword ptr [ESI + 0x114],0x0
MOV dword ptr [ESI + 0x118],0x0
MOV dword ptr [ESI],ECX
MOV dword ptr [ESI + 0x94],EAX
MOV dword ptr [ESI + 0x4],0x0
POP EAX
POP EDX
PUSH 0x0
PUSH dword ptr [EBP + -0x1c]
MOV dword ptr [EBP + -0x24],ECX
CALL 0x003d8720
POP ECX
LEA EAX,[EDI + 0xffffd968]
POP EBX
LEA EBX,[EDI + 0xffffd954]
MOV dword ptr [ESI + 0x94],EAX
MOV dword ptr [ESI + 0x8],EBX
PUSH 0x0
PUSH dword ptr [EBP + -0x1c]
MOV dword ptr [EBP + -0x28],EBX
MOV EBX,EDI
CALL 0x003d8720
LEA EAX,[EDI + 0xffffd9fc]
LEA ECX,[ESI + 0xc]
MOV dword ptr [EBP + -0x20],ECX
LEA EDX,[EAX + 0xc]
MOV dword ptr [ESI],EDX
LEA EDX,[EAX + 0x34]
ADD EAX,0x20
MOV dword ptr [ESI + 0x94],EDX
MOV dword ptr [ESI + 0x8],EAX
MOV dword ptr [ESP],ECX
CALL 0x003da940
POP EAX
POP EDX
PUSH dword ptr [EBP + -0x20]
PUSH dword ptr [EBP + -0x1c]
CALL 0x003d8720
MOV EAX,dword ptr [EBP + 0xc]
ADD ESP,0xc
PUSH dword ptr [EBP + 0x10]
PUSH dword ptr [EAX]
PUSH dword ptr [EBP + -0x20]
CALL 0x003dec20
MOV EDX,dword ptr [ESI]
ADD ESP,0x10
MOV ECX,dword ptr [EDX + -0xc]
ADD ECX,ESI
TEST EAX,EAX
JZ 0x003df2a0
SUB ESP,0x8
PUSH 0x0
PUSH ECX
CALL 0x003d7ed0
ADD ESP,0x10
LEA ESP,[EBP + -0xc]
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV EAX,dword ptr [ECX + 0x14]
SUB ESP,0x8
OR EAX,0x4
PUSH EAX
PUSH ECX
CALL 0x003d7ed0
ADD ESP,0x10
LEA ESP,[EBP + -0xc]
POP EBX
POP ESI
POP EDI
POP EBP
RET
(translation_unit "void FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)\n\n{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */\n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */\n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */\n  FUN_003da940(piVar1);\n                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */\n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}\n\n" (function_definition "void FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)\n\n{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */\n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */\n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */\n  FUN_003da940(piVar1);\n                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */\n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}" primitive_type (function_declarator "FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)" identifier (parameter_list "(int *param_1,undefined4 *param_2,undefined4 param_3)" ( (parameter_declaration "int *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined4 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "undefined4 param_3" type_identifier identifier) ))) (compound_statement "{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */\n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */\n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */\n  FUN_003da940(piVar1);\n                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */\n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int unaff_EDI;" primitive_type identifier ;) (expression_statement "FUN_00074f0a();" (call_expression "FUN_00074f0a()" identifier (argument_list "()" ( ))) ;) (expression_statement "piVar2 = param_1 + 0x25;" (assignment_expression "piVar2 = param_1 + 0x25" identifier = (binary_expression "param_1 + 0x25" identifier + number_literal)) ;) (expression_statement "FUN_003f2f70(piVar2);" (call_expression "FUN_003f2f70(piVar2)" identifier (argument_list "(piVar2)" ( identifier ))) ;) (expression_statement "param_1[0x41] = 0;" (assignment_expression "param_1[0x41] = 0" (subscript_expression "param_1[0x41]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "*(undefined2 *)(param_1 + 0x42) = 0;" (assignment_expression "*(undefined2 *)(param_1 + 0x42) = 0" (pointer_expression "*(undefined2 *)(param_1 + 0x42)" * (cast_expression "(undefined2 *)(param_1 + 0x42)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x42)" ( (binary_expression "param_1 + 0x42" identifier + number_literal) )))) = number_literal) ;) (expression_statement "param_1[0x43] = 0;" (assignment_expression "param_1[0x43] = 0" (subscript_expression "param_1[0x43]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[0x44] = 0;" (assignment_expression "param_1[0x44] = 0" (subscript_expression "param_1[0x44]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[0x45] = 0;" (assignment_expression "param_1[0x45] = 0" (subscript_expression "param_1[0x45]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[0x46] = 0;" (assignment_expression "param_1[0x46] = 0" (subscript_expression "param_1[0x46]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "*param_1 = unaff_EDI + 0x2087f3;" (assignment_expression "*param_1 = unaff_EDI + 0x2087f3" (pointer_expression "*param_1" * identifier) = (binary_expression "unaff_EDI + 0x2087f3" identifier + number_literal)) ;) (expression_statement "param_1[0x25] = unaff_EDI + 0x208807;" (assignment_expression "param_1[0x25] = unaff_EDI + 0x208807" (subscript_expression "param_1[0x25]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x208807" identifier + number_literal)) ;) (expression_statement "param_1[1] = 0;" (assignment_expression "param_1[1] = 0" (subscript_expression "param_1[1]" identifier [ number_literal ]) = number_literal) ;) comment (expression_statement "FUN_003d8720(piVar2,0);" (call_expression "FUN_003d8720(piVar2,0)" identifier (argument_list "(piVar2,0)" ( identifier , number_literal ))) ;) (expression_statement "param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);" (assignment_expression "param_1[0x25] = (int)(&UNK_002087df + unaff_EDI)" (subscript_expression "param_1[0x25]" identifier [ number_literal ]) = (cast_expression "(int)(&UNK_002087df + unaff_EDI)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(&UNK_002087df + unaff_EDI)" ( (binary_expression "&UNK_002087df + unaff_EDI" (pointer_expression "&UNK_002087df" & identifier) + identifier) )))) ;) (expression_statement "param_1[2] = unaff_EDI + 0x2087cb;" (assignment_expression "param_1[2] = unaff_EDI + 0x2087cb" (subscript_expression "param_1[2]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x2087cb" identifier + number_literal)) ;) comment (expression_statement "FUN_003d8720(piVar2,0);" (call_expression "FUN_003d8720(piVar2,0)" identifier (argument_list "(piVar2,0)" ( identifier , number_literal ))) ;) (expression_statement "piVar1 = param_1 + 3;" (assignment_expression "piVar1 = param_1 + 3" identifier = (binary_expression "param_1 + 3" identifier + number_literal)) ;) (expression_statement "*param_1 = unaff_EDI + 0x20887f;" (assignment_expression "*param_1 = unaff_EDI + 0x20887f" (pointer_expression "*param_1" * identifier) = (binary_expression "unaff_EDI + 0x20887f" identifier + number_literal)) ;) (expression_statement "param_1[0x25] = unaff_EDI + 0x2088a7;" (assignment_expression "param_1[0x25] = unaff_EDI + 0x2088a7" (subscript_expression "param_1[0x25]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x2088a7" identifier + number_literal)) ;) (expression_statement "param_1[2] = unaff_EDI + 0x208893;" (assignment_expression "param_1[2] = unaff_EDI + 0x208893" (subscript_expression "param_1[2]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x208893" identifier + number_literal)) ;) comment (expression_statement "FUN_003da940(piVar1);" (call_expression "FUN_003da940(piVar1)" identifier (argument_list "(piVar1)" ( identifier ))) ;) comment (expression_statement "FUN_003d8720(piVar2,piVar1);" (call_expression "FUN_003d8720(piVar2,piVar1)" identifier (argument_list "(piVar2,piVar1)" ( identifier , identifier ))) ;) (expression_statement "iVar3 = FUN_003dec20(piVar1,*param_2,param_3);" (assignment_expression "iVar3 = FUN_003dec20(piVar1,*param_2,param_3)" identifier = (call_expression "FUN_003dec20(piVar1,*param_2,param_3)" identifier (argument_list "(piVar1,*param_2,param_3)" ( identifier , (pointer_expression "*param_2" * identifier) , identifier )))) ;) (expression_statement "iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;" (assignment_expression "iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1" identifier = (binary_expression "*(int *)(*param_1 + -0xc) + (int)param_1" (pointer_expression "*(int *)(*param_1 + -0xc)" * (cast_expression "(int *)(*param_1 + -0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_1 + -0xc)" ( (binary_expression "*param_1 + -0xc" (pointer_expression "*param_1" * identifier) + number_literal) )))) + (cast_expression "(int)param_1" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (if_statement "if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }" if (parenthesized_expression "(iVar3 != 0)" ( (binary_expression "iVar3 != 0" identifier != number_literal) )) (compound_statement "{\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }" { (expression_statement "FUN_003d7ed0(iVar4,0);" (call_expression "FUN_003d7ed0(iVar4,0)" identifier (argument_list "(iVar4,0)" ( identifier , number_literal ))) ;) (return_statement "return;" return ;) })) (expression_statement "FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);" (call_expression "FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4)" identifier (argument_list "(iVar4,*(uint *)(iVar4 + 0x14) | 4)" ( identifier , (binary_expression "*(uint *)(iVar4 + 0x14) | 4" (pointer_expression "*(uint *)(iVar4 + 0x14)" * (cast_expression "(uint *)(iVar4 + 0x14)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) | number_literal) ))) ;) (return_statement "return;" return ;) })))
(translation_unit "/* std::fstream::fstream(std::string const&, std::_Ios_Openmode) */\n\nvoid __thiscall std::fstream::fstream(fstream *this,string *param_1,_Ios_Openmode param_2)\n\n{\n  ios_base *this_00;\n  int iVar1;\n  int unaff_EDI;\n  \n  __x86_get_pc_thunk_di();\n  this_00 = (ios_base *)(this + 0x94);\n  ios_base::ios_base(this_00);\n  *(undefined4 *)(this + 0x104) = 0;\n  *(undefined2 *)(this + 0x108) = 0;\n  *(undefined4 *)(this + 0x10c) = 0;\n  *(undefined4 *)(this + 0x110) = 0;\n  *(undefined4 *)(this + 0x114) = 0;\n  *(undefined4 *)(this + 0x118) = 0;\n  *(undefined **)this = &UNK_002087f3 + unaff_EDI;\n  *(undefined **)(this + 0x94) = &UNK_00208807 + unaff_EDI;\n  *(undefined4 *)(this + 4) = 0;\n                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */\n  ios::init((streambuf *)this_00);\n  *(undefined **)(this + 0x94) = &UNK_002087df + unaff_EDI;\n  *(undefined **)(this + 8) = &UNK_002087cb + unaff_EDI;\n                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */\n  ios::init((streambuf *)this_00);\n  *(undefined **)this = &UNK_0020887f + unaff_EDI;\n  *(undefined **)(this + 0x94) = &UNK_002088a7 + unaff_EDI;\n  *(undefined **)(this + 8) = &UNK_00208893 + unaff_EDI;\n                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */\n  filebuf::filebuf((filebuf *)(this + 0xc));\n                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */\n  ios::init((streambuf *)this_00);\n  iVar1 = filebuf::open((char *)(this + 0xc),*(_Ios_Openmode *)param_1);\n  if (iVar1 != 0) {\n    ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n    return;\n  }\n  ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n  return;\n}\n\n" comment (function_definition "void __thiscall std::fstream::fstream(fstream *this,string *param_1,_Ios_Openmode param_2)\n\n{\n  ios_base *this_00;\n  int iVar1;\n  int unaff_EDI;\n  \n  __x86_get_pc_thunk_di();\n  this_00 = (ios_base *)(this + 0x94);\n  ios_base::ios_base(this_00);\n  *(undefined4 *)(this + 0x104) = 0;\n  *(undefined2 *)(this + 0x108) = 0;\n  *(undefined4 *)(this + 0x10c) = 0;\n  *(undefined4 *)(this + 0x110) = 0;\n  *(undefined4 *)(this + 0x114) = 0;\n  *(undefined4 *)(this + 0x118) = 0;\n  *(undefined **)this = &UNK_002087f3 + unaff_EDI;\n  *(undefined **)(this + 0x94) = &UNK_00208807 + unaff_EDI;\n  *(undefined4 *)(this + 4) = 0;\n                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */\n  ios::init((streambuf *)this_00);\n  *(undefined **)(this + 0x94) = &UNK_002087df + unaff_EDI;\n  *(undefined **)(this + 8) = &UNK_002087cb + unaff_EDI;\n                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */\n  ios::init((streambuf *)this_00);\n  *(undefined **)this = &UNK_0020887f + unaff_EDI;\n  *(undefined **)(this + 0x94) = &UNK_002088a7 + unaff_EDI;\n  *(undefined **)(this + 8) = &UNK_00208893 + unaff_EDI;\n                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */\n  filebuf::filebuf((filebuf *)(this + 0xc));\n                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */\n  ios::init((streambuf *)this_00);\n  iVar1 = filebuf::open((char *)(this + 0xc),*(_Ios_Openmode *)param_1);\n  if (iVar1 != 0) {\n    ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n    return;\n  }\n  ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n  return;\n}" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::fstream::" identifier : : identifier : :) (function_declarator "fstream(fstream *this,string *param_1,_Ios_Openmode param_2)" identifier (parameter_list "(fstream *this,string *param_1,_Ios_Openmode param_2)" ( (parameter_declaration "fstream *this" type_identifier (pointer_declarator "*this" * identifier)) , (parameter_declaration "string *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "_Ios_Openmode param_2" type_identifier identifier) ))) (compound_statement "{\n  ios_base *this_00;\n  int iVar1;\n  int unaff_EDI;\n  \n  __x86_get_pc_thunk_di();\n  this_00 = (ios_base *)(this + 0x94);\n  ios_base::ios_base(this_00);\n  *(undefined4 *)(this + 0x104) = 0;\n  *(undefined2 *)(this + 0x108) = 0;\n  *(undefined4 *)(this + 0x10c) = 0;\n  *(undefined4 *)(this + 0x110) = 0;\n  *(undefined4 *)(this + 0x114) = 0;\n  *(undefined4 *)(this + 0x118) = 0;\n  *(undefined **)this = &UNK_002087f3 + unaff_EDI;\n  *(undefined **)(this + 0x94) = &UNK_00208807 + unaff_EDI;\n  *(undefined4 *)(this + 4) = 0;\n                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */\n  ios::init((streambuf *)this_00);\n  *(undefined **)(this + 0x94) = &UNK_002087df + unaff_EDI;\n  *(undefined **)(this + 8) = &UNK_002087cb + unaff_EDI;\n                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */\n  ios::init((streambuf *)this_00);\n  *(undefined **)this = &UNK_0020887f + unaff_EDI;\n  *(undefined **)(this + 0x94) = &UNK_002088a7 + unaff_EDI;\n  *(undefined **)(this + 8) = &UNK_00208893 + unaff_EDI;\n                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */\n  filebuf::filebuf((filebuf *)(this + 0xc));\n                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */\n  ios::init((streambuf *)this_00);\n  iVar1 = filebuf::open((char *)(this + 0xc),*(_Ios_Openmode *)param_1);\n  if (iVar1 != 0) {\n    ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n    return;\n  }\n  ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n  return;\n}" { (declaration "ios_base *this_00;" type_identifier (pointer_declarator "*this_00" * identifier) ;) (declaration "int iVar1;" primitive_type identifier ;) (declaration "int unaff_EDI;" primitive_type identifier ;) (expression_statement "__x86_get_pc_thunk_di();" (call_expression "__x86_get_pc_thunk_di()" identifier (argument_list "()" ( ))) ;) (expression_statement "this_00 = (ios_base *)(this + 0x94);" (assignment_expression "this_00 = (ios_base *)(this + 0x94)" identifier = (cast_expression "(ios_base *)(this + 0x94)" ( (type_descriptor "ios_base *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x94)" ( (binary_expression "this + 0x94" identifier + number_literal) )))) ;) (labeled_statement "ios_base::ios_base(this_00);" statement_identifier : (ERROR ":" :) (expression_statement "ios_base(this_00);" (call_expression "ios_base(this_00)" identifier (argument_list "(this_00)" ( identifier ))) ;)) (expression_statement "*(undefined4 *)(this + 0x104) = 0;" (assignment_expression "*(undefined4 *)(this + 0x104) = 0" (pointer_expression "*(undefined4 *)(this + 0x104)" * (cast_expression "(undefined4 *)(this + 0x104)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x104)" ( (binary_expression "this + 0x104" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined2 *)(this + 0x108) = 0;" (assignment_expression "*(undefined2 *)(this + 0x108) = 0" (pointer_expression "*(undefined2 *)(this + 0x108)" * (cast_expression "(undefined2 *)(this + 0x108)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x108)" ( (binary_expression "this + 0x108" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined4 *)(this + 0x10c) = 0;" (assignment_expression "*(undefined4 *)(this + 0x10c) = 0" (pointer_expression "*(undefined4 *)(this + 0x10c)" * (cast_expression "(undefined4 *)(this + 0x10c)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x10c)" ( (binary_expression "this + 0x10c" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined4 *)(this + 0x110) = 0;" (assignment_expression "*(undefined4 *)(this + 0x110) = 0" (pointer_expression "*(undefined4 *)(this + 0x110)" * (cast_expression "(undefined4 *)(this + 0x110)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x110)" ( (binary_expression "this + 0x110" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined4 *)(this + 0x114) = 0;" (assignment_expression "*(undefined4 *)(this + 0x114) = 0" (pointer_expression "*(undefined4 *)(this + 0x114)" * (cast_expression "(undefined4 *)(this + 0x114)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x114)" ( (binary_expression "this + 0x114" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined4 *)(this + 0x118) = 0;" (assignment_expression "*(undefined4 *)(this + 0x118) = 0" (pointer_expression "*(undefined4 *)(this + 0x118)" * (cast_expression "(undefined4 *)(this + 0x118)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0x118)" ( (binary_expression "this + 0x118" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined **)this = &UNK_002087f3 + unaff_EDI;" (assignment_expression "*(undefined **)this = &UNK_002087f3 + unaff_EDI" (pointer_expression "*(undefined **)this" * (cast_expression "(undefined **)this" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "&UNK_002087f3 + unaff_EDI" (pointer_expression "&UNK_002087f3" & identifier) + identifier)) ;) (expression_statement "*(undefined **)(this + 0x94) = &UNK_00208807 + unaff_EDI;" (assignment_expression "*(undefined **)(this + 0x94) = &UNK_00208807 + unaff_EDI" (pointer_expression "*(undefined **)(this + 0x94)" * (cast_expression "(undefined **)(this + 0x94)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(this + 0x94)" ( (binary_expression "this + 0x94" identifier + number_literal) )))) = (binary_expression "&UNK_00208807 + unaff_EDI" (pointer_expression "&UNK_00208807" & identifier) + identifier)) ;) (expression_statement "*(undefined4 *)(this + 4) = 0;" (assignment_expression "*(undefined4 *)(this + 4) = 0" (pointer_expression "*(undefined4 *)(this + 4)" * (cast_expression "(undefined4 *)(this + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 4)" ( (binary_expression "this + 4" identifier + number_literal) )))) = number_literal) ;) comment (labeled_statement "ios::init((streambuf *)this_00);" statement_identifier : (ERROR ":" :) (expression_statement "init((streambuf *)this_00);" (call_expression "init((streambuf *)this_00)" identifier (argument_list "((streambuf *)this_00)" ( (cast_expression "(streambuf *)this_00" ( (type_descriptor "streambuf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) ))) ;)) (expression_statement "*(undefined **)(this + 0x94) = &UNK_002087df + unaff_EDI;" (assignment_expression "*(undefined **)(this + 0x94) = &UNK_002087df + unaff_EDI" (pointer_expression "*(undefined **)(this + 0x94)" * (cast_expression "(undefined **)(this + 0x94)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(this + 0x94)" ( (binary_expression "this + 0x94" identifier + number_literal) )))) = (binary_expression "&UNK_002087df + unaff_EDI" (pointer_expression "&UNK_002087df" & identifier) + identifier)) ;) (expression_statement "*(undefined **)(this + 8) = &UNK_002087cb + unaff_EDI;" (assignment_expression "*(undefined **)(this + 8) = &UNK_002087cb + unaff_EDI" (pointer_expression "*(undefined **)(this + 8)" * (cast_expression "(undefined **)(this + 8)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) )))) = (binary_expression "&UNK_002087cb + unaff_EDI" (pointer_expression "&UNK_002087cb" & identifier) + identifier)) ;) comment (labeled_statement "ios::init((streambuf *)this_00);" statement_identifier : (ERROR ":" :) (expression_statement "init((streambuf *)this_00);" (call_expression "init((streambuf *)this_00)" identifier (argument_list "((streambuf *)this_00)" ( (cast_expression "(streambuf *)this_00" ( (type_descriptor "streambuf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) ))) ;)) (expression_statement "*(undefined **)this = &UNK_0020887f + unaff_EDI;" (assignment_expression "*(undefined **)this = &UNK_0020887f + unaff_EDI" (pointer_expression "*(undefined **)this" * (cast_expression "(undefined **)this" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) identifier)) = (binary_expression "&UNK_0020887f + unaff_EDI" (pointer_expression "&UNK_0020887f" & identifier) + identifier)) ;) (expression_statement "*(undefined **)(this + 0x94) = &UNK_002088a7 + unaff_EDI;" (assignment_expression "*(undefined **)(this + 0x94) = &UNK_002088a7 + unaff_EDI" (pointer_expression "*(undefined **)(this + 0x94)" * (cast_expression "(undefined **)(this + 0x94)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(this + 0x94)" ( (binary_expression "this + 0x94" identifier + number_literal) )))) = (binary_expression "&UNK_002088a7 + unaff_EDI" (pointer_expression "&UNK_002088a7" & identifier) + identifier)) ;) (expression_statement "*(undefined **)(this + 8) = &UNK_00208893 + unaff_EDI;" (assignment_expression "*(undefined **)(this + 8) = &UNK_00208893 + unaff_EDI" (pointer_expression "*(undefined **)(this + 8)" * (cast_expression "(undefined **)(this + 8)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) )))) = (binary_expression "&UNK_00208893 + unaff_EDI" (pointer_expression "&UNK_00208893" & identifier) + identifier)) ;) comment (labeled_statement "filebuf::filebuf((filebuf *)(this + 0xc));" statement_identifier : (ERROR ":" :) (expression_statement "filebuf((filebuf *)(this + 0xc));" (call_expression "filebuf((filebuf *)(this + 0xc))" identifier (argument_list "((filebuf *)(this + 0xc))" ( (cast_expression "(filebuf *)(this + 0xc)" ( (type_descriptor "filebuf *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0xc)" ( (binary_expression "this + 0xc" identifier + number_literal) ))) ))) ;)) comment (labeled_statement "ios::init((streambuf *)this_00);" statement_identifier : (ERROR ":" :) (expression_statement "init((streambuf *)this_00);" (call_expression "init((streambuf *)this_00)" identifier (argument_list "((streambuf *)this_00)" ( (cast_expression "(streambuf *)this_00" ( (type_descriptor "streambuf *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) ))) ;)) (ERROR "iVar1 = filebuf::" (assignment_expression "iVar1 = filebuf" identifier = identifier) : :) (expression_statement "open((char *)(this + 0xc),*(_Ios_Openmode *)param_1);" (call_expression "open((char *)(this + 0xc),*(_Ios_Openmode *)param_1)" identifier (argument_list "((char *)(this + 0xc),*(_Ios_Openmode *)param_1)" ( (cast_expression "(char *)(this + 0xc)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 0xc)" ( (binary_expression "this + 0xc" identifier + number_literal) ))) , (pointer_expression "*(_Ios_Openmode *)param_1" * (cast_expression "(_Ios_Openmode *)param_1" ( (type_descriptor "_Ios_Openmode *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) ))) ;) (if_statement "if (iVar1 != 0) {\n    ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n    return;\n  }" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (compound_statement "{\n    ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));\n    return;\n  }" { (labeled_statement "ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));" statement_identifier : (ERROR ":" :) (expression_statement "clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));" (call_expression "clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)))" identifier (argument_list "((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)))" ( (call_expression "(_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc))" (parenthesized_expression "(_Ios_Iostate)" ( identifier )) (argument_list "(this + *(int *)(*(int *)this + -0xc))" ( (binary_expression "this + *(int *)(*(int *)this + -0xc)" identifier + (pointer_expression "*(int *)(*(int *)this + -0xc)" * (cast_expression "(int *)(*(int *)this + -0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + -0xc)" ( (binary_expression "*(int *)this + -0xc" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + number_literal) ))))) ))) ))) ;)) (return_statement "return;" return ;) })) (labeled_statement "ios::clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));" statement_identifier : (ERROR ":" :) (expression_statement "clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)));" (call_expression "clear((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)))" identifier (argument_list "((_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc)))" ( (call_expression "(_Ios_Iostate)(this + *(int *)(*(int *)this + -0xc))" (parenthesized_expression "(_Ios_Iostate)" ( identifier )) (argument_list "(this + *(int *)(*(int *)this + -0xc))" ( (binary_expression "this + *(int *)(*(int *)this + -0xc)" identifier + (pointer_expression "*(int *)(*(int *)this + -0xc)" * (cast_expression "(int *)(*(int *)this + -0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)this + -0xc)" ( (binary_expression "*(int *)this + -0xc" (pointer_expression "*(int *)this" * (cast_expression "(int *)this" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) + number_literal) ))))) ))) ))) ;)) (return_statement "return;" return ;) })))
(translation_unit "void FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)\n\n{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    \n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    \n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    \n  FUN_003da940(piVar1);\n                    \n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}\n\n" (function_definition "void FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)\n\n{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    \n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    \n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    \n  FUN_003da940(piVar1);\n                    \n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}" primitive_type (function_declarator "FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)" identifier (parameter_list "(int *param_1,undefined4 *param_2,undefined4 param_3)" ( (parameter_declaration "int *param_1" primitive_type (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "undefined4 *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "undefined4 param_3" type_identifier identifier) ))) (compound_statement "{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    \n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    \n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    \n  FUN_003da940(piVar1);\n                    \n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int unaff_EDI;" primitive_type identifier ;) (expression_statement "FUN_00074f0a();" (call_expression "FUN_00074f0a()" identifier (argument_list "()" ( ))) ;) (expression_statement "piVar2 = param_1 + 0x25;" (assignment_expression "piVar2 = param_1 + 0x25" identifier = (binary_expression "param_1 + 0x25" identifier + number_literal)) ;) (expression_statement "FUN_003f2f70(piVar2);" (call_expression "FUN_003f2f70(piVar2)" identifier (argument_list "(piVar2)" ( identifier ))) ;) (expression_statement "param_1[0x41] = 0;" (assignment_expression "param_1[0x41] = 0" (subscript_expression "param_1[0x41]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "*(undefined2 *)(param_1 + 0x42) = 0;" (assignment_expression "*(undefined2 *)(param_1 + 0x42) = 0" (pointer_expression "*(undefined2 *)(param_1 + 0x42)" * (cast_expression "(undefined2 *)(param_1 + 0x42)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x42)" ( (binary_expression "param_1 + 0x42" identifier + number_literal) )))) = number_literal) ;) (expression_statement "param_1[0x43] = 0;" (assignment_expression "param_1[0x43] = 0" (subscript_expression "param_1[0x43]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[0x44] = 0;" (assignment_expression "param_1[0x44] = 0" (subscript_expression "param_1[0x44]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[0x45] = 0;" (assignment_expression "param_1[0x45] = 0" (subscript_expression "param_1[0x45]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[0x46] = 0;" (assignment_expression "param_1[0x46] = 0" (subscript_expression "param_1[0x46]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "*param_1 = unaff_EDI + 0x2087f3;" (assignment_expression "*param_1 = unaff_EDI + 0x2087f3" (pointer_expression "*param_1" * identifier) = (binary_expression "unaff_EDI + 0x2087f3" identifier + number_literal)) ;) (expression_statement "param_1[0x25] = unaff_EDI + 0x208807;" (assignment_expression "param_1[0x25] = unaff_EDI + 0x208807" (subscript_expression "param_1[0x25]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x208807" identifier + number_literal)) ;) (expression_statement "param_1[1] = 0;" (assignment_expression "param_1[1] = 0" (subscript_expression "param_1[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "FUN_003d8720(piVar2,0);" (call_expression "FUN_003d8720(piVar2,0)" identifier (argument_list "(piVar2,0)" ( identifier , number_literal ))) ;) (expression_statement "param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);" (assignment_expression "param_1[0x25] = (int)(&UNK_002087df + unaff_EDI)" (subscript_expression "param_1[0x25]" identifier [ number_literal ]) = (cast_expression "(int)(&UNK_002087df + unaff_EDI)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(&UNK_002087df + unaff_EDI)" ( (binary_expression "&UNK_002087df + unaff_EDI" (pointer_expression "&UNK_002087df" & identifier) + identifier) )))) ;) (expression_statement "param_1[2] = unaff_EDI + 0x2087cb;" (assignment_expression "param_1[2] = unaff_EDI + 0x2087cb" (subscript_expression "param_1[2]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x2087cb" identifier + number_literal)) ;) (expression_statement "FUN_003d8720(piVar2,0);" (call_expression "FUN_003d8720(piVar2,0)" identifier (argument_list "(piVar2,0)" ( identifier , number_literal ))) ;) (expression_statement "piVar1 = param_1 + 3;" (assignment_expression "piVar1 = param_1 + 3" identifier = (binary_expression "param_1 + 3" identifier + number_literal)) ;) (expression_statement "*param_1 = unaff_EDI + 0x20887f;" (assignment_expression "*param_1 = unaff_EDI + 0x20887f" (pointer_expression "*param_1" * identifier) = (binary_expression "unaff_EDI + 0x20887f" identifier + number_literal)) ;) (expression_statement "param_1[0x25] = unaff_EDI + 0x2088a7;" (assignment_expression "param_1[0x25] = unaff_EDI + 0x2088a7" (subscript_expression "param_1[0x25]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x2088a7" identifier + number_literal)) ;) (expression_statement "param_1[2] = unaff_EDI + 0x208893;" (assignment_expression "param_1[2] = unaff_EDI + 0x208893" (subscript_expression "param_1[2]" identifier [ number_literal ]) = (binary_expression "unaff_EDI + 0x208893" identifier + number_literal)) ;) (expression_statement "FUN_003da940(piVar1);" (call_expression "FUN_003da940(piVar1)" identifier (argument_list "(piVar1)" ( identifier ))) ;) (expression_statement "FUN_003d8720(piVar2,piVar1);" (call_expression "FUN_003d8720(piVar2,piVar1)" identifier (argument_list "(piVar2,piVar1)" ( identifier , identifier ))) ;) (expression_statement "iVar3 = FUN_003dec20(piVar1,*param_2,param_3);" (assignment_expression "iVar3 = FUN_003dec20(piVar1,*param_2,param_3)" identifier = (call_expression "FUN_003dec20(piVar1,*param_2,param_3)" identifier (argument_list "(piVar1,*param_2,param_3)" ( identifier , (pointer_expression "*param_2" * identifier) , identifier )))) ;) (expression_statement "iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;" (assignment_expression "iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1" identifier = (binary_expression "*(int *)(*param_1 + -0xc) + (int)param_1" (pointer_expression "*(int *)(*param_1 + -0xc)" * (cast_expression "(int *)(*param_1 + -0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_1 + -0xc)" ( (binary_expression "*param_1 + -0xc" (pointer_expression "*param_1" * identifier) + number_literal) )))) + (cast_expression "(int)param_1" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (if_statement "if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }" if (parenthesized_expression "(iVar3 != 0)" ( (binary_expression "iVar3 != 0" identifier != number_literal) )) (compound_statement "{\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }" { (expression_statement "FUN_003d7ed0(iVar4,0);" (call_expression "FUN_003d7ed0(iVar4,0)" identifier (argument_list "(iVar4,0)" ( identifier , number_literal ))) ;) (return_statement "return;" return ;) })) (expression_statement "FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);" (call_expression "FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4)" identifier (argument_list "(iVar4,*(uint *)(iVar4 + 0x14) | 4)" ( identifier , (binary_expression "*(uint *)(iVar4 + 0x14) | 4" (pointer_expression "*(uint *)(iVar4 + 0x14)" * (cast_expression "(uint *)(iVar4 + 0x14)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) | number_literal) ))) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (call_expression IDENT (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (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) = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT ))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression (pointer_expression & IDENT) + IDENT) )))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression IDENT + LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT ))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression IDENT + LIT)) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * IDENT) , IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) + LIT) )))) + (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT ))) ;) (return_statement return ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) | LIT) ))) ;) (return_statement return ;) })))
(function_definition "void FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)\n\n{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    \n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    \n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    \n  FUN_003da940(piVar1);\n                    \n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}" (primitive_type "void") (function_declarator "FUN_003df180(int *param_1,undefined4 *param_2,undefined4 param_3)" (identifier "FUN_003df180") (parameter_list "(int *param_1,undefined4 *param_2,undefined4 param_3)" (( "(") (parameter_declaration "int *param_1" (primitive_type "int") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "undefined4 *param_2" (type_identifier "undefined4") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "undefined4 param_3" (type_identifier "undefined4") (identifier "param_3")) () ")"))) (compound_statement "{\n  int *piVar1;\n  int *piVar2;\n  int iVar3;\n  int iVar4;\n  int unaff_EDI;\n  \n  FUN_00074f0a();\n  piVar2 = param_1 + 0x25;\n  FUN_003f2f70(piVar2);\n  param_1[0x41] = 0;\n  *(undefined2 *)(param_1 + 0x42) = 0;\n  param_1[0x43] = 0;\n  param_1[0x44] = 0;\n  param_1[0x45] = 0;\n  param_1[0x46] = 0;\n  *param_1 = unaff_EDI + 0x2087f3;\n  param_1[0x25] = unaff_EDI + 0x208807;\n  param_1[1] = 0;\n                    \n  FUN_003d8720(piVar2,0);\n  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);\n  param_1[2] = unaff_EDI + 0x2087cb;\n                    \n  FUN_003d8720(piVar2,0);\n  piVar1 = param_1 + 3;\n  *param_1 = unaff_EDI + 0x20887f;\n  param_1[0x25] = unaff_EDI + 0x2088a7;\n  param_1[2] = unaff_EDI + 0x208893;\n                    \n  FUN_003da940(piVar1);\n                    \n  FUN_003d8720(piVar2,piVar1);\n  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);\n  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;\n  if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }\n  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);\n  return;\n}" ({ "{") (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "int *piVar2;" (primitive_type "int") (pointer_declarator "*piVar2" (* "*") (identifier "piVar2")) (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "int unaff_EDI;" (primitive_type "int") (identifier "unaff_EDI") (; ";")) (expression_statement "FUN_00074f0a();" (call_expression "FUN_00074f0a()" (identifier "FUN_00074f0a") (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "piVar2 = param_1 + 0x25;" (assignment_expression "piVar2 = param_1 + 0x25" (identifier "piVar2") (= "=") (binary_expression "param_1 + 0x25" (identifier "param_1") (+ "+") (number_literal "0x25"))) (; ";")) (expression_statement "FUN_003f2f70(piVar2);" (call_expression "FUN_003f2f70(piVar2)" (identifier "FUN_003f2f70") (argument_list "(piVar2)" (( "(") (identifier "piVar2") () ")"))) (; ";")) (expression_statement "param_1[0x41] = 0;" (assignment_expression "param_1[0x41] = 0" (subscript_expression "param_1[0x41]" (identifier "param_1") ([ "[") (number_literal "0x41") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "*(undefined2 *)(param_1 + 0x42) = 0;" (assignment_expression "*(undefined2 *)(param_1 + 0x42) = 0" (pointer_expression "*(undefined2 *)(param_1 + 0x42)" (* "*") (cast_expression "(undefined2 *)(param_1 + 0x42)" (( "(") (type_descriptor "undefined2 *" (type_identifier "undefined2") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x42)" (( "(") (binary_expression "param_1 + 0x42" (identifier "param_1") (+ "+") (number_literal "0x42")) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_1[0x43] = 0;" (assignment_expression "param_1[0x43] = 0" (subscript_expression "param_1[0x43]" (identifier "param_1") ([ "[") (number_literal "0x43") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_1[0x44] = 0;" (assignment_expression "param_1[0x44] = 0" (subscript_expression "param_1[0x44]" (identifier "param_1") ([ "[") (number_literal "0x44") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_1[0x45] = 0;" (assignment_expression "param_1[0x45] = 0" (subscript_expression "param_1[0x45]" (identifier "param_1") ([ "[") (number_literal "0x45") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_1[0x46] = 0;" (assignment_expression "param_1[0x46] = 0" (subscript_expression "param_1[0x46]" (identifier "param_1") ([ "[") (number_literal "0x46") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "*param_1 = unaff_EDI + 0x2087f3;" (assignment_expression "*param_1 = unaff_EDI + 0x2087f3" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (binary_expression "unaff_EDI + 0x2087f3" (identifier "unaff_EDI") (+ "+") (number_literal "0x2087f3"))) (; ";")) (expression_statement "param_1[0x25] = unaff_EDI + 0x208807;" (assignment_expression "param_1[0x25] = unaff_EDI + 0x208807" (subscript_expression "param_1[0x25]" (identifier "param_1") ([ "[") (number_literal "0x25") (] "]")) (= "=") (binary_expression "unaff_EDI + 0x208807" (identifier "unaff_EDI") (+ "+") (number_literal "0x208807"))) (; ";")) (expression_statement "param_1[1] = 0;" (assignment_expression "param_1[1] = 0" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "FUN_003d8720(piVar2,0);" (call_expression "FUN_003d8720(piVar2,0)" (identifier "FUN_003d8720") (argument_list "(piVar2,0)" (( "(") (identifier "piVar2") (, ",") (number_literal "0") () ")"))) (; ";")) (expression_statement "param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);" (assignment_expression "param_1[0x25] = (int)(&UNK_002087df + unaff_EDI)" (subscript_expression "param_1[0x25]" (identifier "param_1") ([ "[") (number_literal "0x25") (] "]")) (= "=") (cast_expression "(int)(&UNK_002087df + unaff_EDI)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(&UNK_002087df + unaff_EDI)" (( "(") (binary_expression "&UNK_002087df + unaff_EDI" (pointer_expression "&UNK_002087df" (& "&") (identifier "UNK_002087df")) (+ "+") (identifier "unaff_EDI")) () ")")))) (; ";")) (expression_statement "param_1[2] = unaff_EDI + 0x2087cb;" (assignment_expression "param_1[2] = unaff_EDI + 0x2087cb" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (= "=") (binary_expression "unaff_EDI + 0x2087cb" (identifier "unaff_EDI") (+ "+") (number_literal "0x2087cb"))) (; ";")) (expression_statement "FUN_003d8720(piVar2,0);" (call_expression "FUN_003d8720(piVar2,0)" (identifier "FUN_003d8720") (argument_list "(piVar2,0)" (( "(") (identifier "piVar2") (, ",") (number_literal "0") () ")"))) (; ";")) (expression_statement "piVar1 = param_1 + 3;" (assignment_expression "piVar1 = param_1 + 3" (identifier "piVar1") (= "=") (binary_expression "param_1 + 3" (identifier "param_1") (+ "+") (number_literal "3"))) (; ";")) (expression_statement "*param_1 = unaff_EDI + 0x20887f;" (assignment_expression "*param_1 = unaff_EDI + 0x20887f" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (binary_expression "unaff_EDI + 0x20887f" (identifier "unaff_EDI") (+ "+") (number_literal "0x20887f"))) (; ";")) (expression_statement "param_1[0x25] = unaff_EDI + 0x2088a7;" (assignment_expression "param_1[0x25] = unaff_EDI + 0x2088a7" (subscript_expression "param_1[0x25]" (identifier "param_1") ([ "[") (number_literal "0x25") (] "]")) (= "=") (binary_expression "unaff_EDI + 0x2088a7" (identifier "unaff_EDI") (+ "+") (number_literal "0x2088a7"))) (; ";")) (expression_statement "param_1[2] = unaff_EDI + 0x208893;" (assignment_expression "param_1[2] = unaff_EDI + 0x208893" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (= "=") (binary_expression "unaff_EDI + 0x208893" (identifier "unaff_EDI") (+ "+") (number_literal "0x208893"))) (; ";")) (expression_statement "FUN_003da940(piVar1);" (call_expression "FUN_003da940(piVar1)" (identifier "FUN_003da940") (argument_list "(piVar1)" (( "(") (identifier "piVar1") () ")"))) (; ";")) (expression_statement "FUN_003d8720(piVar2,piVar1);" (call_expression "FUN_003d8720(piVar2,piVar1)" (identifier "FUN_003d8720") (argument_list "(piVar2,piVar1)" (( "(") (identifier "piVar2") (, ",") (identifier "piVar1") () ")"))) (; ";")) (expression_statement "iVar3 = FUN_003dec20(piVar1,*param_2,param_3);" (assignment_expression "iVar3 = FUN_003dec20(piVar1,*param_2,param_3)" (identifier "iVar3") (= "=") (call_expression "FUN_003dec20(piVar1,*param_2,param_3)" (identifier "FUN_003dec20") (argument_list "(piVar1,*param_2,param_3)" (( "(") (identifier "piVar1") (, ",") (pointer_expression "*param_2" (* "*") (identifier "param_2")) (, ",") (identifier "param_3") () ")")))) (; ";")) (expression_statement "iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;" (assignment_expression "iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1" (identifier "iVar4") (= "=") (binary_expression "*(int *)(*param_1 + -0xc) + (int)param_1" (pointer_expression "*(int *)(*param_1 + -0xc)" (* "*") (cast_expression "(int *)(*param_1 + -0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*param_1 + -0xc)" (( "(") (binary_expression "*param_1 + -0xc" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (+ "+") (number_literal "-0xc")) () ")")))) (+ "+") (cast_expression "(int)param_1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_1")))) (; ";")) (if_statement "if (iVar3 != 0) {\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }" (if "if") (parenthesized_expression "(iVar3 != 0)" (( "(") (binary_expression "iVar3 != 0" (identifier "iVar3") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    FUN_003d7ed0(iVar4,0);\n    return;\n  }" ({ "{") (expression_statement "FUN_003d7ed0(iVar4,0);" (call_expression "FUN_003d7ed0(iVar4,0)" (identifier "FUN_003d7ed0") (argument_list "(iVar4,0)" (( "(") (identifier "iVar4") (, ",") (number_literal "0") () ")"))) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);" (call_expression "FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4)" (identifier "FUN_003d7ed0") (argument_list "(iVar4,*(uint *)(iVar4 + 0x14) | 4)" (( "(") (identifier "iVar4") (, ",") (binary_expression "*(uint *)(iVar4 + 0x14) | 4" (pointer_expression "*(uint *)(iVar4 + 0x14)" (* "*") (cast_expression "(uint *)(iVar4 + 0x14)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x14)" (( "(") (binary_expression "iVar4 + 0x14" (identifier "iVar4") (+ "+") (number_literal "0x14")) () ")")))) (| "|") (number_literal "4")) () ")"))) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

/* std::fstream::fstream(std::string const&, std::_Ios_Openmode) */

void __thiscall std::function_1::function_1(function_1 *var_2,type_1 *param_1,type_2 param_2)

{
  type_3 *this_00;
  int var_7;
  int var_3;
  
  var_1();
  this_00 = (type_3 *)(var_2 + 0x94);
  ios_base::type_3(this_00);
  *(type_4 *)(var_2 + 0x104) = 0;
  *(type_5 *)(var_2 + 0x108) = 0;
  *(type_4 *)(var_2 + 0x10c) = 0;
  *(type_4 *)(var_2 + 0x110) = 0;
  *(type_4 *)(var_2 + 0x114) = 0;
  *(type_4 *)(var_2 + 0x118) = 0;
  *(type_6 **)var_2 = &UNK_002087f3 + var_3;
  *(type_6 **)(var_2 + 0x94) = &UNK_00208807 + var_3;
  *(type_4 *)(var_2 + 4) = 0;
                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */
  ios::var_4((type_7 *)this_00);
  *(type_6 **)(var_2 + 0x94) = &UNK_002087df + var_3;
  *(type_6 **)(var_2 + 8) = &UNK_002087cb + var_3;
                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */
  ios::var_4((type_7 *)this_00);
  *(type_6 **)var_2 = &UNK_0020887f + var_3;
  *(type_6 **)(var_2 + 0x94) = &UNK_002088a7 + var_3;
  *(type_6 **)(var_2 + 8) = &UNK_00208893 + var_3;
                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */
  filebuf::var_5((var_5 *)(var_2 + 0xc));
                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */
  ios::var_4((type_7 *)this_00);
  var_7 = var_5::var_6((char *)(var_2 + 0xc),*(type_2 *)param_1);
  if (var_7 != 0) {
    ios::var_8((_Ios_Iostate)(var_2 + *(int *)(*(int *)var_2 + -0xc)));
    return;
  }
  ios::var_8((_Ios_Iostate)(var_2 + *(int *)(*(int *)var_2 + -0xc)));
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (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))))) right: (number_literal))) (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: (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: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (identifier)))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal)))) (return_statement))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (binary_expression left: (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))))) right: (number_literal))))) (return_statement))))

void MASKED(int *param_1,undefined4 *param_2,undefined4 param_3)

{
  int *piVar1;
  int *piVar2;
  int iVar3;
  int iVar4;
  int unaff_EDI;
  
  FUN_00074f0a();
  piVar2 = param_1 + 0x25;
  FUN_003f2f70(piVar2);
  param_1[0x41] = 0;
  *(undefined2 *)(param_1 + 0x42) = 0;
  param_1[0x43] = 0;
  param_1[0x44] = 0;
  param_1[0x45] = 0;
  param_1[0x46] = 0;
  *param_1 = unaff_EDI + 0x2087f3;
  param_1[0x25] = unaff_EDI + 0x208807;
  param_1[1] = 0;
                    /* try { // try from 003df208 to 003df20c has its CatchHandler @ 003df313 */
  FUN_003d8720(piVar2,0);
  param_1[0x25] = (int)(&UNK_002087df + unaff_EDI);
  param_1[2] = unaff_EDI + 0x2087cb;
                    /* try { // try from 003df22e to 003df232 has its CatchHandler @ 003df311 */
  FUN_003d8720(piVar2,0);
  piVar1 = param_1 + 3;
  *param_1 = unaff_EDI + 0x20887f;
  param_1[0x25] = unaff_EDI + 0x2088a7;
  param_1[2] = unaff_EDI + 0x208893;
                    /* try { // try from 003df256 to 003df25a has its CatchHandler @ 003df2bd */
  FUN_003da940(piVar1);
                    /* try { // try from 003df263 to 003df2af has its CatchHandler @ 003df2bb */
  FUN_003d8720(piVar2,piVar1);
  iVar3 = FUN_003dec20(piVar1,*param_2,param_3);
  iVar4 = *(int *)(*param_1 + -0xc) + (int)param_1;
  if (iVar3 != 0) {
    FUN_003d7ed0(iVar4,0);
    return;
  }
  FUN_003d7ed0(iVar4,*(uint *)(iVar4 + 0x14) | 4);
  return;
}

