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

int mbsnwidth(char *string,size_t nbytes,int flags)

{
  byte *pbVar1;
  int iVar2;
  byte bVar3;
  ushort uVar4;
  uint uVar5;
  size_t sVar6;
  size_t sVar7;
  int iVar8;
  ushort **ppuVar9;
  byte *pbVar10;
  int in_GS_OFFSET;
  wchar_t wc;
  mbstate_t mbstate;
  
  iVar2 = *(int *)(in_GS_OFFSET + 0x14);
  pbVar1 = (byte *)(string + nbytes);
  sVar6 = __ctype_get_mb_cur_max();
  if (sVar6 < 2) {
    if (string < pbVar1) {
      ppuVar9 = __ctype_b_loc();
      uVar5 = flags & 2U;
      if ((flags & 2U) == 0) {
        do {
          nbytes = uVar5;
          pbVar10 = (byte *)string + 1;
          uVar4 = (*ppuVar9)[(byte)*string];
          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {
            if (nbytes == 0x7fffffff) break;
            nbytes = nbytes + 1;
          }
          uVar5 = nbytes;
          string = (char *)pbVar10;
        } while (pbVar1 != pbVar10);
      }
      else {
        sVar7 = 0;
        do {
          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)
          goto LAB_00061e39;
          if (sVar7 == 0x7fffffff) goto LAB_00061f60;
          sVar7 = sVar7 + 1;
        } while (nbytes != sVar7);
      }
      goto LAB_00061e40;
    }
  }
  else if (string < pbVar1) {
    nbytes = 0;
LAB_00061d3b:
    bVar3 = *string;
    if ((char)bVar3 < '@') {
      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;
      goto LAB_00061d2b;
    }
    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))
    goto LAB_00061d2b;
LAB_00061d51:
    mbstate.__count = 0;
    mbstate.__value.__wch = 0;
    if ((flags & 2U) == 0) {
      do {
        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);
        if (sVar7 == 0xffffffff) goto LAB_00061f30;
        if (sVar7 == 0xfffffffe) goto LAB_00061f48;
        if (sVar7 == 0) {
          sVar7 = 1;
        }
        iVar8 = wcwidth(wc);
        if (iVar8 < 0) {
          iVar8 = iswcntrl(wc);
          if (iVar8 == 0) {
            if (nbytes == 0x7fffffff) goto LAB_00061f60;
            nbytes = nbytes + 1;
          }
        }
        else {
          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;
          nbytes = nbytes + iVar8;
        }
        string = (char *)((byte *)string + sVar7);
        iVar8 = mbsinit((mbstate_t *)&mbstate);
      } while (iVar8 == 0);
    }
    else {
      do {
        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);
        if (sVar7 == 0xffffffff) goto LAB_00061f30;
        if (sVar7 == 0xfffffffe) goto LAB_00061f48;
        if (sVar7 == 0) {
          sVar7 = 1;
        }
        iVar8 = wcwidth(wc);
        if (iVar8 < 0) {
          nbytes = 0xffffffff;
          goto LAB_00061e40;
        }
        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;
        nbytes = nbytes + iVar8;
        string = (char *)((byte *)string + sVar7);
        iVar8 = mbsinit((mbstate_t *)&mbstate);
      } while (iVar8 == 0);
    }
    goto LAB_00061d31;
  }
  nbytes = 0;
  goto LAB_00061e40;
LAB_00061f30:
  if ((flags & 1U) != 0) goto LAB_00061e39;
LAB_00061d2b:
  string = (char *)((byte *)string + 1);
  nbytes = nbytes + 1;
LAB_00061d31:
  if (pbVar1 <= string) goto LAB_00061e40;
  goto LAB_00061d3b;
LAB_00061f48:
  if ((flags & 1U) != 0) goto LAB_00061e39;
  nbytes = nbytes + 1;
  string = (char *)pbVar1;
  goto LAB_00061d31;
LAB_00061e39:
  nbytes = 0xffffffff;
  goto LAB_00061e40;
LAB_00061f60:
  nbytes = 0x7fffffff;
LAB_00061e40:
  if (iVar2 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    __stack_chk_fail_local();
  }
  return nbytes;
}



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

uint FUN_00061cc0(byte *param_1,uint param_2,uint param_3)

{
  byte *pbVar1;
  byte bVar2;
  ushort uVar3;
  size_t sVar4;
  uint uVar5;
  int iVar6;
  int iVar7;
  ushort **ppuVar8;
  byte *pbVar9;
  int in_GS_OFFSET;
  wchar_t local_2c;
  mbstate_t local_28;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x61cc9;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  pbVar1 = param_1 + param_2;
  sVar4 = __ctype_get_mb_cur_max();
  if (sVar4 < 2) {
    if (param_1 < pbVar1) {
      ppuVar8 = __ctype_b_loc();
      uVar5 = param_3 & 2;
      if ((param_3 & 2) == 0) {
        do {
          param_2 = uVar5;
          pbVar9 = param_1 + 1;
          uVar3 = (*ppuVar8)[*param_1];
          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {
            if (param_2 == 0x7fffffff) break;
            param_2 = param_2 + 1;
          }
          uVar5 = param_2;
          param_1 = pbVar9;
        } while (pbVar1 != pbVar9);
      }
      else {
        uVar5 = 0;
        do {
          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)
          goto LAB_00061e39;
          if (uVar5 == 0x7fffffff) goto LAB_00061f60;
          uVar5 = uVar5 + 1;
        } while (param_2 != uVar5);
      }
      goto LAB_00061e40;
    }
  }
  else if (param_1 < pbVar1) {
    param_2 = 0;
LAB_00061d3b:
    bVar2 = *param_1;
    if ((char)bVar2 < '@') {
      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;
      goto LAB_00061d2b;
    }
    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))
    goto LAB_00061d2b;
LAB_00061d51:
    local_28.__count = 0;
    local_28.__value.__wch = 0;
    if ((param_3 & 2) == 0) {
      do {
        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);
        if (iVar6 == -1) goto LAB_00061f30;
        if (iVar6 == -2) goto LAB_00061f48;
        if (iVar6 == 0) {
          iVar6 = 1;
        }
        iVar7 = wcwidth(local_2c);
        if (iVar7 < 0) {
          iVar7 = iswcntrl(local_2c);
          if (iVar7 == 0) {
            if (param_2 == 0x7fffffff) goto LAB_00061f60;
            param_2 = param_2 + 1;
          }
        }
        else {
          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;
          param_2 = param_2 + iVar7;
        }
        param_1 = param_1 + iVar6;
        iVar6 = mbsinit(&local_28);
      } while (iVar6 == 0);
    }
    else {
      do {
        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);
        if (iVar6 == -1) goto LAB_00061f30;
        if (iVar6 == -2) goto LAB_00061f48;
        if (iVar6 == 0) {
          iVar6 = 1;
        }
        iVar7 = wcwidth(local_2c);
        if (iVar7 < 0) {
          param_2 = 0xffffffff;
          goto LAB_00061e40;
        }
        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;
        param_2 = param_2 + iVar7;
        param_1 = param_1 + iVar6;
        iVar6 = mbsinit(&local_28);
      } while (iVar6 == 0);
    }
    goto LAB_00061d31;
  }
  param_2 = 0;
  goto LAB_00061e40;
LAB_00061f30:
  if ((param_3 & 1) != 0) goto LAB_00061e39;
LAB_00061d2b:
  param_1 = param_1 + 1;
  param_2 = param_2 + 1;
LAB_00061d31:
  if (pbVar1 <= param_1) goto LAB_00061e40;
  goto LAB_00061d3b;
LAB_00061f48:
  if ((param_3 & 1) != 0) goto LAB_00061e39;
  param_2 = param_2 + 1;
  param_1 = pbVar1;
  goto LAB_00061d31;
LAB_00061e39:
  param_2 = 0xffffffff;
  goto LAB_00061e40;
LAB_00061f60:
  param_2 = 0x7fffffff;
LAB_00061e40:
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_0006c970();
  }
  return param_2;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x00013d10
