
/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* std::codecvt<wchar_t, char, __mbstate_t>::do_in(__mbstate_t&, char const*, char const*, char
   const*&, wchar_t*, wchar_t*, wchar_t*&) const */

int __thiscall
std::codecvt<wchar_t,char,__mbstate_t>::do_in
          (codecvt<wchar_t,char,__mbstate_t> *this,__mbstate_t *param_1,char *param_2,char *param_3,
          char **param_4,wchar_t *param_5,wchar_t *param_6,wchar_t **param_7)

{
  wchar_t *pwVar1;
  undefined4 uVar2;
  char *pcVar3;
  size_t sVar4;
  wchar_t *pwVar5;
  int iVar6;
  char *pcVar7;
  mbstate_t local_24 [2];
  undefined4 uStack_14;
  
  iVar6 = 0;
  uStack_14 = 0x27b1bb;
  local_24[0].__value = param_1->__value;
  local_24[0].__count = param_1->__count;
  uVar2 = __uselocale(*(undefined4 *)(this + 8));
  *param_4 = param_2;
  *param_7 = param_5;
joined_r0x0027b200:
  do {
    if (((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)) {
LAB_0027b295:
      __uselocale(uVar2);
      return iVar6;
    }
    while( true ) {
      sVar4 = (int)param_3 - (int)param_2;
      pcVar3 = (char *)memchr(param_2,0,sVar4);
      pcVar7 = param_3;
      if (pcVar3 != (char *)0x0) {
        sVar4 = (int)pcVar3 - (int)param_2;
        pcVar7 = pcVar3;
      }
      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);
      if (sVar4 == 0xffffffff) break;
      param_2 = *param_4;
      pwVar1 = *param_7 + sVar4;
      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {
        *param_7 = pwVar1;
        iVar6 = 1;
        goto joined_r0x0027b200;
      }
      *param_4 = pcVar7;
      *param_7 = pwVar1;
      if (param_3 <= pcVar7) goto LAB_0027b318;
      if (param_6 <= pwVar1) {
        iVar6 = 1;
        goto LAB_0027b295;
      }
      param_2 = pcVar7 + 1;
      local_24[0].__count = param_1->__count;
      local_24[0].__value = param_1->__value;
      pwVar5 = pwVar1 + 1;
      *param_4 = param_2;
      *param_7 = pwVar5;
      *pwVar1 = L'\0';
      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {
        iVar6 = 0;
        goto LAB_0027b295;
      }
    }
    pwVar5 = *param_7;
    while (sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2) {
      param_2 = param_2 + sVar4;
      pwVar5 = *param_7 + 1;
      *param_7 = pwVar5;
    }
    iVar6 = 2;
    *param_4 = param_2;
    param_1->__value = local_24[0].__value;
    param_1->__count = local_24[0].__count;
    param_2 = *param_4;
  } while( true );
LAB_0027b318:
  iVar6 = 0;
  param_2 = pcVar7;
  goto joined_r0x0027b200;
}



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

int FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,
                int param_6,wchar_t *param_7,int *param_8)

{
  wchar_t *pwVar1;
  undefined4 uVar2;
  char *pcVar3;
  size_t sVar4;
  wchar_t *pwVar5;
  int iVar6;
  char *pcVar7;
  mbstate_t local_24 [2];
  undefined4 uStack_14;
  
  iVar6 = 0;
  uStack_14 = 0x27b1bb;
  local_24[0].__value = param_2->__value;
  local_24[0].__count = param_2->__count;
  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));
  *param_5 = param_3;
  *param_8 = param_6;
joined_r0x0027b200:
  do {
    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))
    {
LAB_0027b295:
      __uselocale(uVar2);
      return iVar6;
    }
    while( true ) {
      sVar4 = (int)param_4 - (int)param_3;
      pcVar3 = (char *)memchr(param_3,0,sVar4);
      pcVar7 = param_4;
      if (pcVar3 != (char *)0x0) {
        sVar4 = (int)pcVar3 - (int)param_3;
        pcVar7 = pcVar3;
      }
      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);
      if (sVar4 == 0xffffffff) break;
      param_3 = *param_5;
      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);
      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {
        *param_8 = (int)pwVar1;
        iVar6 = 1;
        goto joined_r0x0027b200;
      }
      *param_5 = pcVar7;
      *param_8 = (int)pwVar1;
      if (param_4 <= pcVar7) goto LAB_0027b318;
      if (param_7 <= pwVar1) {
        iVar6 = 1;
        goto LAB_0027b295;
      }
      param_3 = pcVar7 + 1;
      local_24[0].__count = param_2->__count;
      local_24[0].__value = param_2->__value;
      pwVar5 = pwVar1 + 1;
      *param_5 = param_3;
      *param_8 = (int)pwVar5;
      *pwVar1 = L'\0';
      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {
        iVar6 = 0;
        goto LAB_0027b295;
      }
    }
    pwVar5 = (wchar_t *)*param_8;
    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {
      param_3 = param_3 + sVar4;
      pwVar5 = (wchar_t *)(*param_8 + 4);
      *param_8 = (int)pwVar5;
    }
    iVar6 = 2;
    *param_5 = param_3;
    param_2->__value = local_24[0].__value;
    param_2->__count = local_24[0].__count;
    param_3 = *param_5;
  } while( true );
LAB_0027b318:
  iVar6 = 0;
  param_3 = pcVar7;
  goto joined_r0x0027b200;
}