ADD EBX,0x34337
SUB ESP,0x3c
MOV EAX,GS:[0x14]
MOV dword ptr [ESP + 0x2c],EAX
XOR EAX,EAX
MOV EDI,dword ptr [ESP + 0x50]
MOV ESI,dword ptr [ESP + 0x54]
MOV EBP,dword ptr [ESP + 0x58]
LEA EAX,[EDI + ESI*0x1]
MOV dword ptr [ESP + 0x10],EAX
CALL 0x00013240
CMP EAX,0x1
JBE 0x00061ee0
CMP EDI,dword ptr [ESP + 0x10]
JNC 0x00061f6a
MOV EAX,EBP
AND EBP,0x1
AND EAX,0x2
MOV dword ptr [ESP + 0x1c],EBP
XOR EBP,EBP
MOV dword ptr [ESP + 0x18],EAX
JMP 0x00061d3b
CMP AL,0x25
JGE 0x00061d2b
SUB EAX,0x20
CMP AL,0x3
JA 0x00061d51
ADD EDI,0x1
ADD EBP,0x1
CMP EDI,dword ptr [ESP + 0x10]
JNC 0x00061e40
MOVZX EAX,byte ptr [EDI]
CMP AL,0x3f
JLE 0x00061d20
CMP AL,0x41
JL 0x00061d51
CMP AL,0x5f
JLE 0x00061d2b
SUB EAX,0x61
CMP AL,0x1d
JBE 0x00061d2b
MOV ECX,dword ptr [ESP + 0x18]
LEA EAX,[ESP + 0x24]
MOV dword ptr [ESP + 0x24],0x0
MOV dword ptr [ESP + 0xc],EAX
LEA EAX,[ESP + 0x20]
TEST ECX,ECX
MOV dword ptr [ESP + 0x28],0x0
MOV dword ptr [ESP + 0x14],EAX
JZ 0x00061da6
JMP 0x00061e8a
MOV ECX,0x7fffffff
SUB ECX,EBP
CMP ECX,EAX
JL 0x00061f60
ADD EBP,EAX
SUB ESP,0xc
ADD EDI,ESI
PUSH dword ptr [ESP + 0x18]
CALL 0x00013110
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x00061d31
PUSH dword ptr [ESP + 0xc]
MOV EAX,dword ptr [ESP + 0x14]
SUB EAX,EDI
PUSH EAX
PUSH EDI
PUSH dword ptr [ESP + 0x20]
CALL 0x00068790
ADD ESP,0x10
MOV ESI,EAX
CMP EAX,-0x1
JZ 0x00061f30
CMP EAX,-0x2
JZ 0x00061f48
TEST EAX,EAX
MOV EAX,0x1
CMOVZ ESI,EAX
SUB ESP,0xc
PUSH dword ptr [ESP + 0x2c]
CALL 0x000130c0
ADD ESP,0x10
TEST EAX,EAX
JNS 0x00061d80
SUB ESP,0xc
PUSH dword ptr [ESP + 0x2c]
CALL 0x000131d0
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x00061d91
CMP EBP,0x7fffffff
JZ 0x00061f60
ADD EBP,0x1
JMP 0x00061d91
MOV EBP,ESI
XOR EAX,EAX
JMP 0x00061e2e
CMP EAX,0x7fffffff
JZ 0x00061f60
ADD EAX,0x1
CMP ESI,EAX
JZ 0x00061e40
MOVZX ECX,byte ptr [EDI + EAX*0x1]
TEST byte ptr [EDX + ECX*0x2 + 0x1],0x40
JNZ 0x00061e1c
MOV EBP,0xffffffff
NOP
MOV EDX,dword ptr [ESP + 0x2c]
XOR EDX,dword ptr GS:[0x14]
MOV EAX,EBP
JNZ 0x00061f71
ADD ESP,0x3c
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV ECX,0x7fffffff
SUB ECX,EBP
CMP EAX,ECX
JG 0x00061f60
SUB ESP,0xc
ADD EBP,EAX
ADD EDI,ESI
PUSH dword ptr [ESP + 0x18]
CALL 0x00013110
ADD ESP,0x10
TEST EAX,EAX
JNZ 0x00061d31
PUSH dword ptr [ESP + 0xc]
MOV EAX,dword ptr [ESP + 0x14]
SUB EAX,EDI
PUSH EAX
PUSH EDI
PUSH dword ptr [ESP + 0x20]
CALL 0x00068790
ADD ESP,0x10
MOV ESI,EAX
CMP EAX,-0x1
JZ 0x00061f30
CMP EAX,-0x2
JZ 0x00061f48
TEST EAX,EAX
MOV EAX,0x1
CMOVZ ESI,EAX
SUB ESP,0xc
PUSH dword ptr [ESP + 0x2c]
CALL 0x000130c0
ADD ESP,0x10
TEST EAX,EAX
JNS 0x00061e60
MOV EBP,0xffffffff
JMP 0x00061e40
CMP EDI,dword ptr [ESP + 0x10]
JNC 0x00061f6a
CALL 0x00013600
AND EBP,0x2
MOV ECX,dword ptr [ESP + 0x10]
MOV EDX,dword ptr [EAX]
JNZ 0x00061e16
NOP
ADD EDI,0x1
MOVZX EAX,byte ptr [EDI + -0x1]
MOVZX EAX,word ptr [EDX + EAX*0x2]
TEST AH,0x40
JNZ 0x00061f14
TEST AL,0x2
JNZ 0x00061f23
CMP EBP,0x7fffffff
JZ 0x00061e40
ADD EBP,0x1
CMP ECX,EDI
JNZ 0x00061f00
JMP 0x00061e40
MOV EDX,dword ptr [ESP + 0x1c]
TEST EDX,EDX
JZ 0x00061d2b
JMP 0x00061e39
MOV EAX,dword ptr [ESP + 0x1c]
TEST EAX,EAX
JNZ 0x00061e39
ADD EBP,0x1
MOV EDI,dword ptr [ESP + 0x10]
JMP 0x00061d31
MOV EBP,0x7fffffff
JMP 0x00061e40
XOR EBP,EBP
JMP 0x00061e40
CALL 0x0006c970
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nuint FUN_00061cc0(byte *param_1,uint param_2,uint param_3)\n\n{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0006c970();\n  }\n  return param_2;\n}\n\n" comment (function_definition "uint FUN_00061cc0(byte *param_1,uint param_2,uint param_3)\n\n{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0006c970();\n  }\n  return param_2;\n}" type_identifier (function_declarator "FUN_00061cc0(byte *param_1,uint param_2,uint param_3)" identifier (parameter_list "(byte *param_1,uint param_2,uint param_3)" ( (parameter_declaration "byte *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "uint param_2" type_identifier identifier) , (parameter_declaration "uint param_3" type_identifier identifier) ))) (compound_statement "{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0006c970();\n  }\n  return param_2;\n}" { (declaration "byte *pbVar1;" type_identifier (pointer_declarator "*pbVar1" * identifier) ;) (declaration "byte bVar2;" type_identifier identifier ;) (declaration "ushort uVar3;" type_identifier identifier ;) (declaration "size_t sVar4;" primitive_type identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "int iVar7;" primitive_type identifier ;) (declaration "ushort **ppuVar8;" type_identifier (pointer_declarator "**ppuVar8" * (pointer_declarator "*ppuVar8" * identifier)) ;) (declaration "byte *pbVar9;" type_identifier (pointer_declarator "*pbVar9" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "wchar_t local_2c;" type_identifier identifier ;) (declaration "mbstate_t local_28;" type_identifier identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x61cc9;" (assignment_expression "uStack_14 = 0x61cc9" identifier = number_literal) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "pbVar1 = param_1 + param_2;" (assignment_expression "pbVar1 = param_1 + param_2" identifier = (binary_expression "param_1 + param_2" identifier + identifier)) ;) (expression_statement "sVar4 = __ctype_get_mb_cur_max();" (assignment_expression "sVar4 = __ctype_get_mb_cur_max()" identifier = (call_expression "__ctype_get_mb_cur_max()" identifier (argument_list "()" ( )))) ;) (if_statement "if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" if (parenthesized_expression "(sVar4 < 2)" ( (binary_expression "sVar4 < 2" identifier < number_literal) )) (compound_statement "{\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }" { (if_statement "if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }" if (parenthesized_expression "(param_1 < pbVar1)" ( (binary_expression "param_1 < pbVar1" identifier < identifier) )) (compound_statement "{\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }" { (expression_statement "ppuVar8 = __ctype_b_loc();" (assignment_expression "ppuVar8 = __ctype_b_loc()" identifier = (call_expression "__ctype_b_loc()" identifier (argument_list "()" ( )))) ;) (expression_statement "uVar5 = param_3 & 2;" (assignment_expression "uVar5 = param_3 & 2" identifier = (binary_expression "param_3 & 2" identifier & number_literal)) ;) (if_statement "if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" if (parenthesized_expression "((param_3 & 2) == 0)" ( (binary_expression "(param_3 & 2) == 0" (parenthesized_expression "(param_3 & 2)" ( (binary_expression "param_3 & 2" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }" { (do_statement "do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);" do (compound_statement "{\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        }" { (expression_statement "param_2 = uVar5;" (assignment_expression "param_2 = uVar5" identifier = identifier) ;) (expression_statement "pbVar9 = param_1 + 1;" (assignment_expression "pbVar9 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "uVar3 = (*ppuVar8)[*param_1];" (assignment_expression "uVar3 = (*ppuVar8)[*param_1]" identifier = (subscript_expression "(*ppuVar8)[*param_1]" (parenthesized_expression "(*ppuVar8)" ( (pointer_expression "*ppuVar8" * identifier) )) [ (pointer_expression "*param_1" * identifier) ])) ;) (if_statement "if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }" if (parenthesized_expression "(((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0))" ( (binary_expression "((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)" (parenthesized_expression "((uVar3 & 0x4000) != 0)" ( (binary_expression "(uVar3 & 0x4000) != 0" (parenthesized_expression "(uVar3 & 0x4000)" ( (binary_expression "uVar3 & 0x4000" identifier & number_literal) )) != number_literal) )) || (parenthesized_expression "((uVar3 & 2) == 0)" ( (binary_expression "(uVar3 & 2) == 0" (parenthesized_expression "(uVar3 & 2)" ( (binary_expression "uVar3 & 2" identifier & number_literal) )) == number_literal) ))) )) (compound_statement "{\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }" { (if_statement "if (param_2 == 0x7fffffff) break;" if (parenthesized_expression "(param_2 == 0x7fffffff)" ( (binary_expression "param_2 == 0x7fffffff" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) })) (expression_statement "uVar5 = param_2;" (assignment_expression "uVar5 = param_2" identifier = identifier) ;) (expression_statement "param_1 = pbVar9;" (assignment_expression "param_1 = pbVar9" identifier = identifier) ;) }) while (parenthesized_expression "(pbVar1 != pbVar9)" ( (binary_expression "pbVar1 != pbVar9" identifier != identifier) )) ;) }) (else_clause "else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" else (compound_statement "{\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" { (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (do_statement "do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);" do (compound_statement "{\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        }" { (if_statement "if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;" if (parenthesized_expression "((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)" ( (binary_expression "(*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0" (parenthesized_expression "(*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40)" ( (binary_expression "*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" * (cast_expression "(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" ( (binary_expression "(int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1" (binary_expression "(int)*ppuVar8 + (uint)param_1[uVar5] * 2" (cast_expression "(int)*ppuVar8" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*ppuVar8" * identifier)) + (binary_expression "(uint)param_1[uVar5] * 2" (cast_expression "(uint)param_1[uVar5]" ( (type_descriptor "uint" type_identifier) ) (subscript_expression "param_1[uVar5]" identifier [ identifier ])) * number_literal)) + number_literal) )))) & number_literal) )) == number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;)) (if_statement "if (uVar5 == 0x7fffffff) goto LAB_00061f60;" if (parenthesized_expression "(uVar5 == 0x7fffffff)" ( (binary_expression "uVar5 == 0x7fffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" identifier = (binary_expression "uVar5 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_2 != uVar5)" ( (binary_expression "param_2 != uVar5" identifier != identifier) )) ;) }))) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) })) }) (else_clause "else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" else (if_statement "if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" if (parenthesized_expression "(param_1 < pbVar1)" ( (binary_expression "param_1 < pbVar1" identifier < identifier) )) (compound_statement "{\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" { (expression_statement "param_2 = 0;" (assignment_expression "param_2 = 0" identifier = number_literal) ;) (labeled_statement "LAB_00061d3b:\n    bVar2 = *param_1;" statement_identifier : (expression_statement "bVar2 = *param_1;" (assignment_expression "bVar2 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;)) (if_statement "if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" if (parenthesized_expression "((char)bVar2 < '@')" ( (binary_expression "(char)bVar2 < '@'" (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'@'" ' character ')) )) (compound_statement "{\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" { (if_statement "if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;" if (parenthesized_expression "(((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20)))" ( (binary_expression "((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))" (parenthesized_expression "((char)bVar2 < '%')" ( (binary_expression "(char)bVar2 < '%'" (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'%'" ' character ')) )) && (parenthesized_expression "(3 < (byte)(bVar2 - 0x20))" ( (binary_expression "3 < (byte)(bVar2 - 0x20)" number_literal < (call_expression "(byte)(bVar2 - 0x20)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(bVar2 - 0x20)" ( (binary_expression "bVar2 - 0x20" identifier - number_literal) )))) ))) )) (goto_statement "goto LAB_00061d51;" goto statement_identifier ;)) (goto_statement "goto LAB_00061d2b;" goto statement_identifier ;) })) (if_statement "if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;" if (parenthesized_expression "(('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))" ( (binary_expression "('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)))" (parenthesized_expression "('@' < (char)bVar2)" ( (binary_expression "'@' < (char)bVar2" (char_literal "'@'" ' character ') < (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier)) )) && (parenthesized_expression "(((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)))" ( (parenthesized_expression "((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))" ( (binary_expression "(char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)" (binary_expression "(char)bVar2 < '`'" (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'`'" ' character ')) || (parenthesized_expression "((byte)(bVar2 + 0x9f) < 0x1e)" ( (binary_expression "(byte)(bVar2 + 0x9f) < 0x1e" (call_expression "(byte)(bVar2 + 0x9f)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(bVar2 + 0x9f)" ( (binary_expression "bVar2 + 0x9f" identifier + number_literal) ))) < number_literal) ))) )) ))) )) (goto_statement "goto LAB_00061d2b;" goto statement_identifier ;)) (labeled_statement "LAB_00061d51:\n    local_28.__count = 0;" statement_identifier : (expression_statement "local_28.__count = 0;" (assignment_expression "local_28.__count = 0" (field_expression "local_28.__count" identifier . field_identifier) = number_literal) ;)) (expression_statement "local_28.__value.__wch = 0;" (assignment_expression "local_28.__value.__wch = 0" (field_expression "local_28.__value.__wch" (field_expression "local_28.__value" identifier . field_identifier) . field_identifier) = number_literal) ;) (if_statement "if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" if (parenthesized_expression "((param_3 & 2) == 0)" ( (binary_expression "(param_3 & 2) == 0" (parenthesized_expression "(param_3 & 2)" ( (binary_expression "param_3 & 2" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" { (do_statement "do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);" do (compound_statement "{\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      }" { (expression_statement "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);" (assignment_expression "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier = (call_expression "FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier (argument_list "(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" ( (pointer_expression "&local_2c" & identifier) , identifier , (binary_expression "(int)pbVar1 - (int)param_1" (cast_expression "(int)pbVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_1" ( (type_descriptor "int" primitive_type) ) identifier)) , (pointer_expression "&local_28" & identifier) )))) ;) (if_statement "if (iVar6 == -1) goto LAB_00061f30;" if (parenthesized_expression "(iVar6 == -1)" ( (binary_expression "iVar6 == -1" identifier == number_literal) )) (goto_statement "goto LAB_00061f30;" goto statement_identifier ;)) (if_statement "if (iVar6 == -2) goto LAB_00061f48;" if (parenthesized_expression "(iVar6 == -2)" ( (binary_expression "iVar6 == -2" identifier == number_literal) )) (goto_statement "goto LAB_00061f48;" goto statement_identifier ;)) (if_statement "if (iVar6 == 0) {\n          iVar6 = 1;\n        }" if (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) (compound_statement "{\n          iVar6 = 1;\n        }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) })) (expression_statement "iVar7 = wcwidth(local_2c);" (assignment_expression "iVar7 = wcwidth(local_2c)" identifier = (call_expression "wcwidth(local_2c)" identifier (argument_list "(local_2c)" ( identifier )))) ;) (if_statement "if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" if (parenthesized_expression "(iVar7 < 0)" ( (binary_expression "iVar7 < 0" identifier < number_literal) )) (compound_statement "{\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }" { (expression_statement "iVar7 = iswcntrl(local_2c);" (assignment_expression "iVar7 = iswcntrl(local_2c)" identifier = (call_expression "iswcntrl(local_2c)" identifier (argument_list "(local_2c)" ( identifier )))) ;) (if_statement "if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }" if (parenthesized_expression "(iVar7 == 0)" ( (binary_expression "iVar7 == 0" identifier == number_literal) )) (compound_statement "{\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }" { (if_statement "if (param_2 == 0x7fffffff) goto LAB_00061f60;" if (parenthesized_expression "(param_2 == 0x7fffffff)" ( (binary_expression "param_2 == 0x7fffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) })) }) (else_clause "else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" else (compound_statement "{\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" { (if_statement "if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;" if (parenthesized_expression "((int)(0x7fffffff - param_2) < iVar7)" ( (binary_expression "(int)(0x7fffffff - param_2) < iVar7" (cast_expression "(int)(0x7fffffff - param_2)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(0x7fffffff - param_2)" ( (binary_expression "0x7fffffff - param_2" number_literal - identifier) ))) < identifier) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "param_2 = param_2 + iVar7;" (assignment_expression "param_2 = param_2 + iVar7" identifier = (binary_expression "param_2 + iVar7" identifier + identifier)) ;) }))) (expression_statement "param_1 = param_1 + iVar6;" (assignment_expression "param_1 = param_1 + iVar6" identifier = (binary_expression "param_1 + iVar6" identifier + identifier)) ;) (expression_statement "iVar6 = mbsinit(&local_28);" (assignment_expression "iVar6 = mbsinit(&local_28)" identifier = (call_expression "mbsinit(&local_28)" identifier (argument_list "(&local_28)" ( (pointer_expression "&local_28" & identifier) )))) ;) }) while (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) ;) }) (else_clause "else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" else (compound_statement "{\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" { (do_statement "do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);" do (compound_statement "{\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      }" { (expression_statement "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);" (assignment_expression "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier = (call_expression "FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier (argument_list "(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" ( (pointer_expression "&local_2c" & identifier) , identifier , (binary_expression "(int)pbVar1 - (int)param_1" (cast_expression "(int)pbVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_1" ( (type_descriptor "int" primitive_type) ) identifier)) , (pointer_expression "&local_28" & identifier) )))) ;) (if_statement "if (iVar6 == -1) goto LAB_00061f30;" if (parenthesized_expression "(iVar6 == -1)" ( (binary_expression "iVar6 == -1" identifier == number_literal) )) (goto_statement "goto LAB_00061f30;" goto statement_identifier ;)) (if_statement "if (iVar6 == -2) goto LAB_00061f48;" if (parenthesized_expression "(iVar6 == -2)" ( (binary_expression "iVar6 == -2" identifier == number_literal) )) (goto_statement "goto LAB_00061f48;" goto statement_identifier ;)) (if_statement "if (iVar6 == 0) {\n          iVar6 = 1;\n        }" if (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) (compound_statement "{\n          iVar6 = 1;\n        }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) })) (expression_statement "iVar7 = wcwidth(local_2c);" (assignment_expression "iVar7 = wcwidth(local_2c)" identifier = (call_expression "wcwidth(local_2c)" identifier (argument_list "(local_2c)" ( identifier )))) ;) (if_statement "if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }" if (parenthesized_expression "(iVar7 < 0)" ( (binary_expression "iVar7 < 0" identifier < number_literal) )) (compound_statement "{\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }" { (expression_statement "param_2 = 0xffffffff;" (assignment_expression "param_2 = 0xffffffff" identifier = number_literal) ;) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) })) (if_statement "if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;" if (parenthesized_expression "((int)(0x7fffffff - param_2) < iVar7)" ( (binary_expression "(int)(0x7fffffff - param_2) < iVar7" (cast_expression "(int)(0x7fffffff - param_2)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(0x7fffffff - param_2)" ( (binary_expression "0x7fffffff - param_2" number_literal - identifier) ))) < identifier) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "param_2 = param_2 + iVar7;" (assignment_expression "param_2 = param_2 + iVar7" identifier = (binary_expression "param_2 + iVar7" identifier + identifier)) ;) (expression_statement "param_1 = param_1 + iVar6;" (assignment_expression "param_1 = param_1 + iVar6" identifier = (binary_expression "param_1 + iVar6" identifier + identifier)) ;) (expression_statement "iVar6 = mbsinit(&local_28);" (assignment_expression "iVar6 = mbsinit(&local_28)" identifier = (call_expression "mbsinit(&local_28)" identifier (argument_list "(&local_28)" ( (pointer_expression "&local_28" & identifier) )))) ;) }) while (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) ;) }))) (goto_statement "goto LAB_00061d31;" goto statement_identifier ;) })))) (expression_statement "param_2 = 0;" (assignment_expression "param_2 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) (labeled_statement "LAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;" statement_identifier : (if_statement "if ((param_3 & 1) != 0) goto LAB_00061e39;" if (parenthesized_expression "((param_3 & 1) != 0)" ( (binary_expression "(param_3 & 1) != 0" (parenthesized_expression "(param_3 & 1)" ( (binary_expression "param_3 & 1" identifier & number_literal) )) != number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;))) (labeled_statement "LAB_00061d2b:\n  param_1 = param_1 + 1;" statement_identifier : (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;)) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) (labeled_statement "LAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;" statement_identifier : (if_statement "if (pbVar1 <= param_1) goto LAB_00061e40;" if (parenthesized_expression "(pbVar1 <= param_1)" ( (binary_expression "pbVar1 <= param_1" identifier <= identifier) )) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;))) (goto_statement "goto LAB_00061d3b;" goto statement_identifier ;) (labeled_statement "LAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;" statement_identifier : (if_statement "if ((param_3 & 1) != 0) goto LAB_00061e39;" if (parenthesized_expression "((param_3 & 1) != 0)" ( (binary_expression "(param_3 & 1) != 0" (parenthesized_expression "(param_3 & 1)" ( (binary_expression "param_3 & 1" identifier & number_literal) )) != number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;))) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) (expression_statement "param_1 = pbVar1;" (assignment_expression "param_1 = pbVar1" identifier = identifier) ;) (goto_statement "goto LAB_00061d31;" goto statement_identifier ;) (labeled_statement "LAB_00061e39:\n  param_2 = 0xffffffff;" statement_identifier : (expression_statement "param_2 = 0xffffffff;" (assignment_expression "param_2 = 0xffffffff" identifier = number_literal) ;)) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) (labeled_statement "LAB_00061f60:\n  param_2 = 0x7fffffff;" statement_identifier : (expression_statement "param_2 = 0x7fffffff;" (assignment_expression "param_2 = 0x7fffffff" identifier = number_literal) ;)) (labeled_statement "LAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0006c970();\n  }" statement_identifier : (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    FUN_0006c970();\n  }" if (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    FUN_0006c970();\n  }" { comment (expression_statement "FUN_0006c970();" (call_expression "FUN_0006c970()" identifier (argument_list "()" ( ))) ;) }))) (return_statement "return param_2;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nint mbsnwidth(char *string,size_t nbytes,int flags)\n\n{\n  byte *pbVar1;\n  int iVar2;\n  byte bVar3;\n  ushort uVar4;\n  uint uVar5;\n  size_t sVar6;\n  size_t sVar7;\n  int iVar8;\n  ushort **ppuVar9;\n  byte *pbVar10;\n  int in_GS_OFFSET;\n  wchar_t wc;\n  mbstate_t mbstate;\n  \n  iVar2 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = (byte *)(string + nbytes);\n  sVar6 = __ctype_get_mb_cur_max();\n  if (sVar6 < 2) {\n    if (string < pbVar1) {\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (string < pbVar1) {\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  nbytes = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((flags & 1U) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  string = (char *)((byte *)string + 1);\n  nbytes = nbytes + 1;\nLAB_00061d31:\n  if (pbVar1 <= string) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((flags & 1U) != 0) goto LAB_00061e39;\n  nbytes = nbytes + 1;\n  string = (char *)pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  nbytes = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  nbytes = 0x7fffffff;\nLAB_00061e40:\n  if (iVar2 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return nbytes;\n}\n\n" comment comment (function_definition "int mbsnwidth(char *string,size_t nbytes,int flags)\n\n{\n  byte *pbVar1;\n  int iVar2;\n  byte bVar3;\n  ushort uVar4;\n  uint uVar5;\n  size_t sVar6;\n  size_t sVar7;\n  int iVar8;\n  ushort **ppuVar9;\n  byte *pbVar10;\n  int in_GS_OFFSET;\n  wchar_t wc;\n  mbstate_t mbstate;\n  \n  iVar2 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = (byte *)(string + nbytes);\n  sVar6 = __ctype_get_mb_cur_max();\n  if (sVar6 < 2) {\n    if (string < pbVar1) {\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (string < pbVar1) {\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  nbytes = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((flags & 1U) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  string = (char *)((byte *)string + 1);\n  nbytes = nbytes + 1;\nLAB_00061d31:\n  if (pbVar1 <= string) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((flags & 1U) != 0) goto LAB_00061e39;\n  nbytes = nbytes + 1;\n  string = (char *)pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  nbytes = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  nbytes = 0x7fffffff;\nLAB_00061e40:\n  if (iVar2 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return nbytes;\n}" primitive_type (function_declarator "mbsnwidth(char *string,size_t nbytes,int flags)" identifier (parameter_list "(char *string,size_t nbytes,int flags)" ( (parameter_declaration "char *string" primitive_type (pointer_declarator "*string" * identifier)) , (parameter_declaration "size_t nbytes" primitive_type identifier) , (parameter_declaration "int flags" primitive_type identifier) ))) (compound_statement "{\n  byte *pbVar1;\n  int iVar2;\n  byte bVar3;\n  ushort uVar4;\n  uint uVar5;\n  size_t sVar6;\n  size_t sVar7;\n  int iVar8;\n  ushort **ppuVar9;\n  byte *pbVar10;\n  int in_GS_OFFSET;\n  wchar_t wc;\n  mbstate_t mbstate;\n  \n  iVar2 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = (byte *)(string + nbytes);\n  sVar6 = __ctype_get_mb_cur_max();\n  if (sVar6 < 2) {\n    if (string < pbVar1) {\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (string < pbVar1) {\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  nbytes = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((flags & 1U) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  string = (char *)((byte *)string + 1);\n  nbytes = nbytes + 1;\nLAB_00061d31:\n  if (pbVar1 <= string) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((flags & 1U) != 0) goto LAB_00061e39;\n  nbytes = nbytes + 1;\n  string = (char *)pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  nbytes = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  nbytes = 0x7fffffff;\nLAB_00061e40:\n  if (iVar2 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }\n  return nbytes;\n}" { (declaration "byte *pbVar1;" type_identifier (pointer_declarator "*pbVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "byte bVar3;" type_identifier identifier ;) (declaration "ushort uVar4;" type_identifier identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "size_t sVar6;" primitive_type identifier ;) (declaration "size_t sVar7;" primitive_type identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "ushort **ppuVar9;" type_identifier (pointer_declarator "**ppuVar9" * (pointer_declarator "*ppuVar9" * identifier)) ;) (declaration "byte *pbVar10;" type_identifier (pointer_declarator "*pbVar10" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "wchar_t wc;" type_identifier identifier ;) (declaration "mbstate_t mbstate;" type_identifier identifier ;) (expression_statement "iVar2 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "iVar2 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "pbVar1 = (byte *)(string + nbytes);" (assignment_expression "pbVar1 = (byte *)(string + nbytes)" identifier = (cast_expression "(byte *)(string + nbytes)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(string + nbytes)" ( (binary_expression "string + nbytes" identifier + identifier) )))) ;) (expression_statement "sVar6 = __ctype_get_mb_cur_max();" (assignment_expression "sVar6 = __ctype_get_mb_cur_max()" identifier = (call_expression "__ctype_get_mb_cur_max()" identifier (argument_list "()" ( )))) ;) (if_statement "if (sVar6 < 2) {\n    if (string < pbVar1) {\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (string < pbVar1) {\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }" if (parenthesized_expression "(sVar6 < 2)" ( (binary_expression "sVar6 < 2" identifier < number_literal) )) (compound_statement "{\n    if (string < pbVar1) {\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }\n  }" { (if_statement "if (string < pbVar1) {\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }" if (parenthesized_expression "(string < pbVar1)" ( (binary_expression "string < pbVar1" identifier < identifier) )) (compound_statement "{\n      ppuVar9 = __ctype_b_loc();\n      uVar5 = flags & 2U;\n      if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }\n      goto LAB_00061e40;\n    }" { (expression_statement "ppuVar9 = __ctype_b_loc();" (assignment_expression "ppuVar9 = __ctype_b_loc()" identifier = (call_expression "__ctype_b_loc()" identifier (argument_list "()" ( )))) ;) (expression_statement "uVar5 = flags & 2U;" (assignment_expression "uVar5 = flags & 2U" identifier = (binary_expression "flags & 2U" identifier & number_literal)) ;) (if_statement "if ((flags & 2U) == 0) {\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }\n      else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }" if (parenthesized_expression "((flags & 2U) == 0)" ( (binary_expression "(flags & 2U) == 0" (parenthesized_expression "(flags & 2U)" ( (binary_expression "flags & 2U" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n        do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);\n      }" { (do_statement "do {\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        } while (pbVar1 != pbVar10);" do (compound_statement "{\n          nbytes = uVar5;\n          pbVar10 = (byte *)string + 1;\n          uVar4 = (*ppuVar9)[(byte)*string];\n          if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }\n          uVar5 = nbytes;\n          string = (char *)pbVar10;\n        }" { (expression_statement "nbytes = uVar5;" (assignment_expression "nbytes = uVar5" identifier = identifier) ;) (expression_statement "pbVar10 = (byte *)string + 1;" (assignment_expression "pbVar10 = (byte *)string + 1" identifier = (binary_expression "(byte *)string + 1" (cast_expression "(byte *)string" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) + number_literal)) ;) (expression_statement "uVar4 = (*ppuVar9)[(byte)*string];" (assignment_expression "uVar4 = (*ppuVar9)[(byte)*string]" identifier = (subscript_expression "(*ppuVar9)[(byte)*string]" (parenthesized_expression "(*ppuVar9)" ( (pointer_expression "*ppuVar9" * identifier) )) [ (binary_expression "(byte)*string" (parenthesized_expression "(byte)" ( identifier )) * identifier) ])) ;) (if_statement "if (((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)) {\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }" if (parenthesized_expression "(((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0))" ( (binary_expression "((uVar4 & 0x4000) != 0) || ((uVar4 & 2) == 0)" (parenthesized_expression "((uVar4 & 0x4000) != 0)" ( (binary_expression "(uVar4 & 0x4000) != 0" (parenthesized_expression "(uVar4 & 0x4000)" ( (binary_expression "uVar4 & 0x4000" identifier & number_literal) )) != number_literal) )) || (parenthesized_expression "((uVar4 & 2) == 0)" ( (binary_expression "(uVar4 & 2) == 0" (parenthesized_expression "(uVar4 & 2)" ( (binary_expression "uVar4 & 2" identifier & number_literal) )) == number_literal) ))) )) (compound_statement "{\n            if (nbytes == 0x7fffffff) break;\n            nbytes = nbytes + 1;\n          }" { (if_statement "if (nbytes == 0x7fffffff) break;" if (parenthesized_expression "(nbytes == 0x7fffffff)" ( (binary_expression "nbytes == 0x7fffffff" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "nbytes = nbytes + 1;" (assignment_expression "nbytes = nbytes + 1" identifier = (binary_expression "nbytes + 1" identifier + number_literal)) ;) })) (expression_statement "uVar5 = nbytes;" (assignment_expression "uVar5 = nbytes" identifier = identifier) ;) (expression_statement "string = (char *)pbVar10;" (assignment_expression "string = (char *)pbVar10" identifier = (cast_expression "(char *)pbVar10" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) }) while (parenthesized_expression "(pbVar1 != pbVar10)" ( (binary_expression "pbVar1 != pbVar10" identifier != identifier) )) ;) }) (else_clause "else {\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }" else (compound_statement "{\n        sVar7 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);\n      }" { (expression_statement "sVar7 = 0;" (assignment_expression "sVar7 = 0" identifier = number_literal) ;) (do_statement "do {\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        } while (nbytes != sVar7);" do (compound_statement "{\n          if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (sVar7 == 0x7fffffff) goto LAB_00061f60;\n          sVar7 = sVar7 + 1;\n        }" { (if_statement "if ((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;" if (parenthesized_expression "((*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0)" ( (binary_expression "(*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40) == 0" (parenthesized_expression "(*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40)" ( (binary_expression "*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1)" * (cast_expression "(byte *)((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1)" ( (binary_expression "(int)*ppuVar9 + (uint)(byte)string[sVar7] * 2 + 1" (binary_expression "(int)*ppuVar9 + (uint)(byte)string[sVar7] * 2" (cast_expression "(int)*ppuVar9" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*ppuVar9" * identifier)) + (binary_expression "(uint)(byte)string[sVar7] * 2" (cast_expression "(uint)(byte)string[sVar7]" ( (type_descriptor "uint" type_identifier) ) (cast_expression "(byte)string[sVar7]" ( (type_descriptor "byte" type_identifier) ) (subscript_expression "string[sVar7]" identifier [ identifier ]))) * number_literal)) + number_literal) )))) & number_literal) )) == number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;)) (if_statement "if (sVar7 == 0x7fffffff) goto LAB_00061f60;" if (parenthesized_expression "(sVar7 == 0x7fffffff)" ( (binary_expression "sVar7 == 0x7fffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "sVar7 = sVar7 + 1;" (assignment_expression "sVar7 = sVar7 + 1" identifier = (binary_expression "sVar7 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(nbytes != sVar7)" ( (binary_expression "nbytes != sVar7" identifier != identifier) )) ;) }))) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) })) }) (else_clause "else if (string < pbVar1) {\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }" else (if_statement "if (string < pbVar1) {\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }" if (parenthesized_expression "(string < pbVar1)" ( (binary_expression "string < pbVar1" identifier < identifier) )) (compound_statement "{\n    nbytes = 0;\nLAB_00061d3b:\n    bVar3 = *string;\n    if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    mbstate.__count = 0;\n    mbstate.__value.__wch = 0;\n    if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    goto LAB_00061d31;\n  }" { (expression_statement "nbytes = 0;" (assignment_expression "nbytes = 0" identifier = number_literal) ;) (labeled_statement "LAB_00061d3b:\n    bVar3 = *string;" statement_identifier : (expression_statement "bVar3 = *string;" (assignment_expression "bVar3 = *string" identifier = (pointer_expression "*string" * identifier)) ;)) (if_statement "if ((char)bVar3 < '@') {\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" if (parenthesized_expression "((char)bVar3 < '@')" ( (binary_expression "(char)bVar3 < '@'" (cast_expression "(char)bVar3" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'@'" ' character ')) )) (compound_statement "{\n      if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" { (if_statement "if (((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))) goto LAB_00061d51;" if (parenthesized_expression "(((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20)))" ( (binary_expression "((char)bVar3 < '%') && (3 < (byte)(bVar3 - 0x20))" (parenthesized_expression "((char)bVar3 < '%')" ( (binary_expression "(char)bVar3 < '%'" (cast_expression "(char)bVar3" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'%'" ' character ')) )) && (parenthesized_expression "(3 < (byte)(bVar3 - 0x20))" ( (binary_expression "3 < (byte)(bVar3 - 0x20)" number_literal < (call_expression "(byte)(bVar3 - 0x20)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(bVar3 - 0x20)" ( (binary_expression "bVar3 - 0x20" identifier - number_literal) )))) ))) )) (goto_statement "goto LAB_00061d51;" goto statement_identifier ;)) (goto_statement "goto LAB_00061d2b;" goto statement_identifier ;) })) (if_statement "if (('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;" if (parenthesized_expression "(('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))))" ( (binary_expression "('@' < (char)bVar3) && (((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e)))" (parenthesized_expression "('@' < (char)bVar3)" ( (binary_expression "'@' < (char)bVar3" (char_literal "'@'" ' character ') < (cast_expression "(char)bVar3" ( (type_descriptor "char" primitive_type) ) identifier)) )) && (parenthesized_expression "(((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e)))" ( (parenthesized_expression "((char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e))" ( (binary_expression "(char)bVar3 < '`' || ((byte)(bVar3 + 0x9f) < 0x1e)" (binary_expression "(char)bVar3 < '`'" (cast_expression "(char)bVar3" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'`'" ' character ')) || (parenthesized_expression "((byte)(bVar3 + 0x9f) < 0x1e)" ( (binary_expression "(byte)(bVar3 + 0x9f) < 0x1e" (call_expression "(byte)(bVar3 + 0x9f)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(bVar3 + 0x9f)" ( (binary_expression "bVar3 + 0x9f" identifier + number_literal) ))) < number_literal) ))) )) ))) )) (goto_statement "goto LAB_00061d2b;" goto statement_identifier ;)) (labeled_statement "LAB_00061d51:\n    mbstate.__count = 0;" statement_identifier : (expression_statement "mbstate.__count = 0;" (assignment_expression "mbstate.__count = 0" (field_expression "mbstate.__count" identifier . field_identifier) = number_literal) ;)) (expression_statement "mbstate.__value.__wch = 0;" (assignment_expression "mbstate.__value.__wch = 0" (field_expression "mbstate.__value.__wch" (field_expression "mbstate.__value" identifier . field_identifier) . field_identifier) = number_literal) ;) (if_statement "if ((flags & 2U) == 0) {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }\n    else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }" if (parenthesized_expression "((flags & 2U) == 0)" ( (binary_expression "(flags & 2U) == 0" (parenthesized_expression "(flags & 2U)" ( (binary_expression "flags & 2U" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }" { (do_statement "do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);" do (compound_statement "{\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      }" { (expression_statement "sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);" (assignment_expression "sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate)" identifier = (call_expression "rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate)" identifier (argument_list "(&wc,string,(int)pbVar1 - (int)string,&mbstate)" ( (pointer_expression "&wc" & identifier) , identifier , (binary_expression "(int)pbVar1 - (int)string" (cast_expression "(int)pbVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)string" ( (type_descriptor "int" primitive_type) ) identifier)) , (pointer_expression "&mbstate" & identifier) )))) ;) (if_statement "if (sVar7 == 0xffffffff) goto LAB_00061f30;" if (parenthesized_expression "(sVar7 == 0xffffffff)" ( (binary_expression "sVar7 == 0xffffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f30;" goto statement_identifier ;)) (if_statement "if (sVar7 == 0xfffffffe) goto LAB_00061f48;" if (parenthesized_expression "(sVar7 == 0xfffffffe)" ( (binary_expression "sVar7 == 0xfffffffe" identifier == number_literal) )) (goto_statement "goto LAB_00061f48;" goto statement_identifier ;)) (if_statement "if (sVar7 == 0) {\n          sVar7 = 1;\n        }" if (parenthesized_expression "(sVar7 == 0)" ( (binary_expression "sVar7 == 0" identifier == number_literal) )) (compound_statement "{\n          sVar7 = 1;\n        }" { (expression_statement "sVar7 = 1;" (assignment_expression "sVar7 = 1" identifier = number_literal) ;) })) (expression_statement "iVar8 = wcwidth(wc);" (assignment_expression "iVar8 = wcwidth(wc)" identifier = (call_expression "wcwidth(wc)" identifier (argument_list "(wc)" ( identifier )))) ;) (if_statement "if (iVar8 < 0) {\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }" if (parenthesized_expression "(iVar8 < 0)" ( (binary_expression "iVar8 < 0" identifier < number_literal) )) (compound_statement "{\n          iVar8 = iswcntrl(wc);\n          if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }\n        }" { (expression_statement "iVar8 = iswcntrl(wc);" (assignment_expression "iVar8 = iswcntrl(wc)" identifier = (call_expression "iswcntrl(wc)" identifier (argument_list "(wc)" ( identifier )))) ;) (if_statement "if (iVar8 == 0) {\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }" if (parenthesized_expression "(iVar8 == 0)" ( (binary_expression "iVar8 == 0" identifier == number_literal) )) (compound_statement "{\n            if (nbytes == 0x7fffffff) goto LAB_00061f60;\n            nbytes = nbytes + 1;\n          }" { (if_statement "if (nbytes == 0x7fffffff) goto LAB_00061f60;" if (parenthesized_expression "(nbytes == 0x7fffffff)" ( (binary_expression "nbytes == 0x7fffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "nbytes = nbytes + 1;" (assignment_expression "nbytes = nbytes + 1" identifier = (binary_expression "nbytes + 1" identifier + number_literal)) ;) })) }) (else_clause "else {\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }" else (compound_statement "{\n          if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n          nbytes = nbytes + iVar8;\n        }" { (if_statement "if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;" if (parenthesized_expression "((int)(0x7fffffff - nbytes) < iVar8)" ( (binary_expression "(int)(0x7fffffff - nbytes) < iVar8" (cast_expression "(int)(0x7fffffff - nbytes)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(0x7fffffff - nbytes)" ( (binary_expression "0x7fffffff - nbytes" number_literal - identifier) ))) < identifier) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "nbytes = nbytes + iVar8;" (assignment_expression "nbytes = nbytes + iVar8" identifier = (binary_expression "nbytes + iVar8" identifier + identifier)) ;) }))) (expression_statement "string = (char *)((byte *)string + sVar7);" (assignment_expression "string = (char *)((byte *)string + sVar7)" identifier = (cast_expression "(char *)((byte *)string + sVar7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((byte *)string + sVar7)" ( (binary_expression "(byte *)string + sVar7" (cast_expression "(byte *)string" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) + identifier) )))) ;) (expression_statement "iVar8 = mbsinit((mbstate_t *)&mbstate);" (assignment_expression "iVar8 = mbsinit((mbstate_t *)&mbstate)" identifier = (call_expression "mbsinit((mbstate_t *)&mbstate)" identifier (argument_list "((mbstate_t *)&mbstate)" ( (cast_expression "(mbstate_t *)&mbstate" ( (type_descriptor "mbstate_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&mbstate" & identifier)) )))) ;) }) while (parenthesized_expression "(iVar8 == 0)" ( (binary_expression "iVar8 == 0" identifier == number_literal) )) ;) }) (else_clause "else {\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }" else (compound_statement "{\n      do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);\n    }" { (do_statement "do {\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      } while (iVar8 == 0);" do (compound_statement "{\n        sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);\n        if (sVar7 == 0xffffffff) goto LAB_00061f30;\n        if (sVar7 == 0xfffffffe) goto LAB_00061f48;\n        if (sVar7 == 0) {\n          sVar7 = 1;\n        }\n        iVar8 = wcwidth(wc);\n        if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;\n        nbytes = nbytes + iVar8;\n        string = (char *)((byte *)string + sVar7);\n        iVar8 = mbsinit((mbstate_t *)&mbstate);\n      }" { (expression_statement "sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate);" (assignment_expression "sVar7 = rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate)" identifier = (call_expression "rpl_mbrtowc(&wc,string,(int)pbVar1 - (int)string,&mbstate)" identifier (argument_list "(&wc,string,(int)pbVar1 - (int)string,&mbstate)" ( (pointer_expression "&wc" & identifier) , identifier , (binary_expression "(int)pbVar1 - (int)string" (cast_expression "(int)pbVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)string" ( (type_descriptor "int" primitive_type) ) identifier)) , (pointer_expression "&mbstate" & identifier) )))) ;) (if_statement "if (sVar7 == 0xffffffff) goto LAB_00061f30;" if (parenthesized_expression "(sVar7 == 0xffffffff)" ( (binary_expression "sVar7 == 0xffffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f30;" goto statement_identifier ;)) (if_statement "if (sVar7 == 0xfffffffe) goto LAB_00061f48;" if (parenthesized_expression "(sVar7 == 0xfffffffe)" ( (binary_expression "sVar7 == 0xfffffffe" identifier == number_literal) )) (goto_statement "goto LAB_00061f48;" goto statement_identifier ;)) (if_statement "if (sVar7 == 0) {\n          sVar7 = 1;\n        }" if (parenthesized_expression "(sVar7 == 0)" ( (binary_expression "sVar7 == 0" identifier == number_literal) )) (compound_statement "{\n          sVar7 = 1;\n        }" { (expression_statement "sVar7 = 1;" (assignment_expression "sVar7 = 1" identifier = number_literal) ;) })) (expression_statement "iVar8 = wcwidth(wc);" (assignment_expression "iVar8 = wcwidth(wc)" identifier = (call_expression "wcwidth(wc)" identifier (argument_list "(wc)" ( identifier )))) ;) (if_statement "if (iVar8 < 0) {\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }" if (parenthesized_expression "(iVar8 < 0)" ( (binary_expression "iVar8 < 0" identifier < number_literal) )) (compound_statement "{\n          nbytes = 0xffffffff;\n          goto LAB_00061e40;\n        }" { (expression_statement "nbytes = 0xffffffff;" (assignment_expression "nbytes = 0xffffffff" identifier = number_literal) ;) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) })) (if_statement "if ((int)(0x7fffffff - nbytes) < iVar8) goto LAB_00061f60;" if (parenthesized_expression "((int)(0x7fffffff - nbytes) < iVar8)" ( (binary_expression "(int)(0x7fffffff - nbytes) < iVar8" (cast_expression "(int)(0x7fffffff - nbytes)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(0x7fffffff - nbytes)" ( (binary_expression "0x7fffffff - nbytes" number_literal - identifier) ))) < identifier) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "nbytes = nbytes + iVar8;" (assignment_expression "nbytes = nbytes + iVar8" identifier = (binary_expression "nbytes + iVar8" identifier + identifier)) ;) (expression_statement "string = (char *)((byte *)string + sVar7);" (assignment_expression "string = (char *)((byte *)string + sVar7)" identifier = (cast_expression "(char *)((byte *)string + sVar7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((byte *)string + sVar7)" ( (binary_expression "(byte *)string + sVar7" (cast_expression "(byte *)string" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) + identifier) )))) ;) (expression_statement "iVar8 = mbsinit((mbstate_t *)&mbstate);" (assignment_expression "iVar8 = mbsinit((mbstate_t *)&mbstate)" identifier = (call_expression "mbsinit((mbstate_t *)&mbstate)" identifier (argument_list "((mbstate_t *)&mbstate)" ( (cast_expression "(mbstate_t *)&mbstate" ( (type_descriptor "mbstate_t *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&mbstate" & identifier)) )))) ;) }) while (parenthesized_expression "(iVar8 == 0)" ( (binary_expression "iVar8 == 0" identifier == number_literal) )) ;) }))) (goto_statement "goto LAB_00061d31;" goto statement_identifier ;) })))) (expression_statement "nbytes = 0;" (assignment_expression "nbytes = 0" identifier = number_literal) ;) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) (labeled_statement "LAB_00061f30:\n  if ((flags & 1U) != 0) goto LAB_00061e39;" statement_identifier : (if_statement "if ((flags & 1U) != 0) goto LAB_00061e39;" if (parenthesized_expression "((flags & 1U) != 0)" ( (binary_expression "(flags & 1U) != 0" (parenthesized_expression "(flags & 1U)" ( (binary_expression "flags & 1U" identifier & number_literal) )) != number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;))) (labeled_statement "LAB_00061d2b:\n  string = (char *)((byte *)string + 1);" statement_identifier : (expression_statement "string = (char *)((byte *)string + 1);" (assignment_expression "string = (char *)((byte *)string + 1)" identifier = (cast_expression "(char *)((byte *)string + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((byte *)string + 1)" ( (binary_expression "(byte *)string + 1" (cast_expression "(byte *)string" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) + number_literal) )))) ;)) (expression_statement "nbytes = nbytes + 1;" (assignment_expression "nbytes = nbytes + 1" identifier = (binary_expression "nbytes + 1" identifier + number_literal)) ;) (labeled_statement "LAB_00061d31:\n  if (pbVar1 <= string) goto LAB_00061e40;" statement_identifier : (if_statement "if (pbVar1 <= string) goto LAB_00061e40;" if (parenthesized_expression "(pbVar1 <= string)" ( (binary_expression "pbVar1 <= string" identifier <= identifier) )) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;))) (goto_statement "goto LAB_00061d3b;" goto statement_identifier ;) (labeled_statement "LAB_00061f48:\n  if ((flags & 1U) != 0) goto LAB_00061e39;" statement_identifier : (if_statement "if ((flags & 1U) != 0) goto LAB_00061e39;" if (parenthesized_expression "((flags & 1U) != 0)" ( (binary_expression "(flags & 1U) != 0" (parenthesized_expression "(flags & 1U)" ( (binary_expression "flags & 1U" identifier & number_literal) )) != number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;))) (expression_statement "nbytes = nbytes + 1;" (assignment_expression "nbytes = nbytes + 1" identifier = (binary_expression "nbytes + 1" identifier + number_literal)) ;) (expression_statement "string = (char *)pbVar1;" (assignment_expression "string = (char *)pbVar1" identifier = (cast_expression "(char *)pbVar1" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) identifier)) ;) (goto_statement "goto LAB_00061d31;" goto statement_identifier ;) (labeled_statement "LAB_00061e39:\n  nbytes = 0xffffffff;" statement_identifier : (expression_statement "nbytes = 0xffffffff;" (assignment_expression "nbytes = 0xffffffff" identifier = number_literal) ;)) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) (labeled_statement "LAB_00061f60:\n  nbytes = 0x7fffffff;" statement_identifier : (expression_statement "nbytes = 0x7fffffff;" (assignment_expression "nbytes = 0x7fffffff" identifier = number_literal) ;)) (labeled_statement "LAB_00061e40:\n  if (iVar2 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" statement_identifier : (if_statement "if (iVar2 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" if (parenthesized_expression "(iVar2 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "iVar2 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    /* WARNING: Subroutine does not return */\n    __stack_chk_fail_local();\n  }" { comment (expression_statement "__stack_chk_fail_local();" (call_expression "__stack_chk_fail_local()" identifier (argument_list "()" ( ))) ;) }))) (return_statement "return nbytes;" return identifier ;) })))
(translation_unit "uint FUN_00061cc0(byte *param_1,uint param_2,uint param_3)\n\n{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }\n  return param_2;\n}\n\n" (function_definition "uint FUN_00061cc0(byte *param_1,uint param_2,uint param_3)\n\n{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }\n  return param_2;\n}" type_identifier (function_declarator "FUN_00061cc0(byte *param_1,uint param_2,uint param_3)" identifier (parameter_list "(byte *param_1,uint param_2,uint param_3)" ( (parameter_declaration "byte *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "uint param_2" type_identifier identifier) , (parameter_declaration "uint param_3" type_identifier identifier) ))) (compound_statement "{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }\n  return param_2;\n}" { (declaration "byte *pbVar1;" type_identifier (pointer_declarator "*pbVar1" * identifier) ;) (declaration "byte bVar2;" type_identifier identifier ;) (declaration "ushort uVar3;" type_identifier identifier ;) (declaration "size_t sVar4;" primitive_type identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "int iVar7;" primitive_type identifier ;) (declaration "ushort **ppuVar8;" type_identifier (pointer_declarator "**ppuVar8" * (pointer_declarator "*ppuVar8" * identifier)) ;) (declaration "byte *pbVar9;" type_identifier (pointer_declarator "*pbVar9" * identifier) ;) (declaration "int in_GS_OFFSET;" primitive_type identifier ;) (declaration "wchar_t local_2c;" type_identifier identifier ;) (declaration "mbstate_t local_28;" type_identifier identifier ;) (declaration "int local_20;" primitive_type identifier ;) (declaration "undefined4 uStack_14;" type_identifier identifier ;) (expression_statement "uStack_14 = 0x61cc9;" (assignment_expression "uStack_14 = 0x61cc9" identifier = number_literal) ;) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" identifier = (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) ;) (expression_statement "pbVar1 = param_1 + param_2;" (assignment_expression "pbVar1 = param_1 + param_2" identifier = (binary_expression "param_1 + param_2" identifier + identifier)) ;) (expression_statement "sVar4 = __ctype_get_mb_cur_max();" (assignment_expression "sVar4 = __ctype_get_mb_cur_max()" identifier = (call_expression "__ctype_get_mb_cur_max()" identifier (argument_list "()" ( )))) ;) (if_statement "if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" if (parenthesized_expression "(sVar4 < 2)" ( (binary_expression "sVar4 < 2" identifier < number_literal) )) (compound_statement "{\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }" { (if_statement "if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }" if (parenthesized_expression "(param_1 < pbVar1)" ( (binary_expression "param_1 < pbVar1" identifier < identifier) )) (compound_statement "{\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }" { (expression_statement "ppuVar8 = __ctype_b_loc();" (assignment_expression "ppuVar8 = __ctype_b_loc()" identifier = (call_expression "__ctype_b_loc()" identifier (argument_list "()" ( )))) ;) (expression_statement "uVar5 = param_3 & 2;" (assignment_expression "uVar5 = param_3 & 2" identifier = (binary_expression "param_3 & 2" identifier & number_literal)) ;) (if_statement "if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" if (parenthesized_expression "((param_3 & 2) == 0)" ( (binary_expression "(param_3 & 2) == 0" (parenthesized_expression "(param_3 & 2)" ( (binary_expression "param_3 & 2" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }" { (do_statement "do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);" do (compound_statement "{\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        }" { (expression_statement "param_2 = uVar5;" (assignment_expression "param_2 = uVar5" identifier = identifier) ;) (expression_statement "pbVar9 = param_1 + 1;" (assignment_expression "pbVar9 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;) (expression_statement "uVar3 = (*ppuVar8)[*param_1];" (assignment_expression "uVar3 = (*ppuVar8)[*param_1]" identifier = (subscript_expression "(*ppuVar8)[*param_1]" (parenthesized_expression "(*ppuVar8)" ( (pointer_expression "*ppuVar8" * identifier) )) [ (pointer_expression "*param_1" * identifier) ])) ;) (if_statement "if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }" if (parenthesized_expression "(((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0))" ( (binary_expression "((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)" (parenthesized_expression "((uVar3 & 0x4000) != 0)" ( (binary_expression "(uVar3 & 0x4000) != 0" (parenthesized_expression "(uVar3 & 0x4000)" ( (binary_expression "uVar3 & 0x4000" identifier & number_literal) )) != number_literal) )) || (parenthesized_expression "((uVar3 & 2) == 0)" ( (binary_expression "(uVar3 & 2) == 0" (parenthesized_expression "(uVar3 & 2)" ( (binary_expression "uVar3 & 2" identifier & number_literal) )) == number_literal) ))) )) (compound_statement "{\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }" { (if_statement "if (param_2 == 0x7fffffff) break;" if (parenthesized_expression "(param_2 == 0x7fffffff)" ( (binary_expression "param_2 == 0x7fffffff" identifier == number_literal) )) (break_statement "break;" break ;)) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) })) (expression_statement "uVar5 = param_2;" (assignment_expression "uVar5 = param_2" identifier = identifier) ;) (expression_statement "param_1 = pbVar9;" (assignment_expression "param_1 = pbVar9" identifier = identifier) ;) }) while (parenthesized_expression "(pbVar1 != pbVar9)" ( (binary_expression "pbVar1 != pbVar9" identifier != identifier) )) ;) }) (else_clause "else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" else (compound_statement "{\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" { (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (do_statement "do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);" do (compound_statement "{\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        }" { (if_statement "if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;" if (parenthesized_expression "((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)" ( (binary_expression "(*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0" (parenthesized_expression "(*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40)" ( (binary_expression "*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" * (cast_expression "(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" ( (binary_expression "(int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1" (binary_expression "(int)*ppuVar8 + (uint)param_1[uVar5] * 2" (cast_expression "(int)*ppuVar8" ( (type_descriptor "int" primitive_type) ) (pointer_expression "*ppuVar8" * identifier)) + (binary_expression "(uint)param_1[uVar5] * 2" (cast_expression "(uint)param_1[uVar5]" ( (type_descriptor "uint" type_identifier) ) (subscript_expression "param_1[uVar5]" identifier [ identifier ])) * number_literal)) + number_literal) )))) & number_literal) )) == number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;)) (if_statement "if (uVar5 == 0x7fffffff) goto LAB_00061f60;" if (parenthesized_expression "(uVar5 == 0x7fffffff)" ( (binary_expression "uVar5 == 0x7fffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" identifier = (binary_expression "uVar5 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "(param_2 != uVar5)" ( (binary_expression "param_2 != uVar5" identifier != identifier) )) ;) }))) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) })) }) (else_clause "else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" else (if_statement "if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" if (parenthesized_expression "(param_1 < pbVar1)" ( (binary_expression "param_1 < pbVar1" identifier < identifier) )) (compound_statement "{\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" { (expression_statement "param_2 = 0;" (assignment_expression "param_2 = 0" identifier = number_literal) ;) (labeled_statement "LAB_00061d3b:\n    bVar2 = *param_1;" statement_identifier : (expression_statement "bVar2 = *param_1;" (assignment_expression "bVar2 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;)) (if_statement "if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" if (parenthesized_expression "((char)bVar2 < '@')" ( (binary_expression "(char)bVar2 < '@'" (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'@'" ' character ')) )) (compound_statement "{\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" { (if_statement "if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;" if (parenthesized_expression "(((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20)))" ( (binary_expression "((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))" (parenthesized_expression "((char)bVar2 < '%')" ( (binary_expression "(char)bVar2 < '%'" (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'%'" ' character ')) )) && (parenthesized_expression "(3 < (byte)(bVar2 - 0x20))" ( (binary_expression "3 < (byte)(bVar2 - 0x20)" number_literal < (call_expression "(byte)(bVar2 - 0x20)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(bVar2 - 0x20)" ( (binary_expression "bVar2 - 0x20" identifier - number_literal) )))) ))) )) (goto_statement "goto LAB_00061d51;" goto statement_identifier ;)) (goto_statement "goto LAB_00061d2b;" goto statement_identifier ;) })) (if_statement "if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;" if (parenthesized_expression "(('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))" ( (binary_expression "('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)))" (parenthesized_expression "('@' < (char)bVar2)" ( (binary_expression "'@' < (char)bVar2" (char_literal "'@'" ' character ') < (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier)) )) && (parenthesized_expression "(((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)))" ( (parenthesized_expression "((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))" ( (binary_expression "(char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)" (binary_expression "(char)bVar2 < '`'" (cast_expression "(char)bVar2" ( (type_descriptor "char" primitive_type) ) identifier) < (char_literal "'`'" ' character ')) || (parenthesized_expression "((byte)(bVar2 + 0x9f) < 0x1e)" ( (binary_expression "(byte)(bVar2 + 0x9f) < 0x1e" (call_expression "(byte)(bVar2 + 0x9f)" (parenthesized_expression "(byte)" ( identifier )) (argument_list "(bVar2 + 0x9f)" ( (binary_expression "bVar2 + 0x9f" identifier + number_literal) ))) < number_literal) ))) )) ))) )) (goto_statement "goto LAB_00061d2b;" goto statement_identifier ;)) (labeled_statement "LAB_00061d51:\n    local_28.__count = 0;" statement_identifier : (expression_statement "local_28.__count = 0;" (assignment_expression "local_28.__count = 0" (field_expression "local_28.__count" identifier . field_identifier) = number_literal) ;)) (expression_statement "local_28.__value.__wch = 0;" (assignment_expression "local_28.__value.__wch = 0" (field_expression "local_28.__value.__wch" (field_expression "local_28.__value" identifier . field_identifier) . field_identifier) = number_literal) ;) (if_statement "if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" if (parenthesized_expression "((param_3 & 2) == 0)" ( (binary_expression "(param_3 & 2) == 0" (parenthesized_expression "(param_3 & 2)" ( (binary_expression "param_3 & 2" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" { (do_statement "do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);" do (compound_statement "{\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      }" { (expression_statement "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);" (assignment_expression "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier = (call_expression "FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier (argument_list "(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" ( (pointer_expression "&local_2c" & identifier) , identifier , (binary_expression "(int)pbVar1 - (int)param_1" (cast_expression "(int)pbVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_1" ( (type_descriptor "int" primitive_type) ) identifier)) , (pointer_expression "&local_28" & identifier) )))) ;) (if_statement "if (iVar6 == -1) goto LAB_00061f30;" if (parenthesized_expression "(iVar6 == -1)" ( (binary_expression "iVar6 == -1" identifier == number_literal) )) (goto_statement "goto LAB_00061f30;" goto statement_identifier ;)) (if_statement "if (iVar6 == -2) goto LAB_00061f48;" if (parenthesized_expression "(iVar6 == -2)" ( (binary_expression "iVar6 == -2" identifier == number_literal) )) (goto_statement "goto LAB_00061f48;" goto statement_identifier ;)) (if_statement "if (iVar6 == 0) {\n          iVar6 = 1;\n        }" if (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) (compound_statement "{\n          iVar6 = 1;\n        }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) })) (expression_statement "iVar7 = wcwidth(local_2c);" (assignment_expression "iVar7 = wcwidth(local_2c)" identifier = (call_expression "wcwidth(local_2c)" identifier (argument_list "(local_2c)" ( identifier )))) ;) (if_statement "if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" if (parenthesized_expression "(iVar7 < 0)" ( (binary_expression "iVar7 < 0" identifier < number_literal) )) (compound_statement "{\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }" { (expression_statement "iVar7 = iswcntrl(local_2c);" (assignment_expression "iVar7 = iswcntrl(local_2c)" identifier = (call_expression "iswcntrl(local_2c)" identifier (argument_list "(local_2c)" ( identifier )))) ;) (if_statement "if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }" if (parenthesized_expression "(iVar7 == 0)" ( (binary_expression "iVar7 == 0" identifier == number_literal) )) (compound_statement "{\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }" { (if_statement "if (param_2 == 0x7fffffff) goto LAB_00061f60;" if (parenthesized_expression "(param_2 == 0x7fffffff)" ( (binary_expression "param_2 == 0x7fffffff" identifier == number_literal) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) })) }) (else_clause "else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" else (compound_statement "{\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" { (if_statement "if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;" if (parenthesized_expression "((int)(0x7fffffff - param_2) < iVar7)" ( (binary_expression "(int)(0x7fffffff - param_2) < iVar7" (cast_expression "(int)(0x7fffffff - param_2)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(0x7fffffff - param_2)" ( (binary_expression "0x7fffffff - param_2" number_literal - identifier) ))) < identifier) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "param_2 = param_2 + iVar7;" (assignment_expression "param_2 = param_2 + iVar7" identifier = (binary_expression "param_2 + iVar7" identifier + identifier)) ;) }))) (expression_statement "param_1 = param_1 + iVar6;" (assignment_expression "param_1 = param_1 + iVar6" identifier = (binary_expression "param_1 + iVar6" identifier + identifier)) ;) (expression_statement "iVar6 = mbsinit(&local_28);" (assignment_expression "iVar6 = mbsinit(&local_28)" identifier = (call_expression "mbsinit(&local_28)" identifier (argument_list "(&local_28)" ( (pointer_expression "&local_28" & identifier) )))) ;) }) while (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) ;) }) (else_clause "else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" else (compound_statement "{\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" { (do_statement "do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);" do (compound_statement "{\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      }" { (expression_statement "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);" (assignment_expression "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier = (call_expression "FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" identifier (argument_list "(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" ( (pointer_expression "&local_2c" & identifier) , identifier , (binary_expression "(int)pbVar1 - (int)param_1" (cast_expression "(int)pbVar1" ( (type_descriptor "int" primitive_type) ) identifier) - (cast_expression "(int)param_1" ( (type_descriptor "int" primitive_type) ) identifier)) , (pointer_expression "&local_28" & identifier) )))) ;) (if_statement "if (iVar6 == -1) goto LAB_00061f30;" if (parenthesized_expression "(iVar6 == -1)" ( (binary_expression "iVar6 == -1" identifier == number_literal) )) (goto_statement "goto LAB_00061f30;" goto statement_identifier ;)) (if_statement "if (iVar6 == -2) goto LAB_00061f48;" if (parenthesized_expression "(iVar6 == -2)" ( (binary_expression "iVar6 == -2" identifier == number_literal) )) (goto_statement "goto LAB_00061f48;" goto statement_identifier ;)) (if_statement "if (iVar6 == 0) {\n          iVar6 = 1;\n        }" if (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) (compound_statement "{\n          iVar6 = 1;\n        }" { (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" identifier = number_literal) ;) })) (expression_statement "iVar7 = wcwidth(local_2c);" (assignment_expression "iVar7 = wcwidth(local_2c)" identifier = (call_expression "wcwidth(local_2c)" identifier (argument_list "(local_2c)" ( identifier )))) ;) (if_statement "if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }" if (parenthesized_expression "(iVar7 < 0)" ( (binary_expression "iVar7 < 0" identifier < number_literal) )) (compound_statement "{\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }" { (expression_statement "param_2 = 0xffffffff;" (assignment_expression "param_2 = 0xffffffff" identifier = number_literal) ;) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) })) (if_statement "if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;" if (parenthesized_expression "((int)(0x7fffffff - param_2) < iVar7)" ( (binary_expression "(int)(0x7fffffff - param_2) < iVar7" (cast_expression "(int)(0x7fffffff - param_2)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(0x7fffffff - param_2)" ( (binary_expression "0x7fffffff - param_2" number_literal - identifier) ))) < identifier) )) (goto_statement "goto LAB_00061f60;" goto statement_identifier ;)) (expression_statement "param_2 = param_2 + iVar7;" (assignment_expression "param_2 = param_2 + iVar7" identifier = (binary_expression "param_2 + iVar7" identifier + identifier)) ;) (expression_statement "param_1 = param_1 + iVar6;" (assignment_expression "param_1 = param_1 + iVar6" identifier = (binary_expression "param_1 + iVar6" identifier + identifier)) ;) (expression_statement "iVar6 = mbsinit(&local_28);" (assignment_expression "iVar6 = mbsinit(&local_28)" identifier = (call_expression "mbsinit(&local_28)" identifier (argument_list "(&local_28)" ( (pointer_expression "&local_28" & identifier) )))) ;) }) while (parenthesized_expression "(iVar6 == 0)" ( (binary_expression "iVar6 == 0" identifier == number_literal) )) ;) }))) (goto_statement "goto LAB_00061d31;" goto statement_identifier ;) })))) (expression_statement "param_2 = 0;" (assignment_expression "param_2 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) (labeled_statement "LAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;" statement_identifier : (if_statement "if ((param_3 & 1) != 0) goto LAB_00061e39;" if (parenthesized_expression "((param_3 & 1) != 0)" ( (binary_expression "(param_3 & 1) != 0" (parenthesized_expression "(param_3 & 1)" ( (binary_expression "param_3 & 1" identifier & number_literal) )) != number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;))) (labeled_statement "LAB_00061d2b:\n  param_1 = param_1 + 1;" statement_identifier : (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" identifier = (binary_expression "param_1 + 1" identifier + number_literal)) ;)) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) (labeled_statement "LAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;" statement_identifier : (if_statement "if (pbVar1 <= param_1) goto LAB_00061e40;" if (parenthesized_expression "(pbVar1 <= param_1)" ( (binary_expression "pbVar1 <= param_1" identifier <= identifier) )) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;))) (goto_statement "goto LAB_00061d3b;" goto statement_identifier ;) (labeled_statement "LAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;" statement_identifier : (if_statement "if ((param_3 & 1) != 0) goto LAB_00061e39;" if (parenthesized_expression "((param_3 & 1) != 0)" ( (binary_expression "(param_3 & 1) != 0" (parenthesized_expression "(param_3 & 1)" ( (binary_expression "param_3 & 1" identifier & number_literal) )) != number_literal) )) (goto_statement "goto LAB_00061e39;" goto statement_identifier ;))) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" identifier = (binary_expression "param_2 + 1" identifier + number_literal)) ;) (expression_statement "param_1 = pbVar1;" (assignment_expression "param_1 = pbVar1" identifier = identifier) ;) (goto_statement "goto LAB_00061d31;" goto statement_identifier ;) (labeled_statement "LAB_00061e39:\n  param_2 = 0xffffffff;" statement_identifier : (expression_statement "param_2 = 0xffffffff;" (assignment_expression "param_2 = 0xffffffff" identifier = number_literal) ;)) (goto_statement "goto LAB_00061e40;" goto statement_identifier ;) (labeled_statement "LAB_00061f60:\n  param_2 = 0x7fffffff;" statement_identifier : (expression_statement "param_2 = 0x7fffffff;" (assignment_expression "param_2 = 0x7fffffff" identifier = number_literal) ;)) (labeled_statement "LAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }" statement_identifier : (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }" if (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" ( (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" identifier != (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" * (cast_expression "(int *)(in_GS_OFFSET + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_GS_OFFSET + 0x14)" ( (binary_expression "in_GS_OFFSET + 0x14" identifier + number_literal) ))))) )) (compound_statement "{\n                    \n    FUN_0006c970();\n  }" { (expression_statement "FUN_0006c970();" (call_expression "FUN_0006c970()" identifier (argument_list "()" ( ))) ;) }))) (return_statement "return param_2;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * (pointer_declarator * IDENT)) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT & LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = (subscript_expression (parenthesized_expression ( (pointer_expression * IDENT) )) [ (pointer_expression * IDENT) ])) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) != LIT) )) || (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) ))) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }) while (parenthesized_expression ( (binary_expression IDENT != IDENT) )) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (do_statement do (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) (pointer_expression * IDENT)) + (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ IDENT ])) * LIT)) + LIT) )))) & LIT) )) == LIT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT != IDENT) )) ;) }))) (goto_statement goto statement_identifier ;) })) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression IDENT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;)) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < (char_literal ' character ')) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < (char_literal ' character ')) )) && (parenthesized_expression ( (binary_expression LIT < (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT - LIT) )))) ))) )) (goto_statement goto statement_identifier ;)) (goto_statement goto statement_identifier ;) })) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (char_literal ' character ') < (cast_expression ( (type_descriptor TYPE) ) IDENT)) )) && (parenthesized_expression ( (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) < (char_literal ' character ')) || (parenthesized_expression ( (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT + LIT) ))) < LIT) ))) )) ))) )) (goto_statement goto statement_identifier ;)) (labeled_statement statement_identifier : (expression_statement (assignment_expression (field_expression IDENT . field_identifier) = LIT) ;)) (expression_statement (assignment_expression (field_expression (field_expression IDENT . field_identifier) . field_identifier) = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) == LIT) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT , (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT)) , (pointer_expression & IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) })) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression LIT - IDENT) ))) < IDENT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) }))) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression & IDENT) )))) ;) }) while (parenthesized_expression ( (binary_expression IDENT == LIT) )) ;) }) (else_clause else (compound_statement { (do_statement do (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT , (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) - (cast_expression ( (type_descriptor TYPE) ) IDENT)) , (pointer_expression & IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression LIT - IDENT) ))) < IDENT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + IDENT)) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (pointer_expression & IDENT) )))) ;) }) while (parenthesized_expression ( (binary_expression IDENT == LIT) )) ;) }))) (goto_statement goto statement_identifier ;) })))) (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) != LIT) )) (goto_statement goto statement_identifier ;))) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;)) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (goto_statement goto statement_identifier ;))) (goto_statement goto statement_identifier ;) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) != LIT) )) (goto_statement goto statement_identifier ;))) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (goto_statement goto statement_identifier ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = LIT) ;)) (goto_statement goto statement_identifier ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = LIT) ;)) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression IDENT != (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) }))) (return_statement return IDENT ;) })))
(function_definition "uint FUN_00061cc0(byte *param_1,uint param_2,uint param_3)\n\n{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }\n  return param_2;\n}" (type_identifier "uint") (function_declarator "FUN_00061cc0(byte *param_1,uint param_2,uint param_3)" (identifier "FUN_00061cc0") (parameter_list "(byte *param_1,uint param_2,uint param_3)" (( "(") (parameter_declaration "byte *param_1" (type_identifier "byte") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "uint param_2" (type_identifier "uint") (identifier "param_2")) (, ",") (parameter_declaration "uint param_3" (type_identifier "uint") (identifier "param_3")) () ")"))) (compound_statement "{\n  byte *pbVar1;\n  byte bVar2;\n  ushort uVar3;\n  size_t sVar4;\n  uint uVar5;\n  int iVar6;\n  int iVar7;\n  ushort **ppuVar8;\n  byte *pbVar9;\n  int in_GS_OFFSET;\n  wchar_t local_2c;\n  mbstate_t local_28;\n  int local_20;\n  undefined4 uStack_14;\n  \n  uStack_14 = 0x61cc9;\n  local_20 = *(int *)(in_GS_OFFSET + 0x14);\n  pbVar1 = param_1 + param_2;\n  sVar4 = __ctype_get_mb_cur_max();\n  if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }\n  param_2 = 0;\n  goto LAB_00061e40;\nLAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\nLAB_00061d2b:\n  param_1 = param_1 + 1;\n  param_2 = param_2 + 1;\nLAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;\n  goto LAB_00061d3b;\nLAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;\n  param_2 = param_2 + 1;\n  param_1 = pbVar1;\n  goto LAB_00061d31;\nLAB_00061e39:\n  param_2 = 0xffffffff;\n  goto LAB_00061e40;\nLAB_00061f60:\n  param_2 = 0x7fffffff;\nLAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }\n  return param_2;\n}" ({ "{") (declaration "byte *pbVar1;" (type_identifier "byte") (pointer_declarator "*pbVar1" (* "*") (identifier "pbVar1")) (; ";")) (declaration "byte bVar2;" (type_identifier "byte") (identifier "bVar2") (; ";")) (declaration "ushort uVar3;" (type_identifier "ushort") (identifier "uVar3") (; ";")) (declaration "size_t sVar4;" (primitive_type "size_t") (identifier "sVar4") (; ";")) (declaration "uint uVar5;" (type_identifier "uint") (identifier "uVar5") (; ";")) (declaration "int iVar6;" (primitive_type "int") (identifier "iVar6") (; ";")) (declaration "int iVar7;" (primitive_type "int") (identifier "iVar7") (; ";")) (declaration "ushort **ppuVar8;" (type_identifier "ushort") (pointer_declarator "**ppuVar8" (* "*") (pointer_declarator "*ppuVar8" (* "*") (identifier "ppuVar8"))) (; ";")) (declaration "byte *pbVar9;" (type_identifier "byte") (pointer_declarator "*pbVar9" (* "*") (identifier "pbVar9")) (; ";")) (declaration "int in_GS_OFFSET;" (primitive_type "int") (identifier "in_GS_OFFSET") (; ";")) (declaration "wchar_t local_2c;" (type_identifier "wchar_t") (identifier "local_2c") (; ";")) (declaration "mbstate_t local_28;" (type_identifier "mbstate_t") (identifier "local_28") (; ";")) (declaration "int local_20;" (primitive_type "int") (identifier "local_20") (; ";")) (declaration "undefined4 uStack_14;" (type_identifier "undefined4") (identifier "uStack_14") (; ";")) (expression_statement "uStack_14 = 0x61cc9;" (assignment_expression "uStack_14 = 0x61cc9" (identifier "uStack_14") (= "=") (number_literal "0x61cc9")) (; ";")) (expression_statement "local_20 = *(int *)(in_GS_OFFSET + 0x14);" (assignment_expression "local_20 = *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (= "=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (expression_statement "pbVar1 = param_1 + param_2;" (assignment_expression "pbVar1 = param_1 + param_2" (identifier "pbVar1") (= "=") (binary_expression "param_1 + param_2" (identifier "param_1") (+ "+") (identifier "param_2"))) (; ";")) (expression_statement "sVar4 = __ctype_get_mb_cur_max();" (assignment_expression "sVar4 = __ctype_get_mb_cur_max()" (identifier "sVar4") (= "=") (call_expression "__ctype_get_mb_cur_max()" (identifier "__ctype_get_mb_cur_max") (argument_list "()" (( "(") () ")")))) (; ";")) (if_statement "if (sVar4 < 2) {\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }\n  else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" (if "if") (parenthesized_expression "(sVar4 < 2)" (( "(") (binary_expression "sVar4 < 2" (identifier "sVar4") (< "<") (number_literal "2")) () ")")) (compound_statement "{\n    if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }\n  }" ({ "{") (if_statement "if (param_1 < pbVar1) {\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }" (if "if") (parenthesized_expression "(param_1 < pbVar1)" (( "(") (binary_expression "param_1 < pbVar1" (identifier "param_1") (< "<") (identifier "pbVar1")) () ")")) (compound_statement "{\n      ppuVar8 = __ctype_b_loc();\n      uVar5 = param_3 & 2;\n      if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }\n      goto LAB_00061e40;\n    }" ({ "{") (expression_statement "ppuVar8 = __ctype_b_loc();" (assignment_expression "ppuVar8 = __ctype_b_loc()" (identifier "ppuVar8") (= "=") (call_expression "__ctype_b_loc()" (identifier "__ctype_b_loc") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "uVar5 = param_3 & 2;" (assignment_expression "uVar5 = param_3 & 2" (identifier "uVar5") (= "=") (binary_expression "param_3 & 2" (identifier "param_3") (& "&") (number_literal "2"))) (; ";")) (if_statement "if ((param_3 & 2) == 0) {\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }\n      else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" (if "if") (parenthesized_expression "((param_3 & 2) == 0)" (( "(") (binary_expression "(param_3 & 2) == 0" (parenthesized_expression "(param_3 & 2)" (( "(") (binary_expression "param_3 & 2" (identifier "param_3") (& "&") (number_literal "2")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);\n      }" ({ "{") (do_statement "do {\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        } while (pbVar1 != pbVar9);" (do "do") (compound_statement "{\n          param_2 = uVar5;\n          pbVar9 = param_1 + 1;\n          uVar3 = (*ppuVar8)[*param_1];\n          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }\n          uVar5 = param_2;\n          param_1 = pbVar9;\n        }" ({ "{") (expression_statement "param_2 = uVar5;" (assignment_expression "param_2 = uVar5" (identifier "param_2") (= "=") (identifier "uVar5")) (; ";")) (expression_statement "pbVar9 = param_1 + 1;" (assignment_expression "pbVar9 = param_1 + 1" (identifier "pbVar9") (= "=") (binary_expression "param_1 + 1" (identifier "param_1") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "uVar3 = (*ppuVar8)[*param_1];" (assignment_expression "uVar3 = (*ppuVar8)[*param_1]" (identifier "uVar3") (= "=") (subscript_expression "(*ppuVar8)[*param_1]" (parenthesized_expression "(*ppuVar8)" (( "(") (pointer_expression "*ppuVar8" (* "*") (identifier "ppuVar8")) () ")")) ([ "[") (pointer_expression "*param_1" (* "*") (identifier "param_1")) (] "]"))) (; ";")) (if_statement "if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }" (if "if") (parenthesized_expression "(((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0))" (( "(") (binary_expression "((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)" (parenthesized_expression "((uVar3 & 0x4000) != 0)" (( "(") (binary_expression "(uVar3 & 0x4000) != 0" (parenthesized_expression "(uVar3 & 0x4000)" (( "(") (binary_expression "uVar3 & 0x4000" (identifier "uVar3") (& "&") (number_literal "0x4000")) () ")")) (!= "!=") (number_literal "0")) () ")")) (|| "||") (parenthesized_expression "((uVar3 & 2) == 0)" (( "(") (binary_expression "(uVar3 & 2) == 0" (parenthesized_expression "(uVar3 & 2)" (( "(") (binary_expression "uVar3 & 2" (identifier "uVar3") (& "&") (number_literal "2")) () ")")) (== "==") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n            if (param_2 == 0x7fffffff) break;\n            param_2 = param_2 + 1;\n          }" ({ "{") (if_statement "if (param_2 == 0x7fffffff) break;" (if "if") (parenthesized_expression "(param_2 == 0x7fffffff)" (( "(") (binary_expression "param_2 == 0x7fffffff" (identifier "param_2") (== "==") (number_literal "0x7fffffff")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" (identifier "param_2") (= "=") (binary_expression "param_2 + 1" (identifier "param_2") (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (expression_statement "uVar5 = param_2;" (assignment_expression "uVar5 = param_2" (identifier "uVar5") (= "=") (identifier "param_2")) (; ";")) (expression_statement "param_1 = pbVar9;" (assignment_expression "param_1 = pbVar9" (identifier "param_1") (= "=") (identifier "pbVar9")) (; ";")) (} "}")) (while "while") (parenthesized_expression "(pbVar1 != pbVar9)" (( "(") (binary_expression "pbVar1 != pbVar9" (identifier "pbVar1") (!= "!=") (identifier "pbVar9")) () ")")) (; ";")) (} "}")) (else_clause "else {\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" (else "else") (compound_statement "{\n        uVar5 = 0;\n        do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);\n      }" ({ "{") (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" (identifier "uVar5") (= "=") (number_literal "0")) (; ";")) (do_statement "do {\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        } while (param_2 != uVar5);" (do "do") (compound_statement "{\n          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;\n          if (uVar5 == 0x7fffffff) goto LAB_00061f60;\n          uVar5 = uVar5 + 1;\n        }" ({ "{") (if_statement "if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)\n          goto LAB_00061e39;" (if "if") (parenthesized_expression "((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)" (( "(") (binary_expression "(*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0" (parenthesized_expression "(*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40)" (( "(") (binary_expression "*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40" (pointer_expression "*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" (* "*") (cast_expression "(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1)" (( "(") (binary_expression "(int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1" (binary_expression "(int)*ppuVar8 + (uint)param_1[uVar5] * 2" (cast_expression "(int)*ppuVar8" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (pointer_expression "*ppuVar8" (* "*") (identifier "ppuVar8"))) (+ "+") (binary_expression "(uint)param_1[uVar5] * 2" (cast_expression "(uint)param_1[uVar5]" (( "(") (type_descriptor "uint" (type_identifier "uint")) () ")") (subscript_expression "param_1[uVar5]" (identifier "param_1") ([ "[") (identifier "uVar5") (] "]"))) (* "*") (number_literal "2"))) (+ "+") (number_literal "1")) () ")")))) (& "&") (number_literal "0x40")) () ")")) (== "==") (number_literal "0")) () ")")) (goto_statement "goto LAB_00061e39;" (goto "goto") (statement_identifier "LAB_00061e39") (; ";"))) (if_statement "if (uVar5 == 0x7fffffff) goto LAB_00061f60;" (if "if") (parenthesized_expression "(uVar5 == 0x7fffffff)" (( "(") (binary_expression "uVar5 == 0x7fffffff" (identifier "uVar5") (== "==") (number_literal "0x7fffffff")) () ")")) (goto_statement "goto LAB_00061f60;" (goto "goto") (statement_identifier "LAB_00061f60") (; ";"))) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" (identifier "uVar5") (= "=") (binary_expression "uVar5 + 1" (identifier "uVar5") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(param_2 != uVar5)" (( "(") (binary_expression "param_2 != uVar5" (identifier "param_2") (!= "!=") (identifier "uVar5")) () ")")) (; ";")) (} "}")))) (goto_statement "goto LAB_00061e40;" (goto "goto") (statement_identifier "LAB_00061e40") (; ";")) (} "}"))) (} "}")) (else_clause "else if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" (else "else") (if_statement "if (param_1 < pbVar1) {\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" (if "if") (parenthesized_expression "(param_1 < pbVar1)" (( "(") (binary_expression "param_1 < pbVar1" (identifier "param_1") (< "<") (identifier "pbVar1")) () ")")) (compound_statement "{\n    param_2 = 0;\nLAB_00061d3b:\n    bVar2 = *param_1;\n    if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }\n    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;\nLAB_00061d51:\n    local_28.__count = 0;\n    local_28.__value.__wch = 0;\n    if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    goto LAB_00061d31;\n  }" ({ "{") (expression_statement "param_2 = 0;" (assignment_expression "param_2 = 0" (identifier "param_2") (= "=") (number_literal "0")) (; ";")) (labeled_statement "LAB_00061d3b:\n    bVar2 = *param_1;" (statement_identifier "LAB_00061d3b") (: ":") (expression_statement "bVar2 = *param_1;" (assignment_expression "bVar2 = *param_1" (identifier "bVar2") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";"))) (if_statement "if ((char)bVar2 < '@') {\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" (if "if") (parenthesized_expression "((char)bVar2 < '@')" (( "(") (binary_expression "(char)bVar2 < '@'" (cast_expression "(char)bVar2" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (identifier "bVar2")) (< "<") (char_literal "'@'" (' "'") (character "@") (' "'"))) () ")")) (compound_statement "{\n      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;\n      goto LAB_00061d2b;\n    }" ({ "{") (if_statement "if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;" (if "if") (parenthesized_expression "(((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20)))" (( "(") (binary_expression "((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))" (parenthesized_expression "((char)bVar2 < '%')" (( "(") (binary_expression "(char)bVar2 < '%'" (cast_expression "(char)bVar2" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (identifier "bVar2")) (< "<") (char_literal "'%'" (' "'") (character "%") (' "'"))) () ")")) (&& "&&") (parenthesized_expression "(3 < (byte)(bVar2 - 0x20))" (( "(") (binary_expression "3 < (byte)(bVar2 - 0x20)" (number_literal "3") (< "<") (call_expression "(byte)(bVar2 - 0x20)" (parenthesized_expression "(byte)" (( "(") (identifier "byte") () ")")) (argument_list "(bVar2 - 0x20)" (( "(") (binary_expression "bVar2 - 0x20" (identifier "bVar2") (- "-") (number_literal "0x20")) () ")")))) () ")"))) () ")")) (goto_statement "goto LAB_00061d51;" (goto "goto") (statement_identifier "LAB_00061d51") (; ";"))) (goto_statement "goto LAB_00061d2b;" (goto "goto") (statement_identifier "LAB_00061d2b") (; ";")) (} "}"))) (if_statement "if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))\n    goto LAB_00061d2b;" (if "if") (parenthesized_expression "(('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))" (( "(") (binary_expression "('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)))" (parenthesized_expression "('@' < (char)bVar2)" (( "(") (binary_expression "'@' < (char)bVar2" (char_literal "'@'" (' "'") (character "@") (' "'")) (< "<") (cast_expression "(char)bVar2" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (identifier "bVar2"))) () ")")) (&& "&&") (parenthesized_expression "(((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)))" (( "(") (parenthesized_expression "((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))" (( "(") (binary_expression "(char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e)" (binary_expression "(char)bVar2 < '`'" (cast_expression "(char)bVar2" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (identifier "bVar2")) (< "<") (char_literal "'`'" (' "'") (character "`") (' "'"))) (|| "||") (parenthesized_expression "((byte)(bVar2 + 0x9f) < 0x1e)" (( "(") (binary_expression "(byte)(bVar2 + 0x9f) < 0x1e" (call_expression "(byte)(bVar2 + 0x9f)" (parenthesized_expression "(byte)" (( "(") (identifier "byte") () ")")) (argument_list "(bVar2 + 0x9f)" (( "(") (binary_expression "bVar2 + 0x9f" (identifier "bVar2") (+ "+") (number_literal "0x9f")) () ")"))) (< "<") (number_literal "0x1e")) () ")"))) () ")")) () ")"))) () ")")) (goto_statement "goto LAB_00061d2b;" (goto "goto") (statement_identifier "LAB_00061d2b") (; ";"))) (labeled_statement "LAB_00061d51:\n    local_28.__count = 0;" (statement_identifier "LAB_00061d51") (: ":") (expression_statement "local_28.__count = 0;" (assignment_expression "local_28.__count = 0" (field_expression "local_28.__count" (identifier "local_28") (. ".") (field_identifier "__count")) (= "=") (number_literal "0")) (; ";"))) (expression_statement "local_28.__value.__wch = 0;" (assignment_expression "local_28.__value.__wch = 0" (field_expression "local_28.__value.__wch" (field_expression "local_28.__value" (identifier "local_28") (. ".") (field_identifier "__value")) (. ".") (field_identifier "__wch")) (= "=") (number_literal "0")) (; ";")) (if_statement "if ((param_3 & 2) == 0) {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }\n    else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" (if "if") (parenthesized_expression "((param_3 & 2) == 0)" (( "(") (binary_expression "(param_3 & 2) == 0" (parenthesized_expression "(param_3 & 2)" (( "(") (binary_expression "param_3 & 2" (identifier "param_3") (& "&") (number_literal "2")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" ({ "{") (do_statement "do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);" (do "do") (compound_statement "{\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      }" ({ "{") (expression_statement "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);" (assignment_expression "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" (identifier "iVar6") (= "=") (call_expression "FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" (identifier "FUN_00068790") (argument_list "(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" (( "(") (pointer_expression "&local_2c" (& "&") (identifier "local_2c")) (, ",") (identifier "param_1") (, ",") (binary_expression "(int)pbVar1 - (int)param_1" (cast_expression "(int)pbVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pbVar1")) (- "-") (cast_expression "(int)param_1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_1"))) (, ",") (pointer_expression "&local_28" (& "&") (identifier "local_28")) () ")")))) (; ";")) (if_statement "if (iVar6 == -1) goto LAB_00061f30;" (if "if") (parenthesized_expression "(iVar6 == -1)" (( "(") (binary_expression "iVar6 == -1" (identifier "iVar6") (== "==") (number_literal "-1")) () ")")) (goto_statement "goto LAB_00061f30;" (goto "goto") (statement_identifier "LAB_00061f30") (; ";"))) (if_statement "if (iVar6 == -2) goto LAB_00061f48;" (if "if") (parenthesized_expression "(iVar6 == -2)" (( "(") (binary_expression "iVar6 == -2" (identifier "iVar6") (== "==") (number_literal "-2")) () ")")) (goto_statement "goto LAB_00061f48;" (goto "goto") (statement_identifier "LAB_00061f48") (; ";"))) (if_statement "if (iVar6 == 0) {\n          iVar6 = 1;\n        }" (if "if") (parenthesized_expression "(iVar6 == 0)" (( "(") (binary_expression "iVar6 == 0" (identifier "iVar6") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          iVar6 = 1;\n        }" ({ "{") (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" (identifier "iVar6") (= "=") (number_literal "1")) (; ";")) (} "}"))) (expression_statement "iVar7 = wcwidth(local_2c);" (assignment_expression "iVar7 = wcwidth(local_2c)" (identifier "iVar7") (= "=") (call_expression "wcwidth(local_2c)" (identifier "wcwidth") (argument_list "(local_2c)" (( "(") (identifier "local_2c") () ")")))) (; ";")) (if_statement "if (iVar7 < 0) {\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }\n        else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" (if "if") (parenthesized_expression "(iVar7 < 0)" (( "(") (binary_expression "iVar7 < 0" (identifier "iVar7") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n          iVar7 = iswcntrl(local_2c);\n          if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }\n        }" ({ "{") (expression_statement "iVar7 = iswcntrl(local_2c);" (assignment_expression "iVar7 = iswcntrl(local_2c)" (identifier "iVar7") (= "=") (call_expression "iswcntrl(local_2c)" (identifier "iswcntrl") (argument_list "(local_2c)" (( "(") (identifier "local_2c") () ")")))) (; ";")) (if_statement "if (iVar7 == 0) {\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }" (if "if") (parenthesized_expression "(iVar7 == 0)" (( "(") (binary_expression "iVar7 == 0" (identifier "iVar7") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n            if (param_2 == 0x7fffffff) goto LAB_00061f60;\n            param_2 = param_2 + 1;\n          }" ({ "{") (if_statement "if (param_2 == 0x7fffffff) goto LAB_00061f60;" (if "if") (parenthesized_expression "(param_2 == 0x7fffffff)" (( "(") (binary_expression "param_2 == 0x7fffffff" (identifier "param_2") (== "==") (number_literal "0x7fffffff")) () ")")) (goto_statement "goto LAB_00061f60;" (goto "goto") (statement_identifier "LAB_00061f60") (; ";"))) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" (identifier "param_2") (= "=") (binary_expression "param_2 + 1" (identifier "param_2") (+ "+") (number_literal "1"))) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" (else "else") (compound_statement "{\n          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n          param_2 = param_2 + iVar7;\n        }" ({ "{") (if_statement "if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;" (if "if") (parenthesized_expression "((int)(0x7fffffff - param_2) < iVar7)" (( "(") (binary_expression "(int)(0x7fffffff - param_2) < iVar7" (cast_expression "(int)(0x7fffffff - param_2)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(0x7fffffff - param_2)" (( "(") (binary_expression "0x7fffffff - param_2" (number_literal "0x7fffffff") (- "-") (identifier "param_2")) () ")"))) (< "<") (identifier "iVar7")) () ")")) (goto_statement "goto LAB_00061f60;" (goto "goto") (statement_identifier "LAB_00061f60") (; ";"))) (expression_statement "param_2 = param_2 + iVar7;" (assignment_expression "param_2 = param_2 + iVar7" (identifier "param_2") (= "=") (binary_expression "param_2 + iVar7" (identifier "param_2") (+ "+") (identifier "iVar7"))) (; ";")) (} "}")))) (expression_statement "param_1 = param_1 + iVar6;" (assignment_expression "param_1 = param_1 + iVar6" (identifier "param_1") (= "=") (binary_expression "param_1 + iVar6" (identifier "param_1") (+ "+") (identifier "iVar6"))) (; ";")) (expression_statement "iVar6 = mbsinit(&local_28);" (assignment_expression "iVar6 = mbsinit(&local_28)" (identifier "iVar6") (= "=") (call_expression "mbsinit(&local_28)" (identifier "mbsinit") (argument_list "(&local_28)" (( "(") (pointer_expression "&local_28" (& "&") (identifier "local_28")) () ")")))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar6 == 0)" (( "(") (binary_expression "iVar6 == 0" (identifier "iVar6") (== "==") (number_literal "0")) () ")")) (; ";")) (} "}")) (else_clause "else {\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" (else "else") (compound_statement "{\n      do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);\n    }" ({ "{") (do_statement "do {\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      } while (iVar6 == 0);" (do "do") (compound_statement "{\n        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);\n        if (iVar6 == -1) goto LAB_00061f30;\n        if (iVar6 == -2) goto LAB_00061f48;\n        if (iVar6 == 0) {\n          iVar6 = 1;\n        }\n        iVar7 = wcwidth(local_2c);\n        if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }\n        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;\n        param_2 = param_2 + iVar7;\n        param_1 = param_1 + iVar6;\n        iVar6 = mbsinit(&local_28);\n      }" ({ "{") (expression_statement "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);" (assignment_expression "iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" (identifier "iVar6") (= "=") (call_expression "FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" (identifier "FUN_00068790") (argument_list "(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28)" (( "(") (pointer_expression "&local_2c" (& "&") (identifier "local_2c")) (, ",") (identifier "param_1") (, ",") (binary_expression "(int)pbVar1 - (int)param_1" (cast_expression "(int)pbVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pbVar1")) (- "-") (cast_expression "(int)param_1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_1"))) (, ",") (pointer_expression "&local_28" (& "&") (identifier "local_28")) () ")")))) (; ";")) (if_statement "if (iVar6 == -1) goto LAB_00061f30;" (if "if") (parenthesized_expression "(iVar6 == -1)" (( "(") (binary_expression "iVar6 == -1" (identifier "iVar6") (== "==") (number_literal "-1")) () ")")) (goto_statement "goto LAB_00061f30;" (goto "goto") (statement_identifier "LAB_00061f30") (; ";"))) (if_statement "if (iVar6 == -2) goto LAB_00061f48;" (if "if") (parenthesized_expression "(iVar6 == -2)" (( "(") (binary_expression "iVar6 == -2" (identifier "iVar6") (== "==") (number_literal "-2")) () ")")) (goto_statement "goto LAB_00061f48;" (goto "goto") (statement_identifier "LAB_00061f48") (; ";"))) (if_statement "if (iVar6 == 0) {\n          iVar6 = 1;\n        }" (if "if") (parenthesized_expression "(iVar6 == 0)" (( "(") (binary_expression "iVar6 == 0" (identifier "iVar6") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          iVar6 = 1;\n        }" ({ "{") (expression_statement "iVar6 = 1;" (assignment_expression "iVar6 = 1" (identifier "iVar6") (= "=") (number_literal "1")) (; ";")) (} "}"))) (expression_statement "iVar7 = wcwidth(local_2c);" (assignment_expression "iVar7 = wcwidth(local_2c)" (identifier "iVar7") (= "=") (call_expression "wcwidth(local_2c)" (identifier "wcwidth") (argument_list "(local_2c)" (( "(") (identifier "local_2c") () ")")))) (; ";")) (if_statement "if (iVar7 < 0) {\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }" (if "if") (parenthesized_expression "(iVar7 < 0)" (( "(") (binary_expression "iVar7 < 0" (identifier "iVar7") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n          param_2 = 0xffffffff;\n          goto LAB_00061e40;\n        }" ({ "{") (expression_statement "param_2 = 0xffffffff;" (assignment_expression "param_2 = 0xffffffff" (identifier "param_2") (= "=") (number_literal "0xffffffff")) (; ";")) (goto_statement "goto LAB_00061e40;" (goto "goto") (statement_identifier "LAB_00061e40") (; ";")) (} "}"))) (if_statement "if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;" (if "if") (parenthesized_expression "((int)(0x7fffffff - param_2) < iVar7)" (( "(") (binary_expression "(int)(0x7fffffff - param_2) < iVar7" (cast_expression "(int)(0x7fffffff - param_2)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(0x7fffffff - param_2)" (( "(") (binary_expression "0x7fffffff - param_2" (number_literal "0x7fffffff") (- "-") (identifier "param_2")) () ")"))) (< "<") (identifier "iVar7")) () ")")) (goto_statement "goto LAB_00061f60;" (goto "goto") (statement_identifier "LAB_00061f60") (; ";"))) (expression_statement "param_2 = param_2 + iVar7;" (assignment_expression "param_2 = param_2 + iVar7" (identifier "param_2") (= "=") (binary_expression "param_2 + iVar7" (identifier "param_2") (+ "+") (identifier "iVar7"))) (; ";")) (expression_statement "param_1 = param_1 + iVar6;" (assignment_expression "param_1 = param_1 + iVar6" (identifier "param_1") (= "=") (binary_expression "param_1 + iVar6" (identifier "param_1") (+ "+") (identifier "iVar6"))) (; ";")) (expression_statement "iVar6 = mbsinit(&local_28);" (assignment_expression "iVar6 = mbsinit(&local_28)" (identifier "iVar6") (= "=") (call_expression "mbsinit(&local_28)" (identifier "mbsinit") (argument_list "(&local_28)" (( "(") (pointer_expression "&local_28" (& "&") (identifier "local_28")) () ")")))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(iVar6 == 0)" (( "(") (binary_expression "iVar6 == 0" (identifier "iVar6") (== "==") (number_literal "0")) () ")")) (; ";")) (} "}")))) (goto_statement "goto LAB_00061d31;" (goto "goto") (statement_identifier "LAB_00061d31") (; ";")) (} "}"))))) (expression_statement "param_2 = 0;" (assignment_expression "param_2 = 0" (identifier "param_2") (= "=") (number_literal "0")) (; ";")) (goto_statement "goto LAB_00061e40;" (goto "goto") (statement_identifier "LAB_00061e40") (; ";")) (labeled_statement "LAB_00061f30:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;" (statement_identifier "LAB_00061f30") (: ":") (if_statement "if ((param_3 & 1) != 0) goto LAB_00061e39;" (if "if") (parenthesized_expression "((param_3 & 1) != 0)" (( "(") (binary_expression "(param_3 & 1) != 0" (parenthesized_expression "(param_3 & 1)" (( "(") (binary_expression "param_3 & 1" (identifier "param_3") (& "&") (number_literal "1")) () ")")) (!= "!=") (number_literal "0")) () ")")) (goto_statement "goto LAB_00061e39;" (goto "goto") (statement_identifier "LAB_00061e39") (; ";")))) (labeled_statement "LAB_00061d2b:\n  param_1 = param_1 + 1;" (statement_identifier "LAB_00061d2b") (: ":") (expression_statement "param_1 = param_1 + 1;" (assignment_expression "param_1 = param_1 + 1" (identifier "param_1") (= "=") (binary_expression "param_1 + 1" (identifier "param_1") (+ "+") (number_literal "1"))) (; ";"))) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" (identifier "param_2") (= "=") (binary_expression "param_2 + 1" (identifier "param_2") (+ "+") (number_literal "1"))) (; ";")) (labeled_statement "LAB_00061d31:\n  if (pbVar1 <= param_1) goto LAB_00061e40;" (statement_identifier "LAB_00061d31") (: ":") (if_statement "if (pbVar1 <= param_1) goto LAB_00061e40;" (if "if") (parenthesized_expression "(pbVar1 <= param_1)" (( "(") (binary_expression "pbVar1 <= param_1" (identifier "pbVar1") (<= "<=") (identifier "param_1")) () ")")) (goto_statement "goto LAB_00061e40;" (goto "goto") (statement_identifier "LAB_00061e40") (; ";")))) (goto_statement "goto LAB_00061d3b;" (goto "goto") (statement_identifier "LAB_00061d3b") (; ";")) (labeled_statement "LAB_00061f48:\n  if ((param_3 & 1) != 0) goto LAB_00061e39;" (statement_identifier "LAB_00061f48") (: ":") (if_statement "if ((param_3 & 1) != 0) goto LAB_00061e39;" (if "if") (parenthesized_expression "((param_3 & 1) != 0)" (( "(") (binary_expression "(param_3 & 1) != 0" (parenthesized_expression "(param_3 & 1)" (( "(") (binary_expression "param_3 & 1" (identifier "param_3") (& "&") (number_literal "1")) () ")")) (!= "!=") (number_literal "0")) () ")")) (goto_statement "goto LAB_00061e39;" (goto "goto") (statement_identifier "LAB_00061e39") (; ";")))) (expression_statement "param_2 = param_2 + 1;" (assignment_expression "param_2 = param_2 + 1" (identifier "param_2") (= "=") (binary_expression "param_2 + 1" (identifier "param_2") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "param_1 = pbVar1;" (assignment_expression "param_1 = pbVar1" (identifier "param_1") (= "=") (identifier "pbVar1")) (; ";")) (goto_statement "goto LAB_00061d31;" (goto "goto") (statement_identifier "LAB_00061d31") (; ";")) (labeled_statement "LAB_00061e39:\n  param_2 = 0xffffffff;" (statement_identifier "LAB_00061e39") (: ":") (expression_statement "param_2 = 0xffffffff;" (assignment_expression "param_2 = 0xffffffff" (identifier "param_2") (= "=") (number_literal "0xffffffff")) (; ";"))) (goto_statement "goto LAB_00061e40;" (goto "goto") (statement_identifier "LAB_00061e40") (; ";")) (labeled_statement "LAB_00061f60:\n  param_2 = 0x7fffffff;" (statement_identifier "LAB_00061f60") (: ":") (expression_statement "param_2 = 0x7fffffff;" (assignment_expression "param_2 = 0x7fffffff" (identifier "param_2") (= "=") (number_literal "0x7fffffff")) (; ";"))) (labeled_statement "LAB_00061e40:\n  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }" (statement_identifier "LAB_00061e40") (: ":") (if_statement "if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {\n                    \n    FUN_0006c970();\n  }" (if "if") (parenthesized_expression "(local_20 != *(int *)(in_GS_OFFSET + 0x14))" (( "(") (binary_expression "local_20 != *(int *)(in_GS_OFFSET + 0x14)" (identifier "local_20") (!= "!=") (pointer_expression "*(int *)(in_GS_OFFSET + 0x14)" (* "*") (cast_expression "(int *)(in_GS_OFFSET + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_GS_OFFSET + 0x14)" (( "(") (binary_expression "in_GS_OFFSET + 0x14" (identifier "in_GS_OFFSET") (+ "+") (number_literal "0x14")) () ")"))))) () ")")) (compound_statement "{\n                    \n    FUN_0006c970();\n  }" ({ "{") (expression_statement "FUN_0006c970();" (call_expression "FUN_0006c970()" (identifier "FUN_0006c970") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))) (return_statement "return param_2;" (return "return") (identifier "param_2") (; ";")) (} "}")))

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

int function_1(char *var_2,size_t var_3,int var_8)

{
  type_1 *var_6;
  int var_18;
  type_1 var_12;
  type_2 var_9;
  type_3 uVar5;
  size_t var_5;
  size_t var_11;
  int var_15;
  type_2 **ppuVar9;
  type_1 *var_10;
  int var_1;
  type_4 wc;
  type_5 mbstate;
  
  var_18 = *(int *)(var_1 + 0x14);
  var_6 = (type_1 *)(var_2 + var_3);
  var_5 = var_4();
  if (var_5 < 2) {
    if (var_2 < var_6) {
      ppuVar9 = var_7();
      uVar5 = var_8 & 2U;
      if ((var_8 & 2U) == 0) {
        do {
          var_3 = uVar5;
          var_10 = (type_1 *)var_2 + 1;
          var_9 = (*ppuVar9)[(type_1)*var_2];
          if (((var_9 & 0x4000) != 0) || ((var_9 & 2) == 0)) {
            if (var_3 == 0x7fffffff) break;
            var_3 = var_3 + 1;
          }
          uVar5 = var_3;
          var_2 = (char *)var_10;
        } while (var_6 != var_10);
      }
      else {
        var_11 = 0;
        do {
          if ((*(type_1 *)((int)*ppuVar9 + (type_3)(type_1)var_2[var_11] * 2 + 1) & 0x40) == 0)
          goto LAB_00061e39;
          if (var_11 == 0x7fffffff) goto LAB_00061f60;
          var_11 = var_11 + 1;
        } while (var_3 != var_11);
      }
      goto LAB_00061e40;
    }
  }
  else if (var_2 < var_6) {
    var_3 = 0;
LAB_00061d3b:
    var_12 = *var_2;
    if ((char)var_12 < '@') {
      if (((char)var_12 < '%') && (3 < (type_1)(var_12 - 0x20))) goto LAB_00061d51;
      goto LAB_00061d2b;
    }
    if (('@' < (char)var_12) && (((char)var_12 < '`' || ((type_1)(var_12 + 0x9f) < 0x1e))))
    goto LAB_00061d2b;
LAB_00061d51:
    mbstate.__count = 0;
    mbstate.__value.__wch = 0;
    if ((var_8 & 2U) == 0) {
      do {
        var_11 = var_13(&wc,var_2,(int)var_6 - (int)var_2,&mbstate);
        if (var_11 == 0xffffffff) goto LAB_00061f30;
        if (var_11 == 0xfffffffe) goto LAB_00061f48;
        if (var_11 == 0) {
          var_11 = 1;
        }
        var_15 = var_14(wc);
        if (var_15 < 0) {
          var_15 = var_16(wc);
          if (var_15 == 0) {
            if (var_3 == 0x7fffffff) goto LAB_00061f60;
            var_3 = var_3 + 1;
          }
        }
        else {
          if ((int)(0x7fffffff - var_3) < var_15) goto LAB_00061f60;
          var_3 = var_3 + var_15;
        }
        var_2 = (char *)((type_1 *)var_2 + var_11);
        var_15 = var_17((type_5 *)&mbstate);
      } while (var_15 == 0);
    }
    else {
      do {
        var_11 = var_13(&wc,var_2,(int)var_6 - (int)var_2,&mbstate);
        if (var_11 == 0xffffffff) goto LAB_00061f30;
        if (var_11 == 0xfffffffe) goto LAB_00061f48;
        if (var_11 == 0) {
          var_11 = 1;
        }
        var_15 = var_14(wc);
        if (var_15 < 0) {
          var_3 = 0xffffffff;
          goto LAB_00061e40;
        }
        if ((int)(0x7fffffff - var_3) < var_15) goto LAB_00061f60;
        var_3 = var_3 + var_15;
        var_2 = (char *)((type_1 *)var_2 + var_11);
        var_15 = var_17((type_5 *)&mbstate);
      } while (var_15 == 0);
    }
    goto LAB_00061d31;
  }
  var_3 = 0;
  goto LAB_00061e40;
LAB_00061f30:
  if ((var_8 & 1U) != 0) goto LAB_00061e39;
LAB_00061d2b:
  var_2 = (char *)((type_1 *)var_2 + 1);
  var_3 = var_3 + 1;
LAB_00061d31:
  if (var_6 <= var_2) goto LAB_00061e40;
  goto LAB_00061d3b;
LAB_00061f48:
  if ((var_8 & 1U) != 0) goto LAB_00061e39;
  var_3 = var_3 + 1;
  var_2 = (char *)var_6;
  goto LAB_00061d31;
LAB_00061e39:
  var_3 = 0xffffffff;
  goto LAB_00061e40;
LAB_00061f60:
  var_3 = 0x7fffffff;
LAB_00061e40:
  if (var_18 != *(int *)(var_1 + 0x14)) {
                    /* WARNING: Subroutine does not return */
    var_19();
  }
  return var_3;
}


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

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

uint MASKED(byte *param_1,uint param_2,uint param_3)

{
  byte *pbVar1;
  byte bVar2;
  ushort uVar3;
  size_t sVar4;
  uint uVar5;
  int iVar6;
  int iVar7;
  ushort **ppuVar8;
  byte *pbVar9;
  int in_GS_OFFSET;
  wchar_t local_2c;
  mbstate_t local_28;
  int local_20;
  undefined4 uStack_14;
  
  uStack_14 = 0x61cc9;
  local_20 = *(int *)(in_GS_OFFSET + 0x14);
  pbVar1 = param_1 + param_2;
  sVar4 = __ctype_get_mb_cur_max();
  if (sVar4 < 2) {
    if (param_1 < pbVar1) {
      ppuVar8 = __ctype_b_loc();
      uVar5 = param_3 & 2;
      if ((param_3 & 2) == 0) {
        do {
          param_2 = uVar5;
          pbVar9 = param_1 + 1;
          uVar3 = (*ppuVar8)[*param_1];
          if (((uVar3 & 0x4000) != 0) || ((uVar3 & 2) == 0)) {
            if (param_2 == 0x7fffffff) break;
            param_2 = param_2 + 1;
          }
          uVar5 = param_2;
          param_1 = pbVar9;
        } while (pbVar1 != pbVar9);
      }
      else {
        uVar5 = 0;
        do {
          if ((*(byte *)((int)*ppuVar8 + (uint)param_1[uVar5] * 2 + 1) & 0x40) == 0)
          goto LAB_00061e39;
          if (uVar5 == 0x7fffffff) goto LAB_00061f60;
          uVar5 = uVar5 + 1;
        } while (param_2 != uVar5);
      }
      goto LAB_00061e40;
    }
  }
  else if (param_1 < pbVar1) {
    param_2 = 0;
LAB_00061d3b:
    bVar2 = *param_1;
    if ((char)bVar2 < '@') {
      if (((char)bVar2 < '%') && (3 < (byte)(bVar2 - 0x20))) goto LAB_00061d51;
      goto LAB_00061d2b;
    }
    if (('@' < (char)bVar2) && (((char)bVar2 < '`' || ((byte)(bVar2 + 0x9f) < 0x1e))))
    goto LAB_00061d2b;
LAB_00061d51:
    local_28.__count = 0;
    local_28.__value.__wch = 0;
    if ((param_3 & 2) == 0) {
      do {
        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);
        if (iVar6 == -1) goto LAB_00061f30;
        if (iVar6 == -2) goto LAB_00061f48;
        if (iVar6 == 0) {
          iVar6 = 1;
        }
        iVar7 = wcwidth(local_2c);
        if (iVar7 < 0) {
          iVar7 = iswcntrl(local_2c);
          if (iVar7 == 0) {
            if (param_2 == 0x7fffffff) goto LAB_00061f60;
            param_2 = param_2 + 1;
          }
        }
        else {
          if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;
          param_2 = param_2 + iVar7;
        }
        param_1 = param_1 + iVar6;
        iVar6 = mbsinit(&local_28);
      } while (iVar6 == 0);
    }
    else {
      do {
        iVar6 = FUN_00068790(&local_2c,param_1,(int)pbVar1 - (int)param_1,&local_28);
        if (iVar6 == -1) goto LAB_00061f30;
        if (iVar6 == -2) goto LAB_00061f48;
        if (iVar6 == 0) {
          iVar6 = 1;
        }
        iVar7 = wcwidth(local_2c);
        if (iVar7 < 0) {
          param_2 = 0xffffffff;
          goto LAB_00061e40;
        }
        if ((int)(0x7fffffff - param_2) < iVar7) goto LAB_00061f60;
        param_2 = param_2 + iVar7;
        param_1 = param_1 + iVar6;
        iVar6 = mbsinit(&local_28);
      } while (iVar6 == 0);
    }
    goto LAB_00061d31;
  }
  param_2 = 0;
  goto LAB_00061e40;
LAB_00061f30:
  if ((param_3 & 1) != 0) goto LAB_00061e39;
LAB_00061d2b:
  param_1 = param_1 + 1;
  param_2 = param_2 + 1;
LAB_00061d31:
  if (pbVar1 <= param_1) goto LAB_00061e40;
  goto LAB_00061d3b;
LAB_00061f48:
  if ((param_3 & 1) != 0) goto LAB_00061e39;
  param_2 = param_2 + 1;
  param_1 = pbVar1;
  goto LAB_00061d31;
LAB_00061e39:
  param_2 = 0xffffffff;
  goto LAB_00061e40;
LAB_00061f60:
  param_2 = 0x7fffffff;
LAB_00061e40:
  if (local_20 != *(int *)(in_GS_OFFSET + 0x14)) {
                    /* WARNING: Subroutine does not return */
    FUN_0006c970();
  }
  return param_2;
}