PUSH EBP
XOR EBP,EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00035840
ADD EBX,0x113e45
SUB ESP,0x38
MOV EAX,dword ptr [ESP + 0x50]
MOV ESI,dword ptr [ESP + 0x54]
MOV EDI,dword ptr [ESP + 0x68]
MOV EDX,dword ptr [EAX + 0x4]
MOV EAX,dword ptr [EAX]
MOV dword ptr [ESP + 0x24],EAX
MOV EAX,dword ptr [ESP + 0x4c]
MOV dword ptr [ESP + 0x28],EDX
PUSH dword ptr [EAX + 0x8]
CALL 0x000297d0
MOV dword ptr [ESP + 0x1c],EAX
MOV EAX,dword ptr [ESP + 0x60]
MOV dword ptr [EAX],ESI
MOV EAX,dword ptr [ESP + 0x64]
ADD ESP,0x10
MOV dword ptr [EDI],EAX
CMP dword ptr [ESP + 0x4c],ESI
JBE 0x0027b295
MOV EDX,dword ptr [EDI]
CMP EDX,dword ptr [ESP + 0x58]
JNC 0x0027b295
TEST EBP,EBP
JNZ 0x0027b295
MOV ECX,dword ptr [ESP + 0x4c]
MOV dword ptr [ESP + 0x8],EDX
SUB ESP,0x4
SUB ECX,ESI
PUSH ECX
MOV dword ptr [ESP + 0xc],ECX
PUSH 0x0
PUSH ESI
CALL 0x00029970
ADD ESP,0x10
MOV ECX,dword ptr [ESP + 0x4]
MOV EDX,dword ptr [ESP + 0x8]
TEST EAX,EAX
MOV EBP,EAX
JZ 0x0027b308
MOV ECX,EAX
SUB ECX,ESI
SUB ESP,0xc
PUSH dword ptr [ESP + 0x50]
MOV EAX,dword ptr [ESP + 0x68]
SUB EAX,EDX
SAR EAX,0x2
PUSH EAX
PUSH ECX
PUSH dword ptr [ESP + 0x68]
PUSH EDX
CALL 0x00029440
ADD ESP,0x20
CMP EAX,-0x1
JZ 0x0027b328
MOV ESI,dword ptr [ESP + 0x50]
MOV EDX,dword ptr [EDI]
MOV ESI,dword ptr [ESI]
LEA EAX,[EDX + EAX*0x4]
CMP ESI,EBP
JNC 0x0027b2b0
TEST ESI,ESI
JZ 0x0027b2b0
MOV dword ptr [EDI],EAX
MOV EBP,0x1
CMP dword ptr [ESP + 0x4c],ESI
JA 0x0027b206
SUB ESP,0xc
PUSH dword ptr [ESP + 0x18]
CALL 0x000297d0
ADD ESP,0x3c
MOV EAX,EBP
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV ESI,dword ptr [ESP + 0x50]
MOV dword ptr [ESI],EBP
MOV dword ptr [EDI],EAX
CMP EBP,dword ptr [ESP + 0x4c]
JNC 0x0027b318
CMP dword ptr [ESP + 0x58],EAX
JBE 0x0027b390
MOV ECX,dword ptr [ESP + 0x44]
LEA ESI,[EBP + 0x1]
MOV EDX,dword ptr [ECX]
MOV ECX,dword ptr [ECX + 0x4]
MOV dword ptr [ESP + 0x1c],ECX
MOV ECX,dword ptr [ESP + 0x50]
MOV dword ptr [ESP + 0x18],EDX
LEA EDX,[EAX + 0x4]
MOV dword ptr [ECX],ESI
MOV dword ptr [EDI],EDX
MOV dword ptr [EAX],0x0
CMP ESI,dword ptr [ESP + 0x4c]
JNC 0x0027b2fd
CMP EDX,dword ptr [ESP + 0x58]
JC 0x0027b216
XOR EBP,EBP
JMP 0x0027b295
MOV EBP,dword ptr [ESP + 0x4c]
JMP 0x0027b249
MOV ESI,EBP
XOR EBP,EBP
JMP 0x0027b1fc
LEA EBP,[ESP + 0x18]
MOV EDX,dword ptr [EDI]
MOV EAX,EBP
MOV EBP,EDI
MOV EDI,ESI
MOV ESI,EAX
JMP 0x0027b34b
MOV ECX,dword ptr [EBP]
ADD EDI,EAX
LEA EDX,[ECX + 0x4]
MOV dword ptr [EBP],EDX
PUSH ESI
MOV EAX,dword ptr [ESP + 0x50]
SUB EAX,EDI
PUSH EAX
PUSH EDI
PUSH EDX
CALL 0x00029390
ADD ESP,0x10
LEA EDX,[EAX + 0x2]
CMP EDX,0x1
JA 0x0027b340
MOV EAX,dword ptr [ESP + 0x50]
MOV ESI,EDI
MOV ECX,dword ptr [ESP + 0x44]
MOV EDI,EBP
MOV EDX,dword ptr [ESP + 0x1c]
MOV EBP,0x2
MOV dword ptr [EAX],ESI
MOV EAX,dword ptr [ESP + 0x18]
MOV dword ptr [ECX + 0x4],EDX
MOV dword ptr [ECX],EAX
MOV EAX,dword ptr [ESP + 0x50]
MOV ESI,dword ptr [EAX]
JMP 0x0027b1fc
MOV EBP,0x1
JMP 0x0027b295
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nint FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)\n\n{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}\n\n" comment (function_definition "int FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)\n\n{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}" primitive_type (function_declarator "FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)" identifier (parameter_list "(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "mbstate_t *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "char *param_4" primitive_type (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "char **param_5" primitive_type (pointer_declarator "**param_5" * (pointer_declarator "*param_5" * identifier))) , (parameter_declaration "int param_6" primitive_type identifier) , (parameter_declaration "wchar_t *param_7" type_identifier (pointer_declarator "*param_7" * identifier)) , (parameter_declaration "int *param_8" primitive_type (pointer_declarator "*param_8" * identifier)) ))) (compound_statement "{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}" { (declaration "wchar_t *pwVar1;" type_identifier (pointer_declarator "*pwVar1" * identifier) ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "size_t sVar4;" primitive_type identifier ;) (declaration "wchar_t *pwVar5;" type_identifier (pointer_declarator "*pwVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "char *pcVar7;" primitive_type (pointer_declarator "*pcVar7" * identifier) ;) (declaration "mbstate_t local_24 [2];" type_identifier (array_declarator "local_24 [2]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "uStack_14 = 0x27b1bb;" (assignment_expression "uStack_14 = 0x27b1bb" identifier = number_literal) ;) (expression_statement "local_24[0].__value = param_2->__value;" (assignment_expression "local_24[0].__value = param_2->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__value" identifier -> field_identifier)) ;) (expression_statement "local_24[0].__count = param_2->__count;" (assignment_expression "local_24[0].__count = param_2->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__count" identifier -> field_identifier)) ;) (expression_statement "uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));" (assignment_expression "uVar2 = __uselocale(*(undefined4 *)(param_1 + 8))" identifier = (call_expression "__uselocale(*(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 "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = param_6;" (assignment_expression "*param_8 = param_6" (pointer_expression "*param_8" * identifier) = identifier) ;) (labeled_statement "joined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );" statement_identifier : (do_statement "do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );" do (compound_statement "{\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  }" { (if_statement "if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" if (parenthesized_expression "(((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))" ( (binary_expression "((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0)" (parenthesized_expression "((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5))" ( (binary_expression "(param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)" (parenthesized_expression "(param_4 <= param_3)" ( (binary_expression "param_4 <= param_3" identifier <= identifier) )) || (parenthesized_expression "(pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)" ( (comma_expression "pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5" (assignment_expression "pwVar5 = (wchar_t *)*param_8" identifier = (cast_expression "(wchar_t *)*param_8" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_8" * identifier))) , (binary_expression "param_7 <= pwVar5" identifier <= identifier)) ))) )) || (parenthesized_expression "(iVar6 != 0)" ( (binary_expression "iVar6 != 0" identifier != number_literal) ))) )) (compound_statement "{\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" { (labeled_statement "LAB_0027b295:\n      __uselocale(uVar2);" statement_identifier : (expression_statement "__uselocale(uVar2);" (call_expression "__uselocale(uVar2)" identifier (argument_list "(uVar2)" ( identifier ))) ;)) (return_statement "return iVar6;" return identifier ;) })) (while_statement "while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" { (expression_statement "sVar4 = (int)param_4 - (int)param_3;" (assignment_expression "sVar4 = (int)param_4 - (int)param_3" identifier = (binary_expression "(int)param_4 - (int)param_3" (cast_expression "(int)param_4" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "pcVar3 = (char *)memchr(param_3,0,sVar4);" (assignment_expression "pcVar3 = (char *)memchr(param_3,0,sVar4)" identifier = (cast_expression "(char *)memchr(param_3,0,sVar4)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "memchr(param_3,0,sVar4)" identifier (argument_list "(param_3,0,sVar4)" ( identifier , number_literal , identifier ))))) ;) (expression_statement "pcVar7 = param_4;" (assignment_expression "pcVar7 = param_4" identifier = identifier) ;) (if_statement "if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }" if (parenthesized_expression "(pcVar3 != (char *)0x0)" ( (binary_expression "pcVar3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }" { (expression_statement "sVar4 = (int)pcVar3 - (int)param_3;" (assignment_expression "sVar4 = (int)pcVar3 - (int)param_3" identifier = (binary_expression "(int)pcVar3 - (int)param_3" (cast_expression "(int)pcVar3" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "pcVar7 = pcVar3;" (assignment_expression "pcVar7 = pcVar3" identifier = identifier) ;) })) (expression_statement "sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);" (assignment_expression "sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" identifier = (call_expression "mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" identifier (argument_list "(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" ( identifier , identifier , identifier , (binary_expression "(int)param_7 - (int)pwVar5 >> 2" (binary_expression "(int)param_7 - (int)pwVar5" (cast_expression "(int)param_7" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) >> number_literal) , identifier )))) ;) (if_statement "if (sVar4 == 0xffffffff) break;" if (parenthesized_expression "(sVar4 == 0xffffffff)" ( (binary_expression "sVar4 == 0xffffffff" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "param_3 = *param_5;" (assignment_expression "param_3 = *param_5" identifier = (pointer_expression "*param_5" * identifier)) ;) (expression_statement "pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);" (assignment_expression "pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4)" identifier = (cast_expression "(wchar_t *)(*param_8 + sVar4 * 4)" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_8 + sVar4 * 4)" ( (binary_expression "*param_8 + sVar4 * 4" (pointer_expression "*param_8" * identifier) + (binary_expression "sVar4 * 4" identifier * number_literal)) )))) ;) (if_statement "if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" if (parenthesized_expression "((param_3 < pcVar7) && (param_3 != (char *)0x0))" ( (binary_expression "(param_3 < pcVar7) && (param_3 != (char *)0x0)" (parenthesized_expression "(param_3 < pcVar7)" ( (binary_expression "param_3 < pcVar7" identifier < identifier) )) && (parenthesized_expression "(param_3 != (char *)0x0)" ( (binary_expression "param_3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ))) )) (compound_statement "{\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" { (expression_statement "*param_8 = (int)pwVar1;" (assignment_expression "*param_8 = (int)pwVar1" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar1" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) (goto_statement "goto joined_r0x0027b200;" goto statement_identifier ;) })) (expression_statement "*param_5 = pcVar7;" (assignment_expression "*param_5 = pcVar7" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = (int)pwVar1;" (assignment_expression "*param_8 = (int)pwVar1" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar1" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (if_statement "if (param_4 <= pcVar7) goto LAB_0027b318;" if (parenthesized_expression "(param_4 <= pcVar7)" ( (binary_expression "param_4 <= pcVar7" identifier <= identifier) )) (goto_statement "goto LAB_0027b318;" goto statement_identifier ;)) (if_statement "if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" if (parenthesized_expression "(param_7 <= pwVar1)" ( (binary_expression "param_7 <= pwVar1" identifier <= identifier) )) (compound_statement "{\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) (goto_statement "goto LAB_0027b295;" goto statement_identifier ;) })) (expression_statement "param_3 = pcVar7 + 1;" (assignment_expression "param_3 = pcVar7 + 1" identifier = (binary_expression "pcVar7 + 1" identifier + number_literal)) ;) (expression_statement "local_24[0].__count = param_2->__count;" (assignment_expression "local_24[0].__count = param_2->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__count" identifier -> field_identifier)) ;) (expression_statement "local_24[0].__value = param_2->__value;" (assignment_expression "local_24[0].__value = param_2->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__value" identifier -> field_identifier)) ;) (expression_statement "pwVar5 = pwVar1 + 1;" (assignment_expression "pwVar5 = pwVar1 + 1" identifier = (binary_expression "pwVar1 + 1" identifier + number_literal)) ;) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = (int)pwVar5;" (assignment_expression "*param_8 = (int)pwVar5" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "*pwVar1 = L'\0';" (assignment_expression "*pwVar1 = L'\0'" (pointer_expression "*pwVar1" * identifier) = (char_literal "L'\0'" L' escape_sequence ')) ;) (if_statement "if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" if (parenthesized_expression "((param_4 <= param_3) || (param_7 <= pwVar5))" ( (binary_expression "(param_4 <= param_3) || (param_7 <= pwVar5)" (parenthesized_expression "(param_4 <= param_3)" ( (binary_expression "param_4 <= param_3" identifier <= identifier) )) || (parenthesized_expression "(param_7 <= pwVar5)" ( (binary_expression "param_7 <= pwVar5" identifier <= identifier) ))) )) (compound_statement "{\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_0027b295;" goto statement_identifier ;) })) })) (expression_statement "pwVar5 = (wchar_t *)*param_8;" (assignment_expression "pwVar5 = (wchar_t *)*param_8" identifier = (cast_expression "(wchar_t *)*param_8" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_8" * identifier))) ;) (while_statement "while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }" while (parenthesized_expression "(sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2)" ( (comma_expression "sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2" (assignment_expression "sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" identifier = (call_expression "mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" identifier (argument_list "(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" ( identifier , identifier , (binary_expression "(int)param_4 - (int)param_3" (cast_expression "(int)param_4" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) , identifier )))) , (binary_expression "1 < sVar4 + 2" number_literal < (binary_expression "sVar4 + 2" identifier + number_literal))) )) (compound_statement "{\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }" { (expression_statement "param_3 = param_3 + sVar4;" (assignment_expression "param_3 = param_3 + sVar4" identifier = (binary_expression "param_3 + sVar4" identifier + identifier)) ;) (expression_statement "pwVar5 = (wchar_t *)(*param_8 + 4);" (assignment_expression "pwVar5 = (wchar_t *)(*param_8 + 4)" identifier = (cast_expression "(wchar_t *)(*param_8 + 4)" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_8 + 4)" ( (binary_expression "*param_8 + 4" (pointer_expression "*param_8" * identifier) + number_literal) )))) ;) (expression_statement "*param_8 = (int)pwVar5;" (assignment_expression "*param_8 = (int)pwVar5" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) ;) })) (expression_statement "iVar6 = 2;" (assignment_expression "iVar6 = 2" identifier = number_literal) ;) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "param_2->__value = local_24[0].__value;" (assignment_expression "param_2->__value = local_24[0].__value" (field_expression "param_2->__value" identifier -> field_identifier) = (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier)) ;) (expression_statement "param_2->__count = local_24[0].__count;" (assignment_expression "param_2->__count = local_24[0].__count" (field_expression "param_2->__count" identifier -> field_identifier) = (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier)) ;) (expression_statement "param_3 = *param_5;" (assignment_expression "param_3 = *param_5" identifier = (pointer_expression "*param_5" * identifier)) ;) }) while (parenthesized_expression "( true )" ( true )) ;)) (labeled_statement "LAB_0027b318:\n  iVar6 = 0;" statement_identifier : (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;)) (expression_statement "param_3 = pcVar7;" (assignment_expression "param_3 = pcVar7" identifier = identifier) ;) (goto_statement "goto joined_r0x0027b200;" goto statement_identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* std::codecvt<wchar_t, char, __mbstate_t>::do_in(__mbstate_t&, char const*, char const*, char\n   const*&, wchar_t*, wchar_t*, wchar_t*&) const */\n\nint __thiscall\nstd::codecvt<wchar_t,char,__mbstate_t>::do_in\n          (codecvt<wchar_t,char,__mbstate_t> *this,__mbstate_t *param_1,char *param_2,char *param_3,\n          char **param_4,wchar_t *param_5,wchar_t *param_6,wchar_t **param_7)\n\n{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_1->__value;\n  local_24[0].__count = param_1->__count;\n  uVar2 = __uselocale(*(undefined4 *)(this + 8));\n  *param_4 = param_2;\n  *param_7 = param_5;\njoined_r0x0027b200:\n  do {\n    if (((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)) {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_3 - (int)param_2;\n      pcVar3 = (char *)memchr(param_2,0,sVar4);\n      pcVar7 = param_3;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);\n      if (sVar4 == 0xffffffff) break;\n      param_2 = *param_4;\n      pwVar1 = *param_7 + sVar4;\n      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_4 = pcVar7;\n      *param_7 = pwVar1;\n      if (param_3 <= pcVar7) goto LAB_0027b318;\n      if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_2 = pcVar7 + 1;\n      local_24[0].__count = param_1->__count;\n      local_24[0].__value = param_1->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_4 = param_2;\n      *param_7 = pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = *param_7;\n    while (sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2) {\n      param_2 = param_2 + sVar4;\n      pwVar5 = *param_7 + 1;\n      *param_7 = pwVar5;\n    }\n    iVar6 = 2;\n    *param_4 = param_2;\n    param_1->__value = local_24[0].__value;\n    param_1->__count = local_24[0].__count;\n    param_2 = *param_4;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_2 = pcVar7;\n  goto joined_r0x0027b200;\n}\n\n" comment comment (declaration "int __thiscall\nstd::codecvt<wchar_t,char,__mbstate_t>::do_in\n          (codecvt<wchar_t,char,__mbstate_t> *this,__mbstate_t *param_1,char *param_2,char *param_3,\n          char **param_4,wchar_t *param_5,wchar_t *param_6,wchar_t **param_7)\n\n{\n  wchar_t *pwVar1;" primitive_type (ms_call_modifier "__thiscall" __thiscall) (ERROR "std::codecvt<" identifier : : identifier <) identifier , identifier , (ERROR "__mbstate_t>::do_in\n          (codecvt<wchar_t,char,__mbstate_t> *this,__mbstate_t *param_1,char *param_2,char *param_3,\n          char **param_4,wchar_t *param_5,wchar_t *param_6,wchar_t **param_7)\n\n{\n  wchar_t" (function_declarator "__mbstate_t>::do_in\n          (codecvt<wchar_t,char,__mbstate_t> *this,__mbstate_t *param_1,char *param_2,char *param_3,\n          char **param_4,wchar_t *param_5,wchar_t *param_6,wchar_t **param_7)" identifier (ERROR ">::do_in" > : : identifier) (parameter_list "(codecvt<wchar_t,char,__mbstate_t> *this,__mbstate_t *param_1,char *param_2,char *param_3,\n          char **param_4,wchar_t *param_5,wchar_t *param_6,wchar_t **param_7)" ( (parameter_declaration "codecvt<wchar_t" type_identifier (ERROR "<" <) identifier) , (parameter_declaration "char" primitive_type) , (parameter_declaration "__mbstate_t> *this" type_identifier (ERROR ">" >) (pointer_declarator "*this" * identifier)) , (parameter_declaration "__mbstate_t *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "char **param_4" primitive_type (pointer_declarator "**param_4" * (pointer_declarator "*param_4" * identifier))) , (parameter_declaration "wchar_t *param_5" type_identifier (pointer_declarator "*param_5" * identifier)) , (parameter_declaration "wchar_t *param_6" type_identifier (pointer_declarator "*param_6" * identifier)) , (parameter_declaration "wchar_t **param_7" type_identifier (pointer_declarator "**param_7" * (pointer_declarator "*param_7" * identifier))) ))) { identifier) (pointer_declarator "*pwVar1" * identifier) ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "size_t sVar4;" primitive_type identifier ;) (declaration "wchar_t *pwVar5;" type_identifier (pointer_declarator "*pwVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "char *pcVar7;" primitive_type (pointer_declarator "*pcVar7" * identifier) ;) (declaration "mbstate_t local_24 [2];" type_identifier (array_declarator "local_24 [2]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "uStack_14 = 0x27b1bb;" (assignment_expression "uStack_14 = 0x27b1bb" identifier = number_literal) ;) (expression_statement "local_24[0].__value = param_1->__value;" (assignment_expression "local_24[0].__value = param_1->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_1->__value" identifier -> field_identifier)) ;) (expression_statement "local_24[0].__count = param_1->__count;" (assignment_expression "local_24[0].__count = param_1->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_1->__count" identifier -> field_identifier)) ;) (expression_statement "uVar2 = __uselocale(*(undefined4 *)(this + 8));" (assignment_expression "uVar2 = __uselocale(*(undefined4 *)(this + 8))" identifier = (call_expression "__uselocale(*(undefined4 *)(this + 8))" identifier (argument_list "(*(undefined4 *)(this + 8))" ( (pointer_expression "*(undefined4 *)(this + 8)" * (cast_expression "(undefined4 *)(this + 8)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(this + 8)" ( (binary_expression "this + 8" identifier + number_literal) )))) )))) ;) (expression_statement "*param_4 = param_2;" (assignment_expression "*param_4 = param_2" (pointer_expression "*param_4" * identifier) = identifier) ;) (expression_statement "*param_7 = param_5;" (assignment_expression "*param_7 = param_5" (pointer_expression "*param_7" * identifier) = identifier) ;) (labeled_statement "joined_r0x0027b200:\n  do {\n    if (((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)) {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_3 - (int)param_2;\n      pcVar3 = (char *)memchr(param_2,0,sVar4);\n      pcVar7 = param_3;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);\n      if (sVar4 == 0xffffffff) break;\n      param_2 = *param_4;\n      pwVar1 = *param_7 + sVar4;\n      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_4 = pcVar7;\n      *param_7 = pwVar1;\n      if (param_3 <= pcVar7) goto LAB_0027b318;\n      if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_2 = pcVar7 + 1;\n      local_24[0].__count = param_1->__count;\n      local_24[0].__value = param_1->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_4 = param_2;\n      *param_7 = pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = *param_7;\n    while (sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2) {\n      param_2 = param_2 + sVar4;\n      pwVar5 = *param_7 + 1;\n      *param_7 = pwVar5;\n    }\n    iVar6 = 2;\n    *param_4 = param_2;\n    param_1->__value = local_24[0].__value;\n    param_1->__count = local_24[0].__count;\n    param_2 = *param_4;\n  } while( true );" statement_identifier : (do_statement "do {\n    if (((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)) {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_3 - (int)param_2;\n      pcVar3 = (char *)memchr(param_2,0,sVar4);\n      pcVar7 = param_3;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);\n      if (sVar4 == 0xffffffff) break;\n      param_2 = *param_4;\n      pwVar1 = *param_7 + sVar4;\n      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_4 = pcVar7;\n      *param_7 = pwVar1;\n      if (param_3 <= pcVar7) goto LAB_0027b318;\n      if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_2 = pcVar7 + 1;\n      local_24[0].__count = param_1->__count;\n      local_24[0].__value = param_1->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_4 = param_2;\n      *param_7 = pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = *param_7;\n    while (sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2) {\n      param_2 = param_2 + sVar4;\n      pwVar5 = *param_7 + 1;\n      *param_7 = pwVar5;\n    }\n    iVar6 = 2;\n    *param_4 = param_2;\n    param_1->__value = local_24[0].__value;\n    param_1->__count = local_24[0].__count;\n    param_2 = *param_4;\n  } while( true );" do (compound_statement "{\n    if (((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)) {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_3 - (int)param_2;\n      pcVar3 = (char *)memchr(param_2,0,sVar4);\n      pcVar7 = param_3;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);\n      if (sVar4 == 0xffffffff) break;\n      param_2 = *param_4;\n      pwVar1 = *param_7 + sVar4;\n      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_4 = pcVar7;\n      *param_7 = pwVar1;\n      if (param_3 <= pcVar7) goto LAB_0027b318;\n      if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_2 = pcVar7 + 1;\n      local_24[0].__count = param_1->__count;\n      local_24[0].__value = param_1->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_4 = param_2;\n      *param_7 = pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = *param_7;\n    while (sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2) {\n      param_2 = param_2 + sVar4;\n      pwVar5 = *param_7 + 1;\n      *param_7 = pwVar5;\n    }\n    iVar6 = 2;\n    *param_4 = param_2;\n    param_1->__value = local_24[0].__value;\n    param_1->__count = local_24[0].__count;\n    param_2 = *param_4;\n  }" { (if_statement "if (((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)) {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" if (parenthesized_expression "(((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0))" ( (binary_expression "((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)) || (iVar6 != 0)" (parenthesized_expression "((param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5))" ( (binary_expression "(param_3 <= param_2) || (pwVar5 = *param_7, param_6 <= pwVar5)" (parenthesized_expression "(param_3 <= param_2)" ( (binary_expression "param_3 <= param_2" identifier <= identifier) )) || (parenthesized_expression "(pwVar5 = *param_7, param_6 <= pwVar5)" ( (comma_expression "pwVar5 = *param_7, param_6 <= pwVar5" (assignment_expression "pwVar5 = *param_7" identifier = (pointer_expression "*param_7" * identifier)) , (binary_expression "param_6 <= pwVar5" identifier <= identifier)) ))) )) || (parenthesized_expression "(iVar6 != 0)" ( (binary_expression "iVar6 != 0" identifier != number_literal) ))) )) (compound_statement "{\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" { (labeled_statement "LAB_0027b295:\n      __uselocale(uVar2);" statement_identifier : (expression_statement "__uselocale(uVar2);" (call_expression "__uselocale(uVar2)" identifier (argument_list "(uVar2)" ( identifier ))) ;)) (return_statement "return iVar6;" return identifier ;) })) (while_statement "while( true ) {\n      sVar4 = (int)param_3 - (int)param_2;\n      pcVar3 = (char *)memchr(param_2,0,sVar4);\n      pcVar7 = param_3;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);\n      if (sVar4 == 0xffffffff) break;\n      param_2 = *param_4;\n      pwVar1 = *param_7 + sVar4;\n      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_4 = pcVar7;\n      *param_7 = pwVar1;\n      if (param_3 <= pcVar7) goto LAB_0027b318;\n      if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_2 = pcVar7 + 1;\n      local_24[0].__count = param_1->__count;\n      local_24[0].__value = param_1->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_4 = param_2;\n      *param_7 = pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n      sVar4 = (int)param_3 - (int)param_2;\n      pcVar3 = (char *)memchr(param_2,0,sVar4);\n      pcVar7 = param_3;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);\n      if (sVar4 == 0xffffffff) break;\n      param_2 = *param_4;\n      pwVar1 = *param_7 + sVar4;\n      if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_4 = pcVar7;\n      *param_7 = pwVar1;\n      if (param_3 <= pcVar7) goto LAB_0027b318;\n      if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_2 = pcVar7 + 1;\n      local_24[0].__count = param_1->__count;\n      local_24[0].__value = param_1->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_4 = param_2;\n      *param_7 = pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" { (expression_statement "sVar4 = (int)param_3 - (int)param_2;" (assignment_expression "sVar4 = (int)param_3 - (int)param_2" identifier = (binary_expression "(int)param_3 - (int)param_2" (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_2" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "pcVar3 = (char *)memchr(param_2,0,sVar4);" (assignment_expression "pcVar3 = (char *)memchr(param_2,0,sVar4)" identifier = (cast_expression "(char *)memchr(param_2,0,sVar4)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "memchr(param_2,0,sVar4)" identifier (argument_list "(param_2,0,sVar4)" ( identifier , number_literal , identifier ))))) ;) (expression_statement "pcVar7 = param_3;" (assignment_expression "pcVar7 = param_3" identifier = identifier) ;) (if_statement "if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }" if (parenthesized_expression "(pcVar3 != (char *)0x0)" ( (binary_expression "pcVar3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        sVar4 = (int)pcVar3 - (int)param_2;\n        pcVar7 = pcVar3;\n      }" { (expression_statement "sVar4 = (int)pcVar3 - (int)param_2;" (assignment_expression "sVar4 = (int)pcVar3 - (int)param_2" identifier = (binary_expression "(int)pcVar3 - (int)param_2" (cast_expression "(int)pcVar3" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_2" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "pcVar7 = pcVar3;" (assignment_expression "pcVar7 = pcVar3" identifier = identifier) ;) })) (expression_statement "sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1);" (assignment_expression "sVar4 = mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1)" identifier = (call_expression "mbsnrtowcs(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1)" identifier (argument_list "(pwVar5,param_4,sVar4,(int)param_6 - (int)pwVar5 >> 2,param_1)" ( identifier , identifier , identifier , (binary_expression "(int)param_6 - (int)pwVar5 >> 2" (binary_expression "(int)param_6 - (int)pwVar5" (cast_expression "(int)param_6" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) >> number_literal) , identifier )))) ;) (if_statement "if (sVar4 == 0xffffffff) break;" if (parenthesized_expression "(sVar4 == 0xffffffff)" ( (binary_expression "sVar4 == 0xffffffff" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "param_2 = *param_4;" (assignment_expression "param_2 = *param_4" identifier = (pointer_expression "*param_4" * identifier)) ;) (expression_statement "pwVar1 = *param_7 + sVar4;" (assignment_expression "pwVar1 = *param_7 + sVar4" identifier = (binary_expression "*param_7 + sVar4" (pointer_expression "*param_7" * identifier) + identifier)) ;) (if_statement "if ((param_2 < pcVar7) && (param_2 != (char *)0x0)) {\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" if (parenthesized_expression "((param_2 < pcVar7) && (param_2 != (char *)0x0))" ( (binary_expression "(param_2 < pcVar7) && (param_2 != (char *)0x0)" (parenthesized_expression "(param_2 < pcVar7)" ( (binary_expression "param_2 < pcVar7" identifier < identifier) )) && (parenthesized_expression "(param_2 != (char *)0x0)" ( (binary_expression "param_2 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ))) )) (compound_statement "{\n        *param_7 = pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" { (expression_statement "*param_7 = pwVar1;" (assignment_expression "*param_7 = pwVar1" (pointer_expression "*param_7" * identifier) = identifier) ;) (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) (goto_statement "goto joined_r0x0027b200;" goto statement_identifier ;) })) (expression_statement "*param_4 = pcVar7;" (assignment_expression "*param_4 = pcVar7" (pointer_expression "*param_4" * identifier) = identifier) ;) (expression_statement "*param_7 = pwVar1;" (assignment_expression "*param_7 = pwVar1" (pointer_expression "*param_7" * identifier) = identifier) ;) (if_statement "if (param_3 <= pcVar7) goto LAB_0027b318;" if (parenthesized_expression "(param_3 <= pcVar7)" ( (binary_expression "param_3 <= pcVar7" identifier <= identifier) )) (goto_statement "goto LAB_0027b318;" goto statement_identifier ;)) (if_statement "if (param_6 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" if (parenthesized_expression "(param_6 <= pwVar1)" ( (binary_expression "param_6 <= pwVar1" identifier <= identifier) )) (compound_statement "{\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) (goto_statement "goto LAB_0027b295;" goto statement_identifier ;) })) (expression_statement "param_2 = pcVar7 + 1;" (assignment_expression "param_2 = pcVar7 + 1" identifier = (binary_expression "pcVar7 + 1" identifier + number_literal)) ;) (expression_statement "local_24[0].__count = param_1->__count;" (assignment_expression "local_24[0].__count = param_1->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_1->__count" identifier -> field_identifier)) ;) (expression_statement "local_24[0].__value = param_1->__value;" (assignment_expression "local_24[0].__value = param_1->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_1->__value" identifier -> field_identifier)) ;) (expression_statement "pwVar5 = pwVar1 + 1;" (assignment_expression "pwVar5 = pwVar1 + 1" identifier = (binary_expression "pwVar1 + 1" identifier + number_literal)) ;) (expression_statement "*param_4 = param_2;" (assignment_expression "*param_4 = param_2" (pointer_expression "*param_4" * identifier) = identifier) ;) (expression_statement "*param_7 = pwVar5;" (assignment_expression "*param_7 = pwVar5" (pointer_expression "*param_7" * identifier) = identifier) ;) (expression_statement "*pwVar1 = L'\0';" (assignment_expression "*pwVar1 = L'\0'" (pointer_expression "*pwVar1" * identifier) = (char_literal "L'\0'" L' escape_sequence ')) ;) (if_statement "if ((param_3 <= param_2) || (param_6 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" if (parenthesized_expression "((param_3 <= param_2) || (param_6 <= pwVar5))" ( (binary_expression "(param_3 <= param_2) || (param_6 <= pwVar5)" (parenthesized_expression "(param_3 <= param_2)" ( (binary_expression "param_3 <= param_2" identifier <= identifier) )) || (parenthesized_expression "(param_6 <= pwVar5)" ( (binary_expression "param_6 <= pwVar5" identifier <= identifier) ))) )) (compound_statement "{\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_0027b295;" goto statement_identifier ;) })) })) (expression_statement "pwVar5 = *param_7;" (assignment_expression "pwVar5 = *param_7" identifier = (pointer_expression "*param_7" * identifier)) ;) (while_statement "while (sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2) {\n      param_2 = param_2 + sVar4;\n      pwVar5 = *param_7 + 1;\n      *param_7 = pwVar5;\n    }" while (parenthesized_expression "(sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2)" ( (comma_expression "sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24), 1 < sVar4 + 2" (assignment_expression "sVar4 = mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24)" identifier = (call_expression "mbrtowc(pwVar5,param_2,(int)param_3 - (int)param_2,local_24)" identifier (argument_list "(pwVar5,param_2,(int)param_3 - (int)param_2,local_24)" ( identifier , identifier , (binary_expression "(int)param_3 - (int)param_2" (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_2" ( (type_descriptor "int" primitive_type) ) identifier)) , identifier )))) , (binary_expression "1 < sVar4 + 2" number_literal < (binary_expression "sVar4 + 2" identifier + number_literal))) )) (compound_statement "{\n      param_2 = param_2 + sVar4;\n      pwVar5 = *param_7 + 1;\n      *param_7 = pwVar5;\n    }" { (expression_statement "param_2 = param_2 + sVar4;" (assignment_expression "param_2 = param_2 + sVar4" identifier = (binary_expression "param_2 + sVar4" identifier + identifier)) ;) (expression_statement "pwVar5 = *param_7 + 1;" (assignment_expression "pwVar5 = *param_7 + 1" identifier = (binary_expression "*param_7 + 1" (pointer_expression "*param_7" * identifier) + number_literal)) ;) (expression_statement "*param_7 = pwVar5;" (assignment_expression "*param_7 = pwVar5" (pointer_expression "*param_7" * identifier) = identifier) ;) })) (expression_statement "iVar6 = 2;" (assignment_expression "iVar6 = 2" identifier = number_literal) ;) (expression_statement "*param_4 = param_2;" (assignment_expression "*param_4 = param_2" (pointer_expression "*param_4" * identifier) = identifier) ;) (expression_statement "param_1->__value = local_24[0].__value;" (assignment_expression "param_1->__value = local_24[0].__value" (field_expression "param_1->__value" identifier -> field_identifier) = (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier)) ;) (expression_statement "param_1->__count = local_24[0].__count;" (assignment_expression "param_1->__count = local_24[0].__count" (field_expression "param_1->__count" identifier -> field_identifier) = (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier)) ;) (expression_statement "param_2 = *param_4;" (assignment_expression "param_2 = *param_4" identifier = (pointer_expression "*param_4" * identifier)) ;) }) while (parenthesized_expression "( true )" ( true )) ;)) (labeled_statement "LAB_0027b318:\n  iVar6 = 0;" statement_identifier : (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;)) (expression_statement "param_2 = pcVar7;" (assignment_expression "param_2 = pcVar7" identifier = identifier) ;) (goto_statement "goto joined_r0x0027b200;" goto statement_identifier ;) (ERROR "}" }))
(translation_unit "int FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)\n\n{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}\n\n" (function_definition "int FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)\n\n{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}" primitive_type (function_declarator "FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)" identifier (parameter_list "(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "mbstate_t *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "char *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "char *param_4" primitive_type (pointer_declarator "*param_4" * identifier)) , (parameter_declaration "char **param_5" primitive_type (pointer_declarator "**param_5" * (pointer_declarator "*param_5" * identifier))) , (parameter_declaration "int param_6" primitive_type identifier) , (parameter_declaration "wchar_t *param_7" type_identifier (pointer_declarator "*param_7" * identifier)) , (parameter_declaration "int *param_8" primitive_type (pointer_declarator "*param_8" * identifier)) ))) (compound_statement "{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}" { (declaration "wchar_t *pwVar1;" type_identifier (pointer_declarator "*pwVar1" * identifier) ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "char *pcVar3;" primitive_type (pointer_declarator "*pcVar3" * identifier) ;) (declaration "size_t sVar4;" primitive_type identifier ;) (declaration "wchar_t *pwVar5;" type_identifier (pointer_declarator "*pwVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "char *pcVar7;" primitive_type (pointer_declarator "*pcVar7" * identifier) ;) (declaration "mbstate_t local_24 [2];" type_identifier (array_declarator "local_24 [2]" identifier [ number_literal ]) ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (expression_statement "uStack_14 = 0x27b1bb;" (assignment_expression "uStack_14 = 0x27b1bb" identifier = number_literal) ;) (expression_statement "local_24[0].__value = param_2->__value;" (assignment_expression "local_24[0].__value = param_2->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__value" identifier -> field_identifier)) ;) (expression_statement "local_24[0].__count = param_2->__count;" (assignment_expression "local_24[0].__count = param_2->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__count" identifier -> field_identifier)) ;) (expression_statement "uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));" (assignment_expression "uVar2 = __uselocale(*(undefined4 *)(param_1 + 8))" identifier = (call_expression "__uselocale(*(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 "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = param_6;" (assignment_expression "*param_8 = param_6" (pointer_expression "*param_8" * identifier) = identifier) ;) (labeled_statement "joined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );" statement_identifier : (do_statement "do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );" do (compound_statement "{\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  }" { (if_statement "if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" if (parenthesized_expression "(((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))" ( (binary_expression "((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0)" (parenthesized_expression "((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5))" ( (binary_expression "(param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)" (parenthesized_expression "(param_4 <= param_3)" ( (binary_expression "param_4 <= param_3" identifier <= identifier) )) || (parenthesized_expression "(pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)" ( (comma_expression "pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5" (assignment_expression "pwVar5 = (wchar_t *)*param_8" identifier = (cast_expression "(wchar_t *)*param_8" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_8" * identifier))) , (binary_expression "param_7 <= pwVar5" identifier <= identifier)) ))) )) || (parenthesized_expression "(iVar6 != 0)" ( (binary_expression "iVar6 != 0" identifier != number_literal) ))) )) (compound_statement "{\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" { (labeled_statement "LAB_0027b295:\n      __uselocale(uVar2);" statement_identifier : (expression_statement "__uselocale(uVar2);" (call_expression "__uselocale(uVar2)" identifier (argument_list "(uVar2)" ( identifier ))) ;)) (return_statement "return iVar6;" return identifier ;) })) (while_statement "while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" { (expression_statement "sVar4 = (int)param_4 - (int)param_3;" (assignment_expression "sVar4 = (int)param_4 - (int)param_3" identifier = (binary_expression "(int)param_4 - (int)param_3" (cast_expression "(int)param_4" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "pcVar3 = (char *)memchr(param_3,0,sVar4);" (assignment_expression "pcVar3 = (char *)memchr(param_3,0,sVar4)" identifier = (cast_expression "(char *)memchr(param_3,0,sVar4)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "memchr(param_3,0,sVar4)" identifier (argument_list "(param_3,0,sVar4)" ( identifier , number_literal , identifier ))))) ;) (expression_statement "pcVar7 = param_4;" (assignment_expression "pcVar7 = param_4" identifier = identifier) ;) (if_statement "if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }" if (parenthesized_expression "(pcVar3 != (char *)0x0)" ( (binary_expression "pcVar3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }" { (expression_statement "sVar4 = (int)pcVar3 - (int)param_3;" (assignment_expression "sVar4 = (int)pcVar3 - (int)param_3" identifier = (binary_expression "(int)pcVar3 - (int)param_3" (cast_expression "(int)pcVar3" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier))) ;) (expression_statement "pcVar7 = pcVar3;" (assignment_expression "pcVar7 = pcVar3" identifier = identifier) ;) })) (expression_statement "sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);" (assignment_expression "sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" identifier = (call_expression "mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" identifier (argument_list "(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" ( identifier , identifier , identifier , (binary_expression "(int)param_7 - (int)pwVar5 >> 2" (binary_expression "(int)param_7 - (int)pwVar5" (cast_expression "(int)param_7" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) >> number_literal) , identifier )))) ;) (if_statement "if (sVar4 == 0xffffffff) break;" if (parenthesized_expression "(sVar4 == 0xffffffff)" ( (binary_expression "sVar4 == 0xffffffff" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "param_3 = *param_5;" (assignment_expression "param_3 = *param_5" identifier = (pointer_expression "*param_5" * identifier)) ;) (expression_statement "pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);" (assignment_expression "pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4)" identifier = (cast_expression "(wchar_t *)(*param_8 + sVar4 * 4)" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_8 + sVar4 * 4)" ( (binary_expression "*param_8 + sVar4 * 4" (pointer_expression "*param_8" * identifier) + (binary_expression "sVar4 * 4" identifier * number_literal)) )))) ;) (if_statement "if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" if (parenthesized_expression "((param_3 < pcVar7) && (param_3 != (char *)0x0))" ( (binary_expression "(param_3 < pcVar7) && (param_3 != (char *)0x0)" (parenthesized_expression "(param_3 < pcVar7)" ( (binary_expression "param_3 < pcVar7" identifier < identifier) )) && (parenthesized_expression "(param_3 != (char *)0x0)" ( (binary_expression "param_3 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ))) )) (compound_statement "{\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" { (expression_statement "*param_8 = (int)pwVar1;" (assignment_expression "*param_8 = (int)pwVar1" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar1" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) (goto_statement "goto joined_r0x0027b200;" goto statement_identifier ;) })) (expression_statement "*param_5 = pcVar7;" (assignment_expression "*param_5 = pcVar7" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = (int)pwVar1;" (assignment_expression "*param_8 = (int)pwVar1" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar1" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (if_statement "if (param_4 <= pcVar7) goto LAB_0027b318;" if (parenthesized_expression "(param_4 <= pcVar7)" ( (binary_expression "param_4 <= pcVar7" identifier <= identifier) )) (goto_statement "goto LAB_0027b318;" goto statement_identifier ;)) (if_statement "if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" if (parenthesized_expression "(param_7 <= pwVar1)" ( (binary_expression "param_7 <= pwVar1" identifier <= identifier) )) (compound_statement "{\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) (goto_statement "goto LAB_0027b295;" goto statement_identifier ;) })) (expression_statement "param_3 = pcVar7 + 1;" (assignment_expression "param_3 = pcVar7 + 1" identifier = (binary_expression "pcVar7 + 1" identifier + number_literal)) ;) (expression_statement "local_24[0].__count = param_2->__count;" (assignment_expression "local_24[0].__count = param_2->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__count" identifier -> field_identifier)) ;) (expression_statement "local_24[0].__value = param_2->__value;" (assignment_expression "local_24[0].__value = param_2->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier) = (field_expression "param_2->__value" identifier -> field_identifier)) ;) (expression_statement "pwVar5 = pwVar1 + 1;" (assignment_expression "pwVar5 = pwVar1 + 1" identifier = (binary_expression "pwVar1 + 1" identifier + number_literal)) ;) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "*param_8 = (int)pwVar5;" (assignment_expression "*param_8 = (int)pwVar5" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "*pwVar1 = L'\0';" (assignment_expression "*pwVar1 = L'\0'" (pointer_expression "*pwVar1" * identifier) = (char_literal "L'\0'" L' escape_sequence ')) ;) (if_statement "if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" if (parenthesized_expression "((param_4 <= param_3) || (param_7 <= pwVar5))" ( (binary_expression "(param_4 <= param_3) || (param_7 <= pwVar5)" (parenthesized_expression "(param_4 <= param_3)" ( (binary_expression "param_4 <= param_3" identifier <= identifier) )) || (parenthesized_expression "(param_7 <= pwVar5)" ( (binary_expression "param_7 <= pwVar5" identifier <= identifier) ))) )) (compound_statement "{\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" { (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_0027b295;" goto statement_identifier ;) })) })) (expression_statement "pwVar5 = (wchar_t *)*param_8;" (assignment_expression "pwVar5 = (wchar_t *)*param_8" identifier = (cast_expression "(wchar_t *)*param_8" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_8" * identifier))) ;) (while_statement "while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }" while (parenthesized_expression "(sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2)" ( (comma_expression "sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2" (assignment_expression "sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" identifier = (call_expression "mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" identifier (argument_list "(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" ( identifier , identifier , (binary_expression "(int)param_4 - (int)param_3" (cast_expression "(int)param_4" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_3" ( (type_descriptor "int" primitive_type) ) identifier)) , identifier )))) , (binary_expression "1 < sVar4 + 2" number_literal < (binary_expression "sVar4 + 2" identifier + number_literal))) )) (compound_statement "{\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }" { (expression_statement "param_3 = param_3 + sVar4;" (assignment_expression "param_3 = param_3 + sVar4" identifier = (binary_expression "param_3 + sVar4" identifier + identifier)) ;) (expression_statement "pwVar5 = (wchar_t *)(*param_8 + 4);" (assignment_expression "pwVar5 = (wchar_t *)(*param_8 + 4)" identifier = (cast_expression "(wchar_t *)(*param_8 + 4)" ( (type_descriptor "wchar_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*param_8 + 4)" ( (binary_expression "*param_8 + 4" (pointer_expression "*param_8" * identifier) + number_literal) )))) ;) (expression_statement "*param_8 = (int)pwVar5;" (assignment_expression "*param_8 = (int)pwVar5" (pointer_expression "*param_8" * identifier) = (cast_expression "(int)pwVar5" ( (type_descriptor "int" primitive_type) ) identifier)) ;) })) (expression_statement "iVar6 = 2;" (assignment_expression "iVar6 = 2" identifier = number_literal) ;) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" * identifier) = identifier) ;) (expression_statement "param_2->__value = local_24[0].__value;" (assignment_expression "param_2->__value = local_24[0].__value" (field_expression "param_2->__value" identifier -> field_identifier) = (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier)) ;) (expression_statement "param_2->__count = local_24[0].__count;" (assignment_expression "param_2->__count = local_24[0].__count" (field_expression "param_2->__count" identifier -> field_identifier) = (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" identifier [ number_literal ]) . field_identifier)) ;) (expression_statement "param_3 = *param_5;" (assignment_expression "param_3 = *param_5" identifier = (pointer_expression "*param_5" * identifier)) ;) }) while (parenthesized_expression "( true )" ( true )) ;)) (labeled_statement "LAB_0027b318:\n  iVar6 = 0;" statement_identifier : (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" identifier = number_literal) ;)) (expression_statement "param_3 = pcVar7;" (assignment_expression "param_3 = pcVar7" identifier = identifier) ;) (goto_statement "goto joined_r0x0027b200;" goto statement_identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * (pointer_declarator * IDENT))) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier) = (field_expression IDENT -> field_identifier)) ;) (expression_statement (assignment_expression (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier) = (field_expression IDENT -> field_identifier)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (labeled_statement statement_identifier : (do_statement do (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) || (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) , (binary_expression IDENT <= IDENT)) ))) )) || (parenthesized_expression ( (binary_expression IDENT != LIT) ))) )) (compound_statement { (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;)) (return_statement return IDENT ;) })) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , LIT , IDENT ))))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT , (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT)) >> LIT) , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) + (binary_expression IDENT * LIT)) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT < IDENT) )) && (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ))) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier) = (field_expression IDENT -> field_identifier)) ;) (expression_statement (assignment_expression (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier) = (field_expression IDENT -> field_identifier)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (char_literal L' escape_sequence ')) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) || (parenthesized_expression ( (binary_expression IDENT <= IDENT) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (while_statement while (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT)) , IDENT )))) , (binary_expression LIT < (binary_expression IDENT + LIT))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) + LIT) )))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) })) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (field_expression IDENT -> field_identifier) = (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier)) ;) (expression_statement (assignment_expression (field_expression IDENT -> field_identifier) = (field_expression (subscript_expression IDENT [ LIT ]) . field_identifier)) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) }) while (parenthesized_expression ( BOOL )) ;)) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = LIT) ;)) (expression_statement (assignment_expression IDENT = IDENT) ;) (goto_statement goto statement_identifier ;) })))
(function_definition "int FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)\n\n{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}" (primitive_type "int") (function_declarator "FUN_0027b1b0(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)" (identifier "FUN_0027b1b0") (parameter_list "(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,\n                int param_6,wchar_t *param_7,int *param_8)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "mbstate_t *param_2" (type_identifier "mbstate_t") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "char *param_3" (primitive_type "char") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) (, ",") (parameter_declaration "char *param_4" (primitive_type "char") (pointer_declarator "*param_4" (* "*") (identifier "param_4"))) (, ",") (parameter_declaration "char **param_5" (primitive_type "char") (pointer_declarator "**param_5" (* "*") (pointer_declarator "*param_5" (* "*") (identifier "param_5")))) (, ",") (parameter_declaration "int param_6" (primitive_type "int") (identifier "param_6")) (, ",") (parameter_declaration "wchar_t *param_7" (type_identifier "wchar_t") (pointer_declarator "*param_7" (* "*") (identifier "param_7"))) (, ",") (parameter_declaration "int *param_8" (primitive_type "int") (pointer_declarator "*param_8" (* "*") (identifier "param_8"))) () ")"))) (compound_statement "{\n  wchar_t *pwVar1;\n  undefined4 uVar2;\n  char *pcVar3;\n  size_t sVar4;\n  wchar_t *pwVar5;\n  int iVar6;\n  char *pcVar7;\n  mbstate_t local_24 [2];\n  undefined4 uStack_14;\n  \n  iVar6 = 0;\n  uStack_14 = 0x27b1bb;\n  local_24[0].__value = param_2->__value;\n  local_24[0].__count = param_2->__count;\n  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));\n  *param_5 = param_3;\n  *param_8 = param_6;\njoined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );\nLAB_0027b318:\n  iVar6 = 0;\n  param_3 = pcVar7;\n  goto joined_r0x0027b200;\n}" ({ "{") (declaration "wchar_t *pwVar1;" (type_identifier "wchar_t") (pointer_declarator "*pwVar1" (* "*") (identifier "pwVar1")) (; ";")) (declaration "undefined4 uVar2;" (type_identifier "undefined4") (identifier "uVar2") (; ";")) (declaration "char *pcVar3;" (primitive_type "char") (pointer_declarator "*pcVar3" (* "*") (identifier "pcVar3")) (; ";")) (declaration "size_t sVar4;" (primitive_type "size_t") (identifier "sVar4") (; ";")) (declaration "wchar_t *pwVar5;" (type_identifier "wchar_t") (pointer_declarator "*pwVar5" (* "*") (identifier "pwVar5")) (; ";")) (declaration "int iVar6;" (primitive_type "int") (identifier "iVar6") (; ";")) (declaration "char *pcVar7;" (primitive_type "char") (pointer_declarator "*pcVar7" (* "*") (identifier "pcVar7")) (; ";")) (declaration "mbstate_t local_24 [2];" (type_identifier "mbstate_t") (array_declarator "local_24 [2]" (identifier "local_24") ([ "[") (number_literal "2") (] "]")) (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" (identifier "iVar6") (= "=") (number_literal "0")) (; ";")) (expression_statement "uStack_14 = 0x27b1bb;" (assignment_expression "uStack_14 = 0x27b1bb" (identifier "uStack_14") (= "=") (number_literal "0x27b1bb")) (; ";")) (expression_statement "local_24[0].__value = param_2->__value;" (assignment_expression "local_24[0].__value = param_2->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" (identifier "local_24") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "__value")) (= "=") (field_expression "param_2->__value" (identifier "param_2") (-> "->") (field_identifier "__value"))) (; ";")) (expression_statement "local_24[0].__count = param_2->__count;" (assignment_expression "local_24[0].__count = param_2->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" (identifier "local_24") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "__count")) (= "=") (field_expression "param_2->__count" (identifier "param_2") (-> "->") (field_identifier "__count"))) (; ";")) (expression_statement "uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));" (assignment_expression "uVar2 = __uselocale(*(undefined4 *)(param_1 + 8))" (identifier "uVar2") (= "=") (call_expression "__uselocale(*(undefined4 *)(param_1 + 8))" (identifier "__uselocale") (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 "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" (* "*") (identifier "param_5")) (= "=") (identifier "param_3")) (; ";")) (expression_statement "*param_8 = param_6;" (assignment_expression "*param_8 = param_6" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (= "=") (identifier "param_6")) (; ";")) (labeled_statement "joined_r0x0027b200:\n  do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );" (statement_identifier "joined_r0x0027b200") (: ":") (do_statement "do {\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  } while( true );" (do "do") (compound_statement "{\n    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }\n    while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }\n    pwVar5 = (wchar_t *)*param_8;\n    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }\n    iVar6 = 2;\n    *param_5 = param_3;\n    param_2->__value = local_24[0].__value;\n    param_2->__count = local_24[0].__count;\n    param_3 = *param_5;\n  }" ({ "{") (if_statement "if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))\n    {\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" (if "if") (parenthesized_expression "(((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))" (( "(") (binary_expression "((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0)" (parenthesized_expression "((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5))" (( "(") (binary_expression "(param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)" (parenthesized_expression "(param_4 <= param_3)" (( "(") (binary_expression "param_4 <= param_3" (identifier "param_4") (<= "<=") (identifier "param_3")) () ")")) (|| "||") (parenthesized_expression "(pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)" (( "(") (comma_expression "pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5" (assignment_expression "pwVar5 = (wchar_t *)*param_8" (identifier "pwVar5") (= "=") (cast_expression "(wchar_t *)*param_8" (( "(") (type_descriptor "wchar_t *" (type_identifier "wchar_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_8" (* "*") (identifier "param_8")))) (, ",") (binary_expression "param_7 <= pwVar5" (identifier "param_7") (<= "<=") (identifier "pwVar5"))) () ")"))) () ")")) (|| "||") (parenthesized_expression "(iVar6 != 0)" (( "(") (binary_expression "iVar6 != 0" (identifier "iVar6") (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\nLAB_0027b295:\n      __uselocale(uVar2);\n      return iVar6;\n    }" ({ "{") (labeled_statement "LAB_0027b295:\n      __uselocale(uVar2);" (statement_identifier "LAB_0027b295") (: ":") (expression_statement "__uselocale(uVar2);" (call_expression "__uselocale(uVar2)" (identifier "__uselocale") (argument_list "(uVar2)" (( "(") (identifier "uVar2") () ")"))) (; ";"))) (return_statement "return iVar6;" (return "return") (identifier "iVar6") (; ";")) (} "}"))) (while_statement "while( true ) {\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n      sVar4 = (int)param_4 - (int)param_3;\n      pcVar3 = (char *)memchr(param_3,0,sVar4);\n      pcVar7 = param_4;\n      if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }\n      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);\n      if (sVar4 == 0xffffffff) break;\n      param_3 = *param_5;\n      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);\n      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }\n      *param_5 = pcVar7;\n      *param_8 = (int)pwVar1;\n      if (param_4 <= pcVar7) goto LAB_0027b318;\n      if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }\n      param_3 = pcVar7 + 1;\n      local_24[0].__count = param_2->__count;\n      local_24[0].__value = param_2->__value;\n      pwVar5 = pwVar1 + 1;\n      *param_5 = param_3;\n      *param_8 = (int)pwVar5;\n      *pwVar1 = L'\0';\n      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }\n    }" ({ "{") (expression_statement "sVar4 = (int)param_4 - (int)param_3;" (assignment_expression "sVar4 = (int)param_4 - (int)param_3" (identifier "sVar4") (= "=") (binary_expression "(int)param_4 - (int)param_3" (cast_expression "(int)param_4" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_4")) (- "-") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3")))) (; ";")) (expression_statement "pcVar3 = (char *)memchr(param_3,0,sVar4);" (assignment_expression "pcVar3 = (char *)memchr(param_3,0,sVar4)" (identifier "pcVar3") (= "=") (cast_expression "(char *)memchr(param_3,0,sVar4)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "memchr(param_3,0,sVar4)" (identifier "memchr") (argument_list "(param_3,0,sVar4)" (( "(") (identifier "param_3") (, ",") (number_literal "0") (, ",") (identifier "sVar4") () ")"))))) (; ";")) (expression_statement "pcVar7 = param_4;" (assignment_expression "pcVar7 = param_4" (identifier "pcVar7") (= "=") (identifier "param_4")) (; ";")) (if_statement "if (pcVar3 != (char *)0x0) {\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }" (if "if") (parenthesized_expression "(pcVar3 != (char *)0x0)" (( "(") (binary_expression "pcVar3 != (char *)0x0" (identifier "pcVar3") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n        sVar4 = (int)pcVar3 - (int)param_3;\n        pcVar7 = pcVar3;\n      }" ({ "{") (expression_statement "sVar4 = (int)pcVar3 - (int)param_3;" (assignment_expression "sVar4 = (int)pcVar3 - (int)param_3" (identifier "sVar4") (= "=") (binary_expression "(int)pcVar3 - (int)param_3" (cast_expression "(int)pcVar3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pcVar3")) (- "-") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3")))) (; ";")) (expression_statement "pcVar7 = pcVar3;" (assignment_expression "pcVar7 = pcVar3" (identifier "pcVar7") (= "=") (identifier "pcVar3")) (; ";")) (} "}"))) (expression_statement "sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);" (assignment_expression "sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" (identifier "sVar4") (= "=") (call_expression "mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" (identifier "mbsnrtowcs") (argument_list "(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2)" (( "(") (identifier "pwVar5") (, ",") (identifier "param_5") (, ",") (identifier "sVar4") (, ",") (binary_expression "(int)param_7 - (int)pwVar5 >> 2" (binary_expression "(int)param_7 - (int)pwVar5" (cast_expression "(int)param_7" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_7")) (- "-") (cast_expression "(int)pwVar5" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pwVar5"))) (>> ">>") (number_literal "2")) (, ",") (identifier "param_2") () ")")))) (; ";")) (if_statement "if (sVar4 == 0xffffffff) break;" (if "if") (parenthesized_expression "(sVar4 == 0xffffffff)" (( "(") (binary_expression "sVar4 == 0xffffffff" (identifier "sVar4") (== "==") (number_literal "0xffffffff")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "param_3 = *param_5;" (assignment_expression "param_3 = *param_5" (identifier "param_3") (= "=") (pointer_expression "*param_5" (* "*") (identifier "param_5"))) (; ";")) (expression_statement "pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);" (assignment_expression "pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4)" (identifier "pwVar1") (= "=") (cast_expression "(wchar_t *)(*param_8 + sVar4 * 4)" (( "(") (type_descriptor "wchar_t *" (type_identifier "wchar_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*param_8 + sVar4 * 4)" (( "(") (binary_expression "*param_8 + sVar4 * 4" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (+ "+") (binary_expression "sVar4 * 4" (identifier "sVar4") (* "*") (number_literal "4"))) () ")")))) (; ";")) (if_statement "if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" (if "if") (parenthesized_expression "((param_3 < pcVar7) && (param_3 != (char *)0x0))" (( "(") (binary_expression "(param_3 < pcVar7) && (param_3 != (char *)0x0)" (parenthesized_expression "(param_3 < pcVar7)" (( "(") (binary_expression "param_3 < pcVar7" (identifier "param_3") (< "<") (identifier "pcVar7")) () ")")) (&& "&&") (parenthesized_expression "(param_3 != (char *)0x0)" (( "(") (binary_expression "param_3 != (char *)0x0" (identifier "param_3") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")"))) () ")")) (compound_statement "{\n        *param_8 = (int)pwVar1;\n        iVar6 = 1;\n        goto joined_r0x0027b200;\n      }" ({ "{") (expression_statement "*param_8 = (int)pwVar1;" (assignment_expression "*param_8 = (int)pwVar1" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (= "=") (cast_expression "(int)pwVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pwVar1"))) (; ";")) (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" (identifier "iVar6") (= "=") (number_literal "1")) (; ";")) (goto_statement "goto joined_r0x0027b200;" (goto "goto") (statement_identifier "joined_r0x0027b200") (; ";")) (} "}"))) (expression_statement "*param_5 = pcVar7;" (assignment_expression "*param_5 = pcVar7" (pointer_expression "*param_5" (* "*") (identifier "param_5")) (= "=") (identifier "pcVar7")) (; ";")) (expression_statement "*param_8 = (int)pwVar1;" (assignment_expression "*param_8 = (int)pwVar1" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (= "=") (cast_expression "(int)pwVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pwVar1"))) (; ";")) (if_statement "if (param_4 <= pcVar7) goto LAB_0027b318;" (if "if") (parenthesized_expression "(param_4 <= pcVar7)" (( "(") (binary_expression "param_4 <= pcVar7" (identifier "param_4") (<= "<=") (identifier "pcVar7")) () ")")) (goto_statement "goto LAB_0027b318;" (goto "goto") (statement_identifier "LAB_0027b318") (; ";"))) (if_statement "if (param_7 <= pwVar1) {\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" (if "if") (parenthesized_expression "(param_7 <= pwVar1)" (( "(") (binary_expression "param_7 <= pwVar1" (identifier "param_7") (<= "<=") (identifier "pwVar1")) () ")")) (compound_statement "{\n        iVar6 = 1;\n        goto LAB_0027b295;\n      }" ({ "{") (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" (identifier "iVar6") (= "=") (number_literal "1")) (; ";")) (goto_statement "goto LAB_0027b295;" (goto "goto") (statement_identifier "LAB_0027b295") (; ";")) (} "}"))) (expression_statement "param_3 = pcVar7 + 1;" (assignment_expression "param_3 = pcVar7 + 1" (identifier "param_3") (= "=") (binary_expression "pcVar7 + 1" (identifier "pcVar7") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "local_24[0].__count = param_2->__count;" (assignment_expression "local_24[0].__count = param_2->__count" (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" (identifier "local_24") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "__count")) (= "=") (field_expression "param_2->__count" (identifier "param_2") (-> "->") (field_identifier "__count"))) (; ";")) (expression_statement "local_24[0].__value = param_2->__value;" (assignment_expression "local_24[0].__value = param_2->__value" (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" (identifier "local_24") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "__value")) (= "=") (field_expression "param_2->__value" (identifier "param_2") (-> "->") (field_identifier "__value"))) (; ";")) (expression_statement "pwVar5 = pwVar1 + 1;" (assignment_expression "pwVar5 = pwVar1 + 1" (identifier "pwVar5") (= "=") (binary_expression "pwVar1 + 1" (identifier "pwVar1") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" (* "*") (identifier "param_5")) (= "=") (identifier "param_3")) (; ";")) (expression_statement "*param_8 = (int)pwVar5;" (assignment_expression "*param_8 = (int)pwVar5" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (= "=") (cast_expression "(int)pwVar5" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pwVar5"))) (; ";")) (expression_statement "*pwVar1 = L'\0';" (assignment_expression "*pwVar1 = L'\0'" (pointer_expression "*pwVar1" (* "*") (identifier "pwVar1")) (= "=") (char_literal "L'\0'" (L' "L'") (escape_sequence "\0") (' "'"))) (; ";")) (if_statement "if ((param_4 <= param_3) || (param_7 <= pwVar5)) {\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" (if "if") (parenthesized_expression "((param_4 <= param_3) || (param_7 <= pwVar5))" (( "(") (binary_expression "(param_4 <= param_3) || (param_7 <= pwVar5)" (parenthesized_expression "(param_4 <= param_3)" (( "(") (binary_expression "param_4 <= param_3" (identifier "param_4") (<= "<=") (identifier "param_3")) () ")")) (|| "||") (parenthesized_expression "(param_7 <= pwVar5)" (( "(") (binary_expression "param_7 <= pwVar5" (identifier "param_7") (<= "<=") (identifier "pwVar5")) () ")"))) () ")")) (compound_statement "{\n        iVar6 = 0;\n        goto LAB_0027b295;\n      }" ({ "{") (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" (identifier "iVar6") (= "=") (number_literal "0")) (; ";")) (goto_statement "goto LAB_0027b295;" (goto "goto") (statement_identifier "LAB_0027b295") (; ";")) (} "}"))) (} "}"))) (expression_statement "pwVar5 = (wchar_t *)*param_8;" (assignment_expression "pwVar5 = (wchar_t *)*param_8" (identifier "pwVar5") (= "=") (cast_expression "(wchar_t *)*param_8" (( "(") (type_descriptor "wchar_t *" (type_identifier "wchar_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_8" (* "*") (identifier "param_8")))) (; ";")) (while_statement "while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }" (while "while") (parenthesized_expression "(sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2)" (( "(") (comma_expression "sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2" (assignment_expression "sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" (identifier "sVar4") (= "=") (call_expression "mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" (identifier "mbrtowc") (argument_list "(pwVar5,param_3,(int)param_4 - (int)param_3,local_24)" (( "(") (identifier "pwVar5") (, ",") (identifier "param_3") (, ",") (binary_expression "(int)param_4 - (int)param_3" (cast_expression "(int)param_4" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_4")) (- "-") (cast_expression "(int)param_3" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_3"))) (, ",") (identifier "local_24") () ")")))) (, ",") (binary_expression "1 < sVar4 + 2" (number_literal "1") (< "<") (binary_expression "sVar4 + 2" (identifier "sVar4") (+ "+") (number_literal "2")))) () ")")) (compound_statement "{\n      param_3 = param_3 + sVar4;\n      pwVar5 = (wchar_t *)(*param_8 + 4);\n      *param_8 = (int)pwVar5;\n    }" ({ "{") (expression_statement "param_3 = param_3 + sVar4;" (assignment_expression "param_3 = param_3 + sVar4" (identifier "param_3") (= "=") (binary_expression "param_3 + sVar4" (identifier "param_3") (+ "+") (identifier "sVar4"))) (; ";")) (expression_statement "pwVar5 = (wchar_t *)(*param_8 + 4);" (assignment_expression "pwVar5 = (wchar_t *)(*param_8 + 4)" (identifier "pwVar5") (= "=") (cast_expression "(wchar_t *)(*param_8 + 4)" (( "(") (type_descriptor "wchar_t *" (type_identifier "wchar_t") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*param_8 + 4)" (( "(") (binary_expression "*param_8 + 4" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (+ "+") (number_literal "4")) () ")")))) (; ";")) (expression_statement "*param_8 = (int)pwVar5;" (assignment_expression "*param_8 = (int)pwVar5" (pointer_expression "*param_8" (* "*") (identifier "param_8")) (= "=") (cast_expression "(int)pwVar5" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pwVar5"))) (; ";")) (} "}"))) (expression_statement "iVar6 = 2;" (assignment_expression "iVar6 = 2" (identifier "iVar6") (= "=") (number_literal "2")) (; ";")) (expression_statement "*param_5 = param_3;" (assignment_expression "*param_5 = param_3" (pointer_expression "*param_5" (* "*") (identifier "param_5")) (= "=") (identifier "param_3")) (; ";")) (expression_statement "param_2->__value = local_24[0].__value;" (assignment_expression "param_2->__value = local_24[0].__value" (field_expression "param_2->__value" (identifier "param_2") (-> "->") (field_identifier "__value")) (= "=") (field_expression "local_24[0].__value" (subscript_expression "local_24[0]" (identifier "local_24") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "__value"))) (; ";")) (expression_statement "param_2->__count = local_24[0].__count;" (assignment_expression "param_2->__count = local_24[0].__count" (field_expression "param_2->__count" (identifier "param_2") (-> "->") (field_identifier "__count")) (= "=") (field_expression "local_24[0].__count" (subscript_expression "local_24[0]" (identifier "local_24") ([ "[") (number_literal "0") (] "]")) (. ".") (field_identifier "__count"))) (; ";")) (expression_statement "param_3 = *param_5;" (assignment_expression "param_3 = *param_5" (identifier "param_3") (= "=") (pointer_expression "*param_5" (* "*") (identifier "param_5"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (; ";"))) (labeled_statement "LAB_0027b318:\n  iVar6 = 0;" (statement_identifier "LAB_0027b318") (: ":") (expression_statement "iVar6 = 0;" (assignment_expression "iVar6 = 0" (identifier "iVar6") (= "=") (number_literal "0")) (; ";"))) (expression_statement "param_3 = pcVar7;" (assignment_expression "param_3 = pcVar7" (identifier "param_3") (= "=") (identifier "pcVar7")) (; ";")) (goto_statement "goto joined_r0x0027b200;" (goto "goto") (statement_identifier "joined_r0x0027b200") (; ";")) (} "}")))

/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */
/* std::codecvt<wchar_t, char, __mbstate_t>::do_in(__mbstate_t&, char const*, char const*, char
   const*&, wchar_t*, wchar_t*, wchar_t*&) const */

int __thiscall
std::codecvt<type_2,char,__mbstate_t>::do_in
          (codecvt<type_2,char,__mbstate_t> *var_2,__mbstate_t *param_1,char *var_4,char *var_3,
          char **param_4,type_2 *param_5,type_2 *var_5,type_2 **param_7)

{
  type_2 *var_13;
  type_1 uVar2;
  char *var_9;
  size_t var_11;
  type_2 *var_6;
  int var_7;
  char *var_12;
  type_3 local_24 [2];
  type_1 uStack_14;
  
  var_7 = 0;
  uStack_14 = 0x27b1bb;
  local_24[0].__value = param_1->__value;
  local_24[0].__count = param_1->__count;
  uVar2 = var_1(*(type_1 *)(var_2 + 8));
  *param_4 = var_4;
  *param_7 = param_5;
joined_r0x0027b200:
  do {
    if (((var_3 <= var_4) || (var_6 = *param_7, var_5 <= var_6)) || (var_7 != 0)) {
LAB_0027b295:
      var_1(uVar2);
      return var_7;
    }
    while( true ) {
      var_11 = (int)var_3 - (int)var_4;
      var_9 = (char *)var_8(var_4,0,var_11);
      var_12 = var_3;
      if (var_9 != (char *)0x0) {
        var_11 = (int)var_9 - (int)var_4;
        var_12 = var_9;
      }
      var_11 = var_10(var_6,param_4,var_11,(int)var_5 - (int)var_6 >> 2,param_1);
      if (var_11 == 0xffffffff) break;
      var_4 = *param_4;
      var_13 = *param_7 + var_11;
      if ((var_4 < var_12) && (var_4 != (char *)0x0)) {
        *param_7 = var_13;
        var_7 = 1;
        goto joined_r0x0027b200;
      }
      *param_4 = var_12;
      *param_7 = var_13;
      if (var_3 <= var_12) goto LAB_0027b318;
      if (var_5 <= var_13) {
        var_7 = 1;
        goto LAB_0027b295;
      }
      var_4 = var_12 + 1;
      local_24[0].__count = param_1->__count;
      local_24[0].__value = param_1->__value;
      var_6 = var_13 + 1;
      *param_4 = var_4;
      *param_7 = var_6;
      *var_13 = L'\0';
      if ((var_3 <= var_4) || (var_5 <= var_6)) {
        var_7 = 0;
        goto LAB_0027b295;
      }
    }
    var_6 = *param_7;
    while (var_11 = var_14(var_6,var_4,(int)var_3 - (int)var_4,local_24), 1 < var_11 + 2) {
      var_4 = var_4 + var_11;
      var_6 = *param_7 + 1;
      *param_7 = var_6;
    }
    var_7 = 2;
    *param_4 = var_4;
    param_1->__value = local_24[0].__value;
    param_1->__count = local_24[0].__count;
    var_4 = *param_4;
  } while( true );
LAB_0027b318:
  var_7 = 0;
  var_4 = var_12;
  goto joined_r0x0027b200;
}


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

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

int MASKED(int param_1,mbstate_t *param_2,char *param_3,char *param_4,char **param_5,
                int param_6,wchar_t *param_7,int *param_8)

{
  wchar_t *pwVar1;
  undefined4 uVar2;
  char *pcVar3;
  size_t sVar4;
  wchar_t *pwVar5;
  int iVar6;
  char *pcVar7;
  mbstate_t local_24 [2];
  undefined4 uStack_14;
  
  iVar6 = 0;
  uStack_14 = 0x27b1bb;
  local_24[0].__value = param_2->__value;
  local_24[0].__count = param_2->__count;
  uVar2 = __uselocale(*(undefined4 *)(param_1 + 8));
  *param_5 = param_3;
  *param_8 = param_6;
joined_r0x0027b200:
  do {
    if (((param_4 <= param_3) || (pwVar5 = (wchar_t *)*param_8, param_7 <= pwVar5)) || (iVar6 != 0))
    {
LAB_0027b295:
      __uselocale(uVar2);
      return iVar6;
    }
    while( true ) {
      sVar4 = (int)param_4 - (int)param_3;
      pcVar3 = (char *)memchr(param_3,0,sVar4);
      pcVar7 = param_4;
      if (pcVar3 != (char *)0x0) {
        sVar4 = (int)pcVar3 - (int)param_3;
        pcVar7 = pcVar3;
      }
      sVar4 = mbsnrtowcs(pwVar5,param_5,sVar4,(int)param_7 - (int)pwVar5 >> 2,param_2);
      if (sVar4 == 0xffffffff) break;
      param_3 = *param_5;
      pwVar1 = (wchar_t *)(*param_8 + sVar4 * 4);
      if ((param_3 < pcVar7) && (param_3 != (char *)0x0)) {
        *param_8 = (int)pwVar1;
        iVar6 = 1;
        goto joined_r0x0027b200;
      }
      *param_5 = pcVar7;
      *param_8 = (int)pwVar1;
      if (param_4 <= pcVar7) goto LAB_0027b318;
      if (param_7 <= pwVar1) {
        iVar6 = 1;
        goto LAB_0027b295;
      }
      param_3 = pcVar7 + 1;
      local_24[0].__count = param_2->__count;
      local_24[0].__value = param_2->__value;
      pwVar5 = pwVar1 + 1;
      *param_5 = param_3;
      *param_8 = (int)pwVar5;
      *pwVar1 = L'\0';
      if ((param_4 <= param_3) || (param_7 <= pwVar5)) {
        iVar6 = 0;
        goto LAB_0027b295;
      }
    }
    pwVar5 = (wchar_t *)*param_8;
    while (sVar4 = mbrtowc(pwVar5,param_3,(int)param_4 - (int)param_3,local_24), 1 < sVar4 + 2) {
      param_3 = param_3 + sVar4;
      pwVar5 = (wchar_t *)(*param_8 + 4);
      *param_8 = (int)pwVar5;
    }
    iVar6 = 2;
    *param_5 = param_3;
    param_2->__value = local_24[0].__value;
    param_2->__count = local_24[0].__count;
    param_3 = *param_5;
  } while( true );
LAB_0027b318:
  iVar6 = 0;
  param_3 = pcVar7;
  goto joined_r0x0027b200;
}

