
void * sqlite3HashInsert(Hash *pH,char *pKey,void *data)

{
  void *pvVar1;
  HashElem *pNew;
  HashElem *pHVar2;
  uint uVar3;
  int iVar4;
  uint uVar5;
  HashElem *pHVar6;
  _ht *p_Var7;
  long in_FS_OFFSET;
  uint h;
  long local_40;
  
  local_40 = *(long *)(in_FS_OFFSET + 0x28);
  pHVar6 = findElementWithHash(pH,pKey,&h);
  pvVar1 = pHVar6->data;
  if (pvVar1 == (void *)0x0) {
    if ((data != (void *)0x0) &&
       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {
      pHVar6->pKey = pKey;
      pHVar6->data = data;
      uVar3 = pH->count + 1;
      pH->count = uVar3;
      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {
        uVar3 = uVar3 * 2;
        if (0x40 < uVar3) {
          uVar3 = 0x40;
        }
        if (pH->htsize != uVar3) {
          sqlite3BeginBenignMalloc();
          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);
          sqlite3EndBenignMalloc();
          if (p_Var7 != (_ht *)0x0) {
            sqlite3_free(pH->ht);
            pH->ht = p_Var7;
            iVar4 = sqlite3MallocSize(p_Var7);
            uVar3 = (uint)((ulong)(long)iVar4 >> 4);
            pH->htsize = uVar3;
            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);
            pNew = pH->first;
            pH->first = (HashElem *)0x0;
            while (pNew != (HashElem *)0x0) {
              uVar5 = strHash(pNew->pKey);
              pHVar2 = pNew->next;
              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);
              pNew = pHVar2;
            }
            uVar3 = strHash(pKey);
            h = uVar3 % pH->htsize;
          }
        }
      }
      p_Var7 = pH->ht;
      if (p_Var7 != (_ht *)0x0) {
        p_Var7 = p_Var7 + h;
      }
      insertElement(pH,p_Var7,pHVar6);
      data = pvVar1;
    }
  }
  else if (data == (void *)0x0) {
    if (pHVar6->prev == (HashElem *)0x0) {
      pH->first = pHVar6->next;
    }
    else {
      pHVar6->prev->next = pHVar6->next;
    }
    if (pHVar6->next != (HashElem *)0x0) {
      pHVar6->next->prev = pHVar6->prev;
    }
    if (pH->ht != (_ht *)0x0) {
      p_Var7 = pH->ht + h;
      if (pHVar6 == p_Var7->chain) {
        p_Var7->chain = pHVar6->next;
      }
      p_Var7->count = p_Var7->count - 1;
    }
    sqlite3_free(pHVar6);
    uVar3 = pH->count - 1;
    pH->count = uVar3;
    data = pvVar1;
    if (uVar3 == 0) {
      sqlite3HashClear(pH);
    }
  }
  else {
    pHVar6->data = data;
    pHVar6->pKey = pKey;
    data = pvVar1;
  }
  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {
    return data;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail();
}



long FUN_0011be09(uint *param_1,long param_2,long param_3)

{
  long lVar1;
  undefined8 *puVar2;
  undefined8 *puVar3;
  uint uVar4;
  int iVar5;
  long *plVar6;
  long lVar7;
  void *__s;
  ulong uVar8;
  ulong uVar9;
  int *piVar10;
  long lVar11;
  long in_FS_OFFSET;
  uint local_44;
  long local_40;
  
  local_40 = *(long *)(in_FS_OFFSET + 0x28);
  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);
  lVar1 = plVar6[2];
  if (lVar1 == 0) {
    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {
      *(long *)(lVar7 + 0x18) = param_2;
      *(long *)(lVar7 + 0x10) = param_3;
      uVar4 = param_1[1] + 1;
      param_1[1] = uVar4;
      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {
        uVar4 = uVar4 * 2;
        if (0x40 < uVar4) {
          uVar4 = 0x40;
        }
        if (*param_1 != uVar4) {
          FUN_0010cba2();
          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);
          FUN_0010cbbb();
          if (__s != (void *)0x0) {
            sqlite3_free(*(undefined8 *)(param_1 + 4));
            *(void **)(param_1 + 4) = __s;
            iVar5 = FUN_0010ccbd(__s);
            uVar8 = (ulong)(long)iVar5 >> 4;
            *param_1 = (uint)uVar8;
            memset(__s,0,(uVar8 & 0xffffffff) << 4);
            puVar2 = *(undefined8 **)(param_1 + 2);
            param_1[2] = 0;
            param_1[3] = 0;
            while (puVar2 != (undefined8 *)0x0) {
              uVar9 = FUN_0010d806(puVar2[3]);
              puVar3 = (undefined8 *)*puVar2;
              FUN_0010d840(param_1,(void *)((long)__s +
                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),
                           puVar2);
              puVar2 = puVar3;
            }
            uVar8 = FUN_0010d806(param_2);
            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);
          }
        }
      }
      lVar11 = *(long *)(param_1 + 4);
      if (lVar11 != 0) {
        lVar11 = lVar11 + (ulong)local_44 * 0x10;
      }
      FUN_0010d840(param_1,lVar11,lVar7);
      param_3 = lVar1;
    }
  }
  else if (param_3 == 0) {
    if ((long *)plVar6[1] == (long *)0x0) {
      *(long *)(param_1 + 2) = *plVar6;
    }
    else {
      *(long *)plVar6[1] = *plVar6;
    }
    if (*plVar6 != 0) {
      *(long *)(*plVar6 + 8) = plVar6[1];
    }
    if (*(long *)(param_1 + 4) != 0) {
      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));
      if (plVar6 == *(long **)(piVar10 + 2)) {
        *(long *)(piVar10 + 2) = *plVar6;
      }
      *piVar10 = *piVar10 + -1;
    }
    sqlite3_free(plVar6);
    uVar4 = param_1[1];
    param_1[1] = uVar4 - 1;
    param_3 = lVar1;
    if (uVar4 - 1 == 0) {
      FUN_0011ad1b(param_1);
    }
  }
  else {
    plVar6[2] = param_3;
    plVar6[3] = param_2;
    param_3 = lVar1;
  }
  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {
    return param_3;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail();
}


PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x28
MOV RBP,RDI
MOV R12,RSI
MOV R14,RDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x18],RAX
XOR EAX,EAX
LEA RDX,[RSP + 0x14]
CALL 0x0010d8aa
MOV RBX,qword ptr [RAX + 0x10]
TEST RBX,RBX
JZ 0x0011beec
TEST R14,R14
JZ 0x0011be7a
MOV qword ptr [RAX + 0x10],R14
MOV qword ptr [RAX + 0x18],R12
MOV RAX,RBX
MOV RCX,qword ptr [RSP + 0x18]
XOR RCX,qword ptr FS:[0x28]
JNZ 0x0011c031
ADD RSP,0x28
POP RBX
POP RBP
POP R12
POP R13
POP R14
POP R15
RET
MOV EDX,dword ptr [RSP + 0x14]
MOV RCX,qword ptr [RAX + 0x8]
TEST RCX,RCX
JZ 0x0011beda
MOV RSI,qword ptr [RAX]
MOV qword ptr [RCX],RSI
MOV RCX,qword ptr [RAX]
TEST RCX,RCX
JZ 0x0011be9d
MOV RSI,qword ptr [RAX + 0x8]
MOV qword ptr [RCX + 0x8],RSI
MOV RCX,qword ptr [RBP + 0x10]
TEST RCX,RCX
JZ 0x0011beb8
MOV EDX,EDX
SHL RDX,0x4
ADD RDX,RCX
CMP RAX,qword ptr [RDX + 0x8]
JZ 0x0011bee3
SUB dword ptr [RDX],0x1
MOV RDI,RAX
CALL 0x0010c8d0
MOV EAX,dword ptr [RBP + 0x4]
SUB EAX,0x1
MOV dword ptr [RBP + 0x4],EAX
TEST EAX,EAX
JNZ 0x0011be54
MOV RDI,RBP
CALL 0x0011ad1b
JMP 0x0011be54
MOV RCX,qword ptr [RAX]
MOV qword ptr [RBP + 0x8],RCX
JMP 0x0011be8d
MOV RCX,qword ptr [RAX]
MOV qword ptr [RDX + 0x8],RCX
JMP 0x0011beb5
TEST R14,R14
JZ 0x0011c029
MOV EDI,0x20
CALL 0x0011bd0f
MOV R13,RAX
TEST RAX,RAX
JNZ 0x0011bf0f
MOV RBX,R14
JMP 0x0011be54
MOV qword ptr [RAX + 0x18],R12
MOV qword ptr [RAX + 0x10],R14
MOV EAX,dword ptr [RBP + 0x4]
ADD EAX,0x1
MOV dword ptr [RBP + 0x4],EAX
CMP EAX,0x9
JBE 0x0011bf2f
MOV EDX,dword ptr [RBP]
LEA ECX,[RDX + RDX*0x1]
CMP EAX,ECX
JA 0x0011bf53
MOV RSI,qword ptr [RBP + 0x10]
TEST RSI,RSI
JZ 0x0011bf43
MOV EAX,dword ptr [RSP + 0x14]
SHL RAX,0x4
ADD RSI,RAX
MOV RDX,R13
MOV RDI,RBP
CALL 0x0010d840
JMP 0x0011be54
LEA R14D,[RAX + RAX*0x1]
MOV EAX,R14D
SHL RAX,0x4
CMP RAX,0x401
MOV EAX,0x40
CMOVNC R14D,EAX
CMP EDX,R14D
JZ 0x0011bf2f
CALL 0x0010cba2
MOV EDI,R14D
SHL RDI,0x4
CALL 0x0011bd0f
MOV R15,RAX
MOV qword ptr [RSP],RAX
CALL 0x0010cbbb
TEST R15,R15
JZ 0x0011bf2f
MOV RDI,qword ptr [RBP + 0x10]
CALL 0x0010c8d0
MOV qword ptr [RBP + 0x10],R15
MOV RDI,R15
CALL 0x0010ccbd
CDQE
SHR RAX,0x4
MOV dword ptr [RSP + 0xc],EAX
MOV dword ptr [RBP],EAX
MOV EDX,EAX
SHL RDX,0x4
MOV ESI,0x0
MOV RDI,R15
CALL 0x0010c180
MOV R14,qword ptr [RBP + 0x8]
MOV qword ptr [RBP + 0x8],0x0
TEST R14,R14
JZ 0x0011c010
MOV RDI,qword ptr [R14 + 0x18]
CALL 0x0010d806
MOV R15,qword ptr [R14]
MOV EDX,0x0
DIV dword ptr [RSP + 0xc]
MOV EDX,EDX
SHL RDX,0x4
MOV RAX,qword ptr [RSP]
LEA RSI,[RAX + RDX*0x1]
MOV RDX,R14
MOV RDI,RBP
CALL 0x0010d840
MOV R14,R15
TEST R15,R15
JNZ 0x0011bfda
MOV RDI,R12
CALL 0x0010d806
MOV EDX,0x0
DIV dword ptr [RBP]
MOV dword ptr [RSP + 0x14],EDX
JMP 0x0011bf2f
MOV RBX,R14
JMP 0x0011be54
CALL 0x0010c0d0
(translation_unit "long FUN_0011be09(uint *param_1,long param_2,long param_3)\n\n{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail();\n}\n\n" (function_definition "long FUN_0011be09(uint *param_1,long param_2,long param_3)\n\n{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail();\n}" (sized_type_specifier "long" long) (function_declarator "FUN_0011be09(uint *param_1,long param_2,long param_3)" identifier (parameter_list "(uint *param_1,long param_2,long param_3)" ( (parameter_declaration "uint *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "long param_2" (sized_type_specifier "long" long) identifier) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) ))) (compound_statement "{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail();\n}" { (declaration "long lVar1;" (sized_type_specifier "long" long) identifier ;) (declaration "undefined8 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined8 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "long *plVar6;" (sized_type_specifier "long" long) (pointer_declarator "*plVar6" * identifier) ;) (declaration "long lVar7;" (sized_type_specifier "long" long) identifier ;) (declaration "void *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "ulong uVar8;" type_identifier identifier ;) (declaration "ulong uVar9;" type_identifier identifier ;) (declaration "int *piVar10;" primitive_type (pointer_declarator "*piVar10" * identifier) ;) (declaration "long lVar11;" (sized_type_specifier "long" long) identifier ;) (declaration "long in_FS_OFFSET;" (sized_type_specifier "long" long) identifier ;) (declaration "uint local_44;" type_identifier identifier ;) (declaration "long local_40;" (sized_type_specifier "long" long) identifier ;) (expression_statement "local_40 = *(long *)(in_FS_OFFSET + 0x28);" (assignment_expression "local_40 = *(long *)(in_FS_OFFSET + 0x28)" identifier = (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" * (cast_expression "(long *)(in_FS_OFFSET + 0x28)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_FS_OFFSET + 0x28)" ( (binary_expression "in_FS_OFFSET + 0x28" identifier + number_literal) ))))) ;) (expression_statement "plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);" (assignment_expression "plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44)" identifier = (cast_expression "(long *)FUN_0010d8aa(param_1,param_2,&local_44)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0010d8aa(param_1,param_2,&local_44)" identifier (argument_list "(param_1,param_2,&local_44)" ( identifier , identifier , (pointer_expression "&local_44" & identifier) ))))) ;) (expression_statement "lVar1 = plVar6[2];" (assignment_expression "lVar1 = plVar6[2]" identifier = (subscript_expression "plVar6[2]" identifier [ number_literal ])) ;) (if_statement "if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" if (parenthesized_expression "(lVar1 == 0)" ( (binary_expression "lVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }" { (if_statement "if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }" if (parenthesized_expression "((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0))" ( (binary_expression "(param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)" (parenthesized_expression "(param_3 != 0)" ( (binary_expression "param_3 != 0" identifier != number_literal) )) && (parenthesized_expression "(lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)" ( (comma_expression "lVar7 = FUN_0011bd0f(0x20), lVar7 != 0" (assignment_expression "lVar7 = FUN_0011bd0f(0x20)" identifier = (call_expression "FUN_0011bd0f(0x20)" identifier (argument_list "(0x20)" ( number_literal )))) , (binary_expression "lVar7 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }" { (expression_statement "*(long *)(lVar7 + 0x18) = param_2;" (assignment_expression "*(long *)(lVar7 + 0x18) = param_2" (pointer_expression "*(long *)(lVar7 + 0x18)" * (cast_expression "(long *)(lVar7 + 0x18)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar7 + 0x18)" ( (binary_expression "lVar7 + 0x18" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(long *)(lVar7 + 0x10) = param_3;" (assignment_expression "*(long *)(lVar7 + 0x10) = param_3" (pointer_expression "*(long *)(lVar7 + 0x10)" * (cast_expression "(long *)(lVar7 + 0x10)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar7 + 0x10)" ( (binary_expression "lVar7 + 0x10" identifier + number_literal) )))) = identifier) ;) (expression_statement "uVar4 = param_1[1] + 1;" (assignment_expression "uVar4 = param_1[1] + 1" identifier = (binary_expression "param_1[1] + 1" (subscript_expression "param_1[1]" identifier [ number_literal ]) + number_literal)) ;) (expression_statement "param_1[1] = uVar4;" (assignment_expression "param_1[1] = uVar4" (subscript_expression "param_1[1]" identifier [ number_literal ]) = identifier) ;) (if_statement "if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }" if (parenthesized_expression "((9 < uVar4) && (*param_1 * 2 < uVar4))" ( (binary_expression "(9 < uVar4) && (*param_1 * 2 < uVar4)" (parenthesized_expression "(9 < uVar4)" ( (binary_expression "9 < uVar4" number_literal < identifier) )) && (parenthesized_expression "(*param_1 * 2 < uVar4)" ( (binary_expression "*param_1 * 2 < uVar4" (binary_expression "*param_1 * 2" (pointer_expression "*param_1" * identifier) * number_literal) < identifier) ))) )) (compound_statement "{\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }" { (expression_statement "uVar4 = uVar4 * 2;" (assignment_expression "uVar4 = uVar4 * 2" identifier = (binary_expression "uVar4 * 2" identifier * number_literal)) ;) (if_statement "if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }" if (parenthesized_expression "(0x40 < uVar4)" ( (binary_expression "0x40 < uVar4" number_literal < identifier) )) (compound_statement "{\n          uVar4 = 0x40;\n        }" { (expression_statement "uVar4 = 0x40;" (assignment_expression "uVar4 = 0x40" identifier = number_literal) ;) })) (if_statement "if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }" if (parenthesized_expression "(*param_1 != uVar4)" ( (binary_expression "*param_1 != uVar4" (pointer_expression "*param_1" * identifier) != identifier) )) (compound_statement "{\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }" { (expression_statement "FUN_0010cba2();" (call_expression "FUN_0010cba2()" identifier (argument_list "()" ( ))) ;) (expression_statement "__s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);" (assignment_expression "__s = (void *)FUN_0011bd0f((ulong)uVar4 << 4)" identifier = (cast_expression "(void *)FUN_0011bd0f((ulong)uVar4 << 4)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0011bd0f((ulong)uVar4 << 4)" identifier (argument_list "((ulong)uVar4 << 4)" ( (binary_expression "(ulong)uVar4 << 4" (cast_expression "(ulong)uVar4" ( (type_descriptor "ulong" type_identifier) ) identifier) << number_literal) ))))) ;) (expression_statement "FUN_0010cbbb();" (call_expression "FUN_0010cbbb()" identifier (argument_list "()" ( ))) ;) (if_statement "if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }" if (parenthesized_expression "(__s != (void *)0x0)" ( (binary_expression "__s != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }" { (expression_statement "sqlite3_free(*(undefined8 *)(param_1 + 4));" (call_expression "sqlite3_free(*(undefined8 *)(param_1 + 4))" identifier (argument_list "(*(undefined8 *)(param_1 + 4))" ( (pointer_expression "*(undefined8 *)(param_1 + 4)" * (cast_expression "(undefined8 *)(param_1 + 4)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) ))) ;) (expression_statement "*(void **)(param_1 + 4) = __s;" (assignment_expression "*(void **)(param_1 + 4) = __s" (pointer_expression "*(void **)(param_1 + 4)" * (cast_expression "(void **)(param_1 + 4)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) = identifier) ;) (expression_statement "iVar5 = FUN_0010ccbd(__s);" (assignment_expression "iVar5 = FUN_0010ccbd(__s)" identifier = (call_expression "FUN_0010ccbd(__s)" identifier (argument_list "(__s)" ( identifier )))) ;) (expression_statement "uVar8 = (ulong)(long)iVar5 >> 4;" (assignment_expression "uVar8 = (ulong)(long)iVar5 >> 4" identifier = (binary_expression "(ulong)(long)iVar5 >> 4" (cast_expression "(ulong)(long)iVar5" ( (type_descriptor "ulong" type_identifier) ) (cast_expression "(long)iVar5" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) >> number_literal)) ;) (expression_statement "*param_1 = (uint)uVar8;" (assignment_expression "*param_1 = (uint)uVar8" (pointer_expression "*param_1" * identifier) = (cast_expression "(uint)uVar8" ( (type_descriptor "uint" type_identifier) ) identifier)) ;) (expression_statement "memset(__s,0,(uVar8 & 0xffffffff) << 4);" (call_expression "memset(__s,0,(uVar8 & 0xffffffff) << 4)" identifier (argument_list "(__s,0,(uVar8 & 0xffffffff) << 4)" ( identifier , number_literal , (binary_expression "(uVar8 & 0xffffffff) << 4" (parenthesized_expression "(uVar8 & 0xffffffff)" ( (binary_expression "uVar8 & 0xffffffff" identifier & number_literal) )) << number_literal) ))) ;) (expression_statement "puVar2 = *(undefined8 **)(param_1 + 2);" (assignment_expression "puVar2 = *(undefined8 **)(param_1 + 2)" identifier = (pointer_expression "*(undefined8 **)(param_1 + 2)" * (cast_expression "(undefined8 **)(param_1 + 2)" ( (type_descriptor "undefined8 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 2)" ( (binary_expression "param_1 + 2" identifier + number_literal) ))))) ;) (expression_statement "param_1[2] = 0;" (assignment_expression "param_1[2] = 0" (subscript_expression "param_1[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[3] = 0;" (assignment_expression "param_1[3] = 0" (subscript_expression "param_1[3]" identifier [ number_literal ]) = number_literal) ;) (while_statement "while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }" while (parenthesized_expression "(puVar2 != (undefined8 *)0x0)" ( (binary_expression "puVar2 != (undefined8 *)0x0" identifier != (cast_expression "(undefined8 *)0x0" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }" { (expression_statement "uVar9 = FUN_0010d806(puVar2[3]);" (assignment_expression "uVar9 = FUN_0010d806(puVar2[3])" identifier = (call_expression "FUN_0010d806(puVar2[3])" identifier (argument_list "(puVar2[3])" ( (subscript_expression "puVar2[3]" identifier [ number_literal ]) )))) ;) (expression_statement "puVar3 = (undefined8 *)*puVar2;" (assignment_expression "puVar3 = (undefined8 *)*puVar2" identifier = (cast_expression "(undefined8 *)*puVar2" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar2" * identifier))) ;) (expression_statement "FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);" (call_expression "FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2)" identifier (argument_list "(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2)" ( identifier , (cast_expression "(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10)" ( (binary_expression "(long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10" (cast_expression "(long)__s" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) + (binary_expression "((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10" (parenthesized_expression "((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff))" ( (binary_expression "(uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)" (parenthesized_expression "(uVar9 & 0xffffffff)" ( (binary_expression "uVar9 & 0xffffffff" identifier & number_literal) )) % (parenthesized_expression "(uVar8 & 0xffffffff)" ( (binary_expression "uVar8 & 0xffffffff" identifier & number_literal) ))) )) * number_literal)) ))) , identifier ))) ;) (expression_statement "puVar2 = puVar3;" (assignment_expression "puVar2 = puVar3" identifier = identifier) ;) })) (expression_statement "uVar8 = FUN_0010d806(param_2);" (assignment_expression "uVar8 = FUN_0010d806(param_2)" identifier = (call_expression "FUN_0010d806(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);" (assignment_expression "local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1)" identifier = (call_expression "(uint)((uVar8 & 0xffffffff) % (ulong)*param_1)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "((uVar8 & 0xffffffff) % (ulong)*param_1)" ( (binary_expression "(uVar8 & 0xffffffff) % (ulong)*param_1" (binary_expression "(uVar8 & 0xffffffff) % (ulong)" (parenthesized_expression "(uVar8 & 0xffffffff)" ( (binary_expression "uVar8 & 0xffffffff" identifier & number_literal) )) % (parenthesized_expression "(ulong)" ( identifier ))) * identifier) )))) ;) })) })) })) (expression_statement "lVar11 = *(long *)(param_1 + 4);" (assignment_expression "lVar11 = *(long *)(param_1 + 4)" identifier = (pointer_expression "*(long *)(param_1 + 4)" * (cast_expression "(long *)(param_1 + 4)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) (if_statement "if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }" if (parenthesized_expression "(lVar11 != 0)" ( (binary_expression "lVar11 != 0" identifier != number_literal) )) (compound_statement "{\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }" { (expression_statement "lVar11 = lVar11 + (ulong)local_44 * 0x10;" (assignment_expression "lVar11 = lVar11 + (ulong)local_44 * 0x10" identifier = (binary_expression "lVar11 + (ulong)local_44 * 0x10" identifier + (binary_expression "(ulong)local_44 * 0x10" (cast_expression "(ulong)local_44" ( (type_descriptor "ulong" type_identifier) ) identifier) * number_literal))) ;) })) (expression_statement "FUN_0010d840(param_1,lVar11,lVar7);" (call_expression "FUN_0010d840(param_1,lVar11,lVar7)" identifier (argument_list "(param_1,lVar11,lVar7)" ( identifier , identifier , identifier ))) ;) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" identifier = identifier) ;) })) }) (else_clause "else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" else (if_statement "if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" if (parenthesized_expression "(param_3 == 0)" ( (binary_expression "param_3 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }" { (if_statement "if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }" if (parenthesized_expression "((long *)plVar6[1] == (long *)0x0)" ( (binary_expression "(long *)plVar6[1] == (long *)0x0" (cast_expression "(long *)plVar6[1]" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (subscript_expression "plVar6[1]" identifier [ number_literal ])) == (cast_expression "(long *)0x0" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      *(long *)(param_1 + 2) = *plVar6;\n    }" { (expression_statement "*(long *)(param_1 + 2) = *plVar6;" (assignment_expression "*(long *)(param_1 + 2) = *plVar6" (pointer_expression "*(long *)(param_1 + 2)" * (cast_expression "(long *)(param_1 + 2)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 2)" ( (binary_expression "param_1 + 2" identifier + number_literal) )))) = (pointer_expression "*plVar6" * identifier)) ;) }) (else_clause "else {\n      *(long *)plVar6[1] = *plVar6;\n    }" else (compound_statement "{\n      *(long *)plVar6[1] = *plVar6;\n    }" { (expression_statement "*(long *)plVar6[1] = *plVar6;" (assignment_expression "*(long *)plVar6[1] = *plVar6" (pointer_expression "*(long *)plVar6[1]" * (cast_expression "(long *)plVar6[1]" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (subscript_expression "plVar6[1]" identifier [ number_literal ]))) = (pointer_expression "*plVar6" * identifier)) ;) }))) (if_statement "if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }" if (parenthesized_expression "(*plVar6 != 0)" ( (binary_expression "*plVar6 != 0" (pointer_expression "*plVar6" * identifier) != number_literal) )) (compound_statement "{\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }" { (expression_statement "*(long *)(*plVar6 + 8) = plVar6[1];" (assignment_expression "*(long *)(*plVar6 + 8) = plVar6[1]" (pointer_expression "*(long *)(*plVar6 + 8)" * (cast_expression "(long *)(*plVar6 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*plVar6 + 8)" ( (binary_expression "*plVar6 + 8" (pointer_expression "*plVar6" * identifier) + number_literal) )))) = (subscript_expression "plVar6[1]" identifier [ number_literal ])) ;) })) (if_statement "if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }" if (parenthesized_expression "(*(long *)(param_1 + 4) != 0)" ( (binary_expression "*(long *)(param_1 + 4) != 0" (pointer_expression "*(long *)(param_1 + 4)" * (cast_expression "(long *)(param_1 + 4)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }" { (expression_statement "piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));" (assignment_expression "piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" identifier = (cast_expression "(int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" ( (binary_expression "(ulong)local_44 * 0x10 + *(long *)(param_1 + 4)" (binary_expression "(ulong)local_44 * 0x10" (cast_expression "(ulong)local_44" ( (type_descriptor "ulong" type_identifier) ) identifier) * number_literal) + (pointer_expression "*(long *)(param_1 + 4)" * (cast_expression "(long *)(param_1 + 4)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) )))) ;) (if_statement "if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }" if (parenthesized_expression "(plVar6 == *(long **)(piVar10 + 2))" ( (binary_expression "plVar6 == *(long **)(piVar10 + 2)" identifier == (pointer_expression "*(long **)(piVar10 + 2)" * (cast_expression "(long **)(piVar10 + 2)" ( (type_descriptor "long **" (sized_type_specifier "long" long) (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(piVar10 + 2)" ( (binary_expression "piVar10 + 2" identifier + number_literal) ))))) )) (compound_statement "{\n        *(long *)(piVar10 + 2) = *plVar6;\n      }" { (expression_statement "*(long *)(piVar10 + 2) = *plVar6;" (assignment_expression "*(long *)(piVar10 + 2) = *plVar6" (pointer_expression "*(long *)(piVar10 + 2)" * (cast_expression "(long *)(piVar10 + 2)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar10 + 2)" ( (binary_expression "piVar10 + 2" identifier + number_literal) )))) = (pointer_expression "*plVar6" * identifier)) ;) })) (expression_statement "*piVar10 = *piVar10 + -1;" (assignment_expression "*piVar10 = *piVar10 + -1" (pointer_expression "*piVar10" * identifier) = (binary_expression "*piVar10 + -1" (pointer_expression "*piVar10" * identifier) + number_literal)) ;) })) (expression_statement "sqlite3_free(plVar6);" (call_expression "sqlite3_free(plVar6)" identifier (argument_list "(plVar6)" ( identifier ))) ;) (expression_statement "uVar4 = param_1[1];" (assignment_expression "uVar4 = param_1[1]" identifier = (subscript_expression "param_1[1]" identifier [ number_literal ])) ;) (expression_statement "param_1[1] = uVar4 - 1;" (assignment_expression "param_1[1] = uVar4 - 1" (subscript_expression "param_1[1]" identifier [ number_literal ]) = (binary_expression "uVar4 - 1" identifier - number_literal)) ;) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" identifier = identifier) ;) (if_statement "if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }" if (parenthesized_expression "(uVar4 - 1 == 0)" ( (binary_expression "uVar4 - 1 == 0" (binary_expression "uVar4 - 1" identifier - number_literal) == number_literal) )) (compound_statement "{\n      FUN_0011ad1b(param_1);\n    }" { (expression_statement "FUN_0011ad1b(param_1);" (call_expression "FUN_0011ad1b(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) })) }) (else_clause "else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" else (compound_statement "{\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" { (expression_statement "plVar6[2] = param_3;" (assignment_expression "plVar6[2] = param_3" (subscript_expression "plVar6[2]" identifier [ number_literal ]) = identifier) ;) (expression_statement "plVar6[3] = param_2;" (assignment_expression "plVar6[3] = param_2" (subscript_expression "plVar6[3]" identifier [ number_literal ]) = identifier) ;) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" identifier = identifier) ;) }))))) (if_statement "if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }" if (parenthesized_expression "(local_40 == *(long *)(in_FS_OFFSET + 0x28))" ( (binary_expression "local_40 == *(long *)(in_FS_OFFSET + 0x28)" identifier == (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" * (cast_expression "(long *)(in_FS_OFFSET + 0x28)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_FS_OFFSET + 0x28)" ( (binary_expression "in_FS_OFFSET + 0x28" identifier + number_literal) ))))) )) (compound_statement "{\n    return param_3;\n  }" { (return_statement "return param_3;" return identifier ;) })) comment (expression_statement "__stack_chk_fail();" (call_expression "__stack_chk_fail()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "void * sqlite3HashInsert(Hash *pH,char *pKey,void *data)\n\n{\n  void *pvVar1;\n  HashElem *pNew;\n  HashElem *pHVar2;\n  uint uVar3;\n  int iVar4;\n  uint uVar5;\n  HashElem *pHVar6;\n  _ht *p_Var7;\n  long in_FS_OFFSET;\n  uint h;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  pHVar6 = findElementWithHash(pH,pKey,&h);\n  pvVar1 = pHVar6->data;\n  if (pvVar1 == (void *)0x0) {\n    if ((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }\n  }\n  else if (data == (void *)0x0) {\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }\n  else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return data;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail();\n}\n\n" (function_definition "void * sqlite3HashInsert(Hash *pH,char *pKey,void *data)\n\n{\n  void *pvVar1;\n  HashElem *pNew;\n  HashElem *pHVar2;\n  uint uVar3;\n  int iVar4;\n  uint uVar5;\n  HashElem *pHVar6;\n  _ht *p_Var7;\n  long in_FS_OFFSET;\n  uint h;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  pHVar6 = findElementWithHash(pH,pKey,&h);\n  pvVar1 = pHVar6->data;\n  if (pvVar1 == (void *)0x0) {\n    if ((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }\n  }\n  else if (data == (void *)0x0) {\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }\n  else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return data;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail();\n}" primitive_type (pointer_declarator "* sqlite3HashInsert(Hash *pH,char *pKey,void *data)" * (function_declarator "sqlite3HashInsert(Hash *pH,char *pKey,void *data)" identifier (parameter_list "(Hash *pH,char *pKey,void *data)" ( (parameter_declaration "Hash *pH" type_identifier (pointer_declarator "*pH" * identifier)) , (parameter_declaration "char *pKey" primitive_type (pointer_declarator "*pKey" * identifier)) , (parameter_declaration "void *data" primitive_type (pointer_declarator "*data" * identifier)) )))) (compound_statement "{\n  void *pvVar1;\n  HashElem *pNew;\n  HashElem *pHVar2;\n  uint uVar3;\n  int iVar4;\n  uint uVar5;\n  HashElem *pHVar6;\n  _ht *p_Var7;\n  long in_FS_OFFSET;\n  uint h;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  pHVar6 = findElementWithHash(pH,pKey,&h);\n  pvVar1 = pHVar6->data;\n  if (pvVar1 == (void *)0x0) {\n    if ((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }\n  }\n  else if (data == (void *)0x0) {\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }\n  else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return data;\n  }\n                    /* WARNING: Subroutine does not return */\n  __stack_chk_fail();\n}" { (declaration "void *pvVar1;" primitive_type (pointer_declarator "*pvVar1" * identifier) ;) (declaration "HashElem *pNew;" type_identifier (pointer_declarator "*pNew" * identifier) ;) (declaration "HashElem *pHVar2;" type_identifier (pointer_declarator "*pHVar2" * identifier) ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "HashElem *pHVar6;" type_identifier (pointer_declarator "*pHVar6" * identifier) ;) (declaration "_ht *p_Var7;" type_identifier (pointer_declarator "*p_Var7" * identifier) ;) (declaration "long in_FS_OFFSET;" (sized_type_specifier "long" long) identifier ;) (declaration "uint h;" type_identifier identifier ;) (declaration "long local_40;" (sized_type_specifier "long" long) identifier ;) (expression_statement "local_40 = *(long *)(in_FS_OFFSET + 0x28);" (assignment_expression "local_40 = *(long *)(in_FS_OFFSET + 0x28)" identifier = (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" * (cast_expression "(long *)(in_FS_OFFSET + 0x28)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_FS_OFFSET + 0x28)" ( (binary_expression "in_FS_OFFSET + 0x28" identifier + number_literal) ))))) ;) (expression_statement "pHVar6 = findElementWithHash(pH,pKey,&h);" (assignment_expression "pHVar6 = findElementWithHash(pH,pKey,&h)" identifier = (call_expression "findElementWithHash(pH,pKey,&h)" identifier (argument_list "(pH,pKey,&h)" ( identifier , identifier , (pointer_expression "&h" & identifier) )))) ;) (expression_statement "pvVar1 = pHVar6->data;" (assignment_expression "pvVar1 = pHVar6->data" identifier = (field_expression "pHVar6->data" identifier -> field_identifier)) ;) (if_statement "if (pvVar1 == (void *)0x0) {\n    if ((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }\n  }\n  else if (data == (void *)0x0) {\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }\n  else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }" if (parenthesized_expression "(pvVar1 == (void *)0x0)" ( (binary_expression "pvVar1 == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if ((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }\n  }" { (if_statement "if ((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)) {\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }" if (parenthesized_expression "((data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0))" ( (binary_expression "(data != (void *)0x0) &&\n       (pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)" (parenthesized_expression "(data != (void *)0x0)" ( (binary_expression "data != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0)" ( (comma_expression "pHVar6 = (HashElem *)sqlite3Malloc(0x20), pHVar6 != (HashElem *)0x0" (assignment_expression "pHVar6 = (HashElem *)sqlite3Malloc(0x20)" identifier = (cast_expression "(HashElem *)sqlite3Malloc(0x20)" ( (type_descriptor "HashElem *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "sqlite3Malloc(0x20)" identifier (argument_list "(0x20)" ( number_literal ))))) , (binary_expression "pHVar6 != (HashElem *)0x0" identifier != (cast_expression "(HashElem *)0x0" ( (type_descriptor "HashElem *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal))) ))) )) (compound_statement "{\n      pHVar6->pKey = pKey;\n      pHVar6->data = data;\n      uVar3 = pH->count + 1;\n      pH->count = uVar3;\n      if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }\n      p_Var7 = pH->ht;\n      if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }\n      insertElement(pH,p_Var7,pHVar6);\n      data = pvVar1;\n    }" { (expression_statement "pHVar6->pKey = pKey;" (assignment_expression "pHVar6->pKey = pKey" (field_expression "pHVar6->pKey" identifier -> field_identifier) = identifier) ;) (expression_statement "pHVar6->data = data;" (assignment_expression "pHVar6->data = data" (field_expression "pHVar6->data" identifier -> field_identifier) = identifier) ;) (expression_statement "uVar3 = pH->count + 1;" (assignment_expression "uVar3 = pH->count + 1" identifier = (binary_expression "pH->count + 1" (field_expression "pH->count" identifier -> field_identifier) + number_literal)) ;) (expression_statement "pH->count = uVar3;" (assignment_expression "pH->count = uVar3" (field_expression "pH->count" identifier -> field_identifier) = identifier) ;) (if_statement "if ((9 < uVar3) && (pH->htsize * 2 < uVar3)) {\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }" if (parenthesized_expression "((9 < uVar3) && (pH->htsize * 2 < uVar3))" ( (binary_expression "(9 < uVar3) && (pH->htsize * 2 < uVar3)" (parenthesized_expression "(9 < uVar3)" ( (binary_expression "9 < uVar3" number_literal < identifier) )) && (parenthesized_expression "(pH->htsize * 2 < uVar3)" ( (binary_expression "pH->htsize * 2 < uVar3" (binary_expression "pH->htsize * 2" (field_expression "pH->htsize" identifier -> field_identifier) * number_literal) < identifier) ))) )) (compound_statement "{\n        uVar3 = uVar3 * 2;\n        if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }\n        if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }\n      }" { (expression_statement "uVar3 = uVar3 * 2;" (assignment_expression "uVar3 = uVar3 * 2" identifier = (binary_expression "uVar3 * 2" identifier * number_literal)) ;) (if_statement "if (0x40 < uVar3) {\n          uVar3 = 0x40;\n        }" if (parenthesized_expression "(0x40 < uVar3)" ( (binary_expression "0x40 < uVar3" number_literal < identifier) )) (compound_statement "{\n          uVar3 = 0x40;\n        }" { (expression_statement "uVar3 = 0x40;" (assignment_expression "uVar3 = 0x40" identifier = number_literal) ;) })) (if_statement "if (pH->htsize != uVar3) {\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }" if (parenthesized_expression "(pH->htsize != uVar3)" ( (binary_expression "pH->htsize != uVar3" (field_expression "pH->htsize" identifier -> field_identifier) != identifier) )) (compound_statement "{\n          sqlite3BeginBenignMalloc();\n          p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);\n          sqlite3EndBenignMalloc();\n          if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }\n        }" { (expression_statement "sqlite3BeginBenignMalloc();" (call_expression "sqlite3BeginBenignMalloc()" identifier (argument_list "()" ( ))) ;) (expression_statement "p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4);" (assignment_expression "p_Var7 = (_ht *)sqlite3Malloc((ulong)uVar3 << 4)" identifier = (cast_expression "(_ht *)sqlite3Malloc((ulong)uVar3 << 4)" ( (type_descriptor "_ht *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "sqlite3Malloc((ulong)uVar3 << 4)" identifier (argument_list "((ulong)uVar3 << 4)" ( (binary_expression "(ulong)uVar3 << 4" (cast_expression "(ulong)uVar3" ( (type_descriptor "ulong" type_identifier) ) identifier) << number_literal) ))))) ;) (expression_statement "sqlite3EndBenignMalloc();" (call_expression "sqlite3EndBenignMalloc()" identifier (argument_list "()" ( ))) ;) (if_statement "if (p_Var7 != (_ht *)0x0) {\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }" if (parenthesized_expression "(p_Var7 != (_ht *)0x0)" ( (binary_expression "p_Var7 != (_ht *)0x0" identifier != (cast_expression "(_ht *)0x0" ( (type_descriptor "_ht *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            sqlite3_free(pH->ht);\n            pH->ht = p_Var7;\n            iVar4 = sqlite3MallocSize(p_Var7);\n            uVar3 = (uint)((ulong)(long)iVar4 >> 4);\n            pH->htsize = uVar3;\n            memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);\n            pNew = pH->first;\n            pH->first = (HashElem *)0x0;\n            while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }\n            uVar3 = strHash(pKey);\n            h = uVar3 % pH->htsize;\n          }" { (expression_statement "sqlite3_free(pH->ht);" (call_expression "sqlite3_free(pH->ht)" identifier (argument_list "(pH->ht)" ( (field_expression "pH->ht" identifier -> field_identifier) ))) ;) (expression_statement "pH->ht = p_Var7;" (assignment_expression "pH->ht = p_Var7" (field_expression "pH->ht" identifier -> field_identifier) = identifier) ;) (expression_statement "iVar4 = sqlite3MallocSize(p_Var7);" (assignment_expression "iVar4 = sqlite3MallocSize(p_Var7)" identifier = (call_expression "sqlite3MallocSize(p_Var7)" identifier (argument_list "(p_Var7)" ( identifier )))) ;) (expression_statement "uVar3 = (uint)((ulong)(long)iVar4 >> 4);" (assignment_expression "uVar3 = (uint)((ulong)(long)iVar4 >> 4)" identifier = (call_expression "(uint)((ulong)(long)iVar4 >> 4)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "((ulong)(long)iVar4 >> 4)" ( (binary_expression "(ulong)(long)iVar4 >> 4" (cast_expression "(ulong)(long)iVar4" ( (type_descriptor "ulong" type_identifier) ) (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) >> number_literal) )))) ;) (expression_statement "pH->htsize = uVar3;" (assignment_expression "pH->htsize = uVar3" (field_expression "pH->htsize" identifier -> field_identifier) = identifier) ;) (expression_statement "memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4);" (call_expression "memset(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4)" identifier (argument_list "(p_Var7,0,((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4)" ( identifier , number_literal , (binary_expression "((ulong)(long)iVar4 >> 4 & 0xffffffff) << 4" (parenthesized_expression "((ulong)(long)iVar4 >> 4 & 0xffffffff)" ( (binary_expression "(ulong)(long)iVar4 >> 4 & 0xffffffff" (binary_expression "(ulong)(long)iVar4 >> 4" (cast_expression "(ulong)(long)iVar4" ( (type_descriptor "ulong" type_identifier) ) (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) >> number_literal) & number_literal) )) << number_literal) ))) ;) (expression_statement "pNew = pH->first;" (assignment_expression "pNew = pH->first" identifier = (field_expression "pH->first" identifier -> field_identifier)) ;) (expression_statement "pH->first = (HashElem *)0x0;" (assignment_expression "pH->first = (HashElem *)0x0" (field_expression "pH->first" identifier -> field_identifier) = (cast_expression "(HashElem *)0x0" ( (type_descriptor "HashElem *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (while_statement "while (pNew != (HashElem *)0x0) {\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }" while (parenthesized_expression "(pNew != (HashElem *)0x0)" ( (binary_expression "pNew != (HashElem *)0x0" identifier != (cast_expression "(HashElem *)0x0" ( (type_descriptor "HashElem *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n              uVar5 = strHash(pNew->pKey);\n              pHVar2 = pNew->next;\n              insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);\n              pNew = pHVar2;\n            }" { (expression_statement "uVar5 = strHash(pNew->pKey);" (assignment_expression "uVar5 = strHash(pNew->pKey)" identifier = (call_expression "strHash(pNew->pKey)" identifier (argument_list "(pNew->pKey)" ( (field_expression "pNew->pKey" identifier -> field_identifier) )))) ;) (expression_statement "pHVar2 = pNew->next;" (assignment_expression "pHVar2 = pNew->next" identifier = (field_expression "pNew->next" identifier -> field_identifier)) ;) (expression_statement "insertElement(pH,p_Var7 + uVar5 % uVar3,pNew);" (call_expression "insertElement(pH,p_Var7 + uVar5 % uVar3,pNew)" identifier (argument_list "(pH,p_Var7 + uVar5 % uVar3,pNew)" ( identifier , (binary_expression "p_Var7 + uVar5 % uVar3" identifier + (binary_expression "uVar5 % uVar3" identifier % identifier)) , identifier ))) ;) (expression_statement "pNew = pHVar2;" (assignment_expression "pNew = pHVar2" identifier = identifier) ;) })) (expression_statement "uVar3 = strHash(pKey);" (assignment_expression "uVar3 = strHash(pKey)" identifier = (call_expression "strHash(pKey)" identifier (argument_list "(pKey)" ( identifier )))) ;) (expression_statement "h = uVar3 % pH->htsize;" (assignment_expression "h = uVar3 % pH->htsize" identifier = (binary_expression "uVar3 % pH->htsize" identifier % (field_expression "pH->htsize" identifier -> field_identifier))) ;) })) })) })) (expression_statement "p_Var7 = pH->ht;" (assignment_expression "p_Var7 = pH->ht" identifier = (field_expression "pH->ht" identifier -> field_identifier)) ;) (if_statement "if (p_Var7 != (_ht *)0x0) {\n        p_Var7 = p_Var7 + h;\n      }" if (parenthesized_expression "(p_Var7 != (_ht *)0x0)" ( (binary_expression "p_Var7 != (_ht *)0x0" identifier != (cast_expression "(_ht *)0x0" ( (type_descriptor "_ht *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n        p_Var7 = p_Var7 + h;\n      }" { (expression_statement "p_Var7 = p_Var7 + h;" (assignment_expression "p_Var7 = p_Var7 + h" identifier = (binary_expression "p_Var7 + h" identifier + identifier)) ;) })) (expression_statement "insertElement(pH,p_Var7,pHVar6);" (call_expression "insertElement(pH,p_Var7,pHVar6)" identifier (argument_list "(pH,p_Var7,pHVar6)" ( identifier , identifier , identifier ))) ;) (expression_statement "data = pvVar1;" (assignment_expression "data = pvVar1" identifier = identifier) ;) })) }) (else_clause "else if (data == (void *)0x0) {\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }\n  else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }" else (if_statement "if (data == (void *)0x0) {\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }\n  else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }" if (parenthesized_expression "(data == (void *)0x0)" ( (binary_expression "data == (void *)0x0" identifier == (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }\n    if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }\n    if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }\n    sqlite3_free(pHVar6);\n    uVar3 = pH->count - 1;\n    pH->count = uVar3;\n    data = pvVar1;\n    if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }\n  }" { (if_statement "if (pHVar6->prev == (HashElem *)0x0) {\n      pH->first = pHVar6->next;\n    }\n    else {\n      pHVar6->prev->next = pHVar6->next;\n    }" if (parenthesized_expression "(pHVar6->prev == (HashElem *)0x0)" ( (binary_expression "pHVar6->prev == (HashElem *)0x0" (field_expression "pHVar6->prev" identifier -> field_identifier) == (cast_expression "(HashElem *)0x0" ( (type_descriptor "HashElem *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      pH->first = pHVar6->next;\n    }" { (expression_statement "pH->first = pHVar6->next;" (assignment_expression "pH->first = pHVar6->next" (field_expression "pH->first" identifier -> field_identifier) = (field_expression "pHVar6->next" identifier -> field_identifier)) ;) }) (else_clause "else {\n      pHVar6->prev->next = pHVar6->next;\n    }" else (compound_statement "{\n      pHVar6->prev->next = pHVar6->next;\n    }" { (expression_statement "pHVar6->prev->next = pHVar6->next;" (assignment_expression "pHVar6->prev->next = pHVar6->next" (field_expression "pHVar6->prev->next" (field_expression "pHVar6->prev" identifier -> field_identifier) -> field_identifier) = (field_expression "pHVar6->next" identifier -> field_identifier)) ;) }))) (if_statement "if (pHVar6->next != (HashElem *)0x0) {\n      pHVar6->next->prev = pHVar6->prev;\n    }" if (parenthesized_expression "(pHVar6->next != (HashElem *)0x0)" ( (binary_expression "pHVar6->next != (HashElem *)0x0" (field_expression "pHVar6->next" identifier -> field_identifier) != (cast_expression "(HashElem *)0x0" ( (type_descriptor "HashElem *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      pHVar6->next->prev = pHVar6->prev;\n    }" { (expression_statement "pHVar6->next->prev = pHVar6->prev;" (assignment_expression "pHVar6->next->prev = pHVar6->prev" (field_expression "pHVar6->next->prev" (field_expression "pHVar6->next" identifier -> field_identifier) -> field_identifier) = (field_expression "pHVar6->prev" identifier -> field_identifier)) ;) })) (if_statement "if (pH->ht != (_ht *)0x0) {\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }" if (parenthesized_expression "(pH->ht != (_ht *)0x0)" ( (binary_expression "pH->ht != (_ht *)0x0" (field_expression "pH->ht" identifier -> field_identifier) != (cast_expression "(_ht *)0x0" ( (type_descriptor "_ht *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      p_Var7 = pH->ht + h;\n      if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }\n      p_Var7->count = p_Var7->count - 1;\n    }" { (expression_statement "p_Var7 = pH->ht + h;" (assignment_expression "p_Var7 = pH->ht + h" identifier = (binary_expression "pH->ht + h" (field_expression "pH->ht" identifier -> field_identifier) + identifier)) ;) (if_statement "if (pHVar6 == p_Var7->chain) {\n        p_Var7->chain = pHVar6->next;\n      }" if (parenthesized_expression "(pHVar6 == p_Var7->chain)" ( (binary_expression "pHVar6 == p_Var7->chain" identifier == (field_expression "p_Var7->chain" identifier -> field_identifier)) )) (compound_statement "{\n        p_Var7->chain = pHVar6->next;\n      }" { (expression_statement "p_Var7->chain = pHVar6->next;" (assignment_expression "p_Var7->chain = pHVar6->next" (field_expression "p_Var7->chain" identifier -> field_identifier) = (field_expression "pHVar6->next" identifier -> field_identifier)) ;) })) (expression_statement "p_Var7->count = p_Var7->count - 1;" (assignment_expression "p_Var7->count = p_Var7->count - 1" (field_expression "p_Var7->count" identifier -> field_identifier) = (binary_expression "p_Var7->count - 1" (field_expression "p_Var7->count" identifier -> field_identifier) - number_literal)) ;) })) (expression_statement "sqlite3_free(pHVar6);" (call_expression "sqlite3_free(pHVar6)" identifier (argument_list "(pHVar6)" ( identifier ))) ;) (expression_statement "uVar3 = pH->count - 1;" (assignment_expression "uVar3 = pH->count - 1" identifier = (binary_expression "pH->count - 1" (field_expression "pH->count" identifier -> field_identifier) - number_literal)) ;) (expression_statement "pH->count = uVar3;" (assignment_expression "pH->count = uVar3" (field_expression "pH->count" identifier -> field_identifier) = identifier) ;) (expression_statement "data = pvVar1;" (assignment_expression "data = pvVar1" identifier = identifier) ;) (if_statement "if (uVar3 == 0) {\n      sqlite3HashClear(pH);\n    }" if (parenthesized_expression "(uVar3 == 0)" ( (binary_expression "uVar3 == 0" identifier == number_literal) )) (compound_statement "{\n      sqlite3HashClear(pH);\n    }" { (expression_statement "sqlite3HashClear(pH);" (call_expression "sqlite3HashClear(pH)" identifier (argument_list "(pH)" ( identifier ))) ;) })) }) (else_clause "else {\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }" else (compound_statement "{\n    pHVar6->data = data;\n    pHVar6->pKey = pKey;\n    data = pvVar1;\n  }" { (expression_statement "pHVar6->data = data;" (assignment_expression "pHVar6->data = data" (field_expression "pHVar6->data" identifier -> field_identifier) = identifier) ;) (expression_statement "pHVar6->pKey = pKey;" (assignment_expression "pHVar6->pKey = pKey" (field_expression "pHVar6->pKey" identifier -> field_identifier) = identifier) ;) (expression_statement "data = pvVar1;" (assignment_expression "data = pvVar1" identifier = identifier) ;) }))))) (if_statement "if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return data;\n  }" if (parenthesized_expression "(local_40 == *(long *)(in_FS_OFFSET + 0x28))" ( (binary_expression "local_40 == *(long *)(in_FS_OFFSET + 0x28)" identifier == (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" * (cast_expression "(long *)(in_FS_OFFSET + 0x28)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_FS_OFFSET + 0x28)" ( (binary_expression "in_FS_OFFSET + 0x28" identifier + number_literal) ))))) )) (compound_statement "{\n    return data;\n  }" { (return_statement "return data;" return identifier ;) })) comment (expression_statement "__stack_chk_fail();" (call_expression "__stack_chk_fail()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit "long FUN_0011be09(uint *param_1,long param_2,long param_3)\n\n{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    \n  __stack_chk_fail();\n}\n\n" (function_definition "long FUN_0011be09(uint *param_1,long param_2,long param_3)\n\n{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    \n  __stack_chk_fail();\n}" (sized_type_specifier "long" long) (function_declarator "FUN_0011be09(uint *param_1,long param_2,long param_3)" identifier (parameter_list "(uint *param_1,long param_2,long param_3)" ( (parameter_declaration "uint *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "long param_2" (sized_type_specifier "long" long) identifier) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) ))) (compound_statement "{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    \n  __stack_chk_fail();\n}" { (declaration "long lVar1;" (sized_type_specifier "long" long) identifier ;) (declaration "undefined8 *puVar2;" type_identifier (pointer_declarator "*puVar2" * identifier) ;) (declaration "undefined8 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "long *plVar6;" (sized_type_specifier "long" long) (pointer_declarator "*plVar6" * identifier) ;) (declaration "long lVar7;" (sized_type_specifier "long" long) identifier ;) (declaration "void *__s;" primitive_type (pointer_declarator "*__s" * identifier) ;) (declaration "ulong uVar8;" type_identifier identifier ;) (declaration "ulong uVar9;" type_identifier identifier ;) (declaration "int *piVar10;" primitive_type (pointer_declarator "*piVar10" * identifier) ;) (declaration "long lVar11;" (sized_type_specifier "long" long) identifier ;) (declaration "long in_FS_OFFSET;" (sized_type_specifier "long" long) identifier ;) (declaration "uint local_44;" type_identifier identifier ;) (declaration "long local_40;" (sized_type_specifier "long" long) identifier ;) (expression_statement "local_40 = *(long *)(in_FS_OFFSET + 0x28);" (assignment_expression "local_40 = *(long *)(in_FS_OFFSET + 0x28)" identifier = (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" * (cast_expression "(long *)(in_FS_OFFSET + 0x28)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_FS_OFFSET + 0x28)" ( (binary_expression "in_FS_OFFSET + 0x28" identifier + number_literal) ))))) ;) (expression_statement "plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);" (assignment_expression "plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44)" identifier = (cast_expression "(long *)FUN_0010d8aa(param_1,param_2,&local_44)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0010d8aa(param_1,param_2,&local_44)" identifier (argument_list "(param_1,param_2,&local_44)" ( identifier , identifier , (pointer_expression "&local_44" & identifier) ))))) ;) (expression_statement "lVar1 = plVar6[2];" (assignment_expression "lVar1 = plVar6[2]" identifier = (subscript_expression "plVar6[2]" identifier [ number_literal ])) ;) (if_statement "if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" if (parenthesized_expression "(lVar1 == 0)" ( (binary_expression "lVar1 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }" { (if_statement "if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }" if (parenthesized_expression "((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0))" ( (binary_expression "(param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)" (parenthesized_expression "(param_3 != 0)" ( (binary_expression "param_3 != 0" identifier != number_literal) )) && (parenthesized_expression "(lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)" ( (comma_expression "lVar7 = FUN_0011bd0f(0x20), lVar7 != 0" (assignment_expression "lVar7 = FUN_0011bd0f(0x20)" identifier = (call_expression "FUN_0011bd0f(0x20)" identifier (argument_list "(0x20)" ( number_literal )))) , (binary_expression "lVar7 != 0" identifier != number_literal)) ))) )) (compound_statement "{\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }" { (expression_statement "*(long *)(lVar7 + 0x18) = param_2;" (assignment_expression "*(long *)(lVar7 + 0x18) = param_2" (pointer_expression "*(long *)(lVar7 + 0x18)" * (cast_expression "(long *)(lVar7 + 0x18)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar7 + 0x18)" ( (binary_expression "lVar7 + 0x18" identifier + number_literal) )))) = identifier) ;) (expression_statement "*(long *)(lVar7 + 0x10) = param_3;" (assignment_expression "*(long *)(lVar7 + 0x10) = param_3" (pointer_expression "*(long *)(lVar7 + 0x10)" * (cast_expression "(long *)(lVar7 + 0x10)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(lVar7 + 0x10)" ( (binary_expression "lVar7 + 0x10" identifier + number_literal) )))) = identifier) ;) (expression_statement "uVar4 = param_1[1] + 1;" (assignment_expression "uVar4 = param_1[1] + 1" identifier = (binary_expression "param_1[1] + 1" (subscript_expression "param_1[1]" identifier [ number_literal ]) + number_literal)) ;) (expression_statement "param_1[1] = uVar4;" (assignment_expression "param_1[1] = uVar4" (subscript_expression "param_1[1]" identifier [ number_literal ]) = identifier) ;) (if_statement "if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }" if (parenthesized_expression "((9 < uVar4) && (*param_1 * 2 < uVar4))" ( (binary_expression "(9 < uVar4) && (*param_1 * 2 < uVar4)" (parenthesized_expression "(9 < uVar4)" ( (binary_expression "9 < uVar4" number_literal < identifier) )) && (parenthesized_expression "(*param_1 * 2 < uVar4)" ( (binary_expression "*param_1 * 2 < uVar4" (binary_expression "*param_1 * 2" (pointer_expression "*param_1" * identifier) * number_literal) < identifier) ))) )) (compound_statement "{\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }" { (expression_statement "uVar4 = uVar4 * 2;" (assignment_expression "uVar4 = uVar4 * 2" identifier = (binary_expression "uVar4 * 2" identifier * number_literal)) ;) (if_statement "if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }" if (parenthesized_expression "(0x40 < uVar4)" ( (binary_expression "0x40 < uVar4" number_literal < identifier) )) (compound_statement "{\n          uVar4 = 0x40;\n        }" { (expression_statement "uVar4 = 0x40;" (assignment_expression "uVar4 = 0x40" identifier = number_literal) ;) })) (if_statement "if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }" if (parenthesized_expression "(*param_1 != uVar4)" ( (binary_expression "*param_1 != uVar4" (pointer_expression "*param_1" * identifier) != identifier) )) (compound_statement "{\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }" { (expression_statement "FUN_0010cba2();" (call_expression "FUN_0010cba2()" identifier (argument_list "()" ( ))) ;) (expression_statement "__s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);" (assignment_expression "__s = (void *)FUN_0011bd0f((ulong)uVar4 << 4)" identifier = (cast_expression "(void *)FUN_0011bd0f((ulong)uVar4 << 4)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0011bd0f((ulong)uVar4 << 4)" identifier (argument_list "((ulong)uVar4 << 4)" ( (binary_expression "(ulong)uVar4 << 4" (cast_expression "(ulong)uVar4" ( (type_descriptor "ulong" type_identifier) ) identifier) << number_literal) ))))) ;) (expression_statement "FUN_0010cbbb();" (call_expression "FUN_0010cbbb()" identifier (argument_list "()" ( ))) ;) (if_statement "if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }" if (parenthesized_expression "(__s != (void *)0x0)" ( (binary_expression "__s != (void *)0x0" identifier != (cast_expression "(void *)0x0" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }" { (expression_statement "sqlite3_free(*(undefined8 *)(param_1 + 4));" (call_expression "sqlite3_free(*(undefined8 *)(param_1 + 4))" identifier (argument_list "(*(undefined8 *)(param_1 + 4))" ( (pointer_expression "*(undefined8 *)(param_1 + 4)" * (cast_expression "(undefined8 *)(param_1 + 4)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) ))) ;) (expression_statement "*(void **)(param_1 + 4) = __s;" (assignment_expression "*(void **)(param_1 + 4) = __s" (pointer_expression "*(void **)(param_1 + 4)" * (cast_expression "(void **)(param_1 + 4)" ( (type_descriptor "void **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) = identifier) ;) (expression_statement "iVar5 = FUN_0010ccbd(__s);" (assignment_expression "iVar5 = FUN_0010ccbd(__s)" identifier = (call_expression "FUN_0010ccbd(__s)" identifier (argument_list "(__s)" ( identifier )))) ;) (expression_statement "uVar8 = (ulong)(long)iVar5 >> 4;" (assignment_expression "uVar8 = (ulong)(long)iVar5 >> 4" identifier = (binary_expression "(ulong)(long)iVar5 >> 4" (cast_expression "(ulong)(long)iVar5" ( (type_descriptor "ulong" type_identifier) ) (cast_expression "(long)iVar5" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier)) >> number_literal)) ;) (expression_statement "*param_1 = (uint)uVar8;" (assignment_expression "*param_1 = (uint)uVar8" (pointer_expression "*param_1" * identifier) = (cast_expression "(uint)uVar8" ( (type_descriptor "uint" type_identifier) ) identifier)) ;) (expression_statement "memset(__s,0,(uVar8 & 0xffffffff) << 4);" (call_expression "memset(__s,0,(uVar8 & 0xffffffff) << 4)" identifier (argument_list "(__s,0,(uVar8 & 0xffffffff) << 4)" ( identifier , number_literal , (binary_expression "(uVar8 & 0xffffffff) << 4" (parenthesized_expression "(uVar8 & 0xffffffff)" ( (binary_expression "uVar8 & 0xffffffff" identifier & number_literal) )) << number_literal) ))) ;) (expression_statement "puVar2 = *(undefined8 **)(param_1 + 2);" (assignment_expression "puVar2 = *(undefined8 **)(param_1 + 2)" identifier = (pointer_expression "*(undefined8 **)(param_1 + 2)" * (cast_expression "(undefined8 **)(param_1 + 2)" ( (type_descriptor "undefined8 **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1 + 2)" ( (binary_expression "param_1 + 2" identifier + number_literal) ))))) ;) (expression_statement "param_1[2] = 0;" (assignment_expression "param_1[2] = 0" (subscript_expression "param_1[2]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "param_1[3] = 0;" (assignment_expression "param_1[3] = 0" (subscript_expression "param_1[3]" identifier [ number_literal ]) = number_literal) ;) (while_statement "while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }" while (parenthesized_expression "(puVar2 != (undefined8 *)0x0)" ( (binary_expression "puVar2 != (undefined8 *)0x0" identifier != (cast_expression "(undefined8 *)0x0" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }" { (expression_statement "uVar9 = FUN_0010d806(puVar2[3]);" (assignment_expression "uVar9 = FUN_0010d806(puVar2[3])" identifier = (call_expression "FUN_0010d806(puVar2[3])" identifier (argument_list "(puVar2[3])" ( (subscript_expression "puVar2[3]" identifier [ number_literal ]) )))) ;) (expression_statement "puVar3 = (undefined8 *)*puVar2;" (assignment_expression "puVar3 = (undefined8 *)*puVar2" identifier = (cast_expression "(undefined8 *)*puVar2" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "*puVar2" * identifier))) ;) (expression_statement "FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);" (call_expression "FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2)" identifier (argument_list "(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2)" ( identifier , (cast_expression "(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10)" ( (type_descriptor "void *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10)" ( (binary_expression "(long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10" (cast_expression "(long)__s" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) + (binary_expression "((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10" (parenthesized_expression "((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff))" ( (binary_expression "(uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)" (parenthesized_expression "(uVar9 & 0xffffffff)" ( (binary_expression "uVar9 & 0xffffffff" identifier & number_literal) )) % (parenthesized_expression "(uVar8 & 0xffffffff)" ( (binary_expression "uVar8 & 0xffffffff" identifier & number_literal) ))) )) * number_literal)) ))) , identifier ))) ;) (expression_statement "puVar2 = puVar3;" (assignment_expression "puVar2 = puVar3" identifier = identifier) ;) })) (expression_statement "uVar8 = FUN_0010d806(param_2);" (assignment_expression "uVar8 = FUN_0010d806(param_2)" identifier = (call_expression "FUN_0010d806(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (expression_statement "local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);" (assignment_expression "local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1)" identifier = (call_expression "(uint)((uVar8 & 0xffffffff) % (ulong)*param_1)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "((uVar8 & 0xffffffff) % (ulong)*param_1)" ( (binary_expression "(uVar8 & 0xffffffff) % (ulong)*param_1" (binary_expression "(uVar8 & 0xffffffff) % (ulong)" (parenthesized_expression "(uVar8 & 0xffffffff)" ( (binary_expression "uVar8 & 0xffffffff" identifier & number_literal) )) % (parenthesized_expression "(ulong)" ( identifier ))) * identifier) )))) ;) })) })) })) (expression_statement "lVar11 = *(long *)(param_1 + 4);" (assignment_expression "lVar11 = *(long *)(param_1 + 4)" identifier = (pointer_expression "*(long *)(param_1 + 4)" * (cast_expression "(long *)(param_1 + 4)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) (if_statement "if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }" if (parenthesized_expression "(lVar11 != 0)" ( (binary_expression "lVar11 != 0" identifier != number_literal) )) (compound_statement "{\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }" { (expression_statement "lVar11 = lVar11 + (ulong)local_44 * 0x10;" (assignment_expression "lVar11 = lVar11 + (ulong)local_44 * 0x10" identifier = (binary_expression "lVar11 + (ulong)local_44 * 0x10" identifier + (binary_expression "(ulong)local_44 * 0x10" (cast_expression "(ulong)local_44" ( (type_descriptor "ulong" type_identifier) ) identifier) * number_literal))) ;) })) (expression_statement "FUN_0010d840(param_1,lVar11,lVar7);" (call_expression "FUN_0010d840(param_1,lVar11,lVar7)" identifier (argument_list "(param_1,lVar11,lVar7)" ( identifier , identifier , identifier ))) ;) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" identifier = identifier) ;) })) }) (else_clause "else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" else (if_statement "if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" if (parenthesized_expression "(param_3 == 0)" ( (binary_expression "param_3 == 0" identifier == number_literal) )) (compound_statement "{\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }" { (if_statement "if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }" if (parenthesized_expression "((long *)plVar6[1] == (long *)0x0)" ( (binary_expression "(long *)plVar6[1] == (long *)0x0" (cast_expression "(long *)plVar6[1]" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (subscript_expression "plVar6[1]" identifier [ number_literal ])) == (cast_expression "(long *)0x0" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      *(long *)(param_1 + 2) = *plVar6;\n    }" { (expression_statement "*(long *)(param_1 + 2) = *plVar6;" (assignment_expression "*(long *)(param_1 + 2) = *plVar6" (pointer_expression "*(long *)(param_1 + 2)" * (cast_expression "(long *)(param_1 + 2)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 2)" ( (binary_expression "param_1 + 2" identifier + number_literal) )))) = (pointer_expression "*plVar6" * identifier)) ;) }) (else_clause "else {\n      *(long *)plVar6[1] = *plVar6;\n    }" else (compound_statement "{\n      *(long *)plVar6[1] = *plVar6;\n    }" { (expression_statement "*(long *)plVar6[1] = *plVar6;" (assignment_expression "*(long *)plVar6[1] = *plVar6" (pointer_expression "*(long *)plVar6[1]" * (cast_expression "(long *)plVar6[1]" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (subscript_expression "plVar6[1]" identifier [ number_literal ]))) = (pointer_expression "*plVar6" * identifier)) ;) }))) (if_statement "if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }" if (parenthesized_expression "(*plVar6 != 0)" ( (binary_expression "*plVar6 != 0" (pointer_expression "*plVar6" * identifier) != number_literal) )) (compound_statement "{\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }" { (expression_statement "*(long *)(*plVar6 + 8) = plVar6[1];" (assignment_expression "*(long *)(*plVar6 + 8) = plVar6[1]" (pointer_expression "*(long *)(*plVar6 + 8)" * (cast_expression "(long *)(*plVar6 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*plVar6 + 8)" ( (binary_expression "*plVar6 + 8" (pointer_expression "*plVar6" * identifier) + number_literal) )))) = (subscript_expression "plVar6[1]" identifier [ number_literal ])) ;) })) (if_statement "if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }" if (parenthesized_expression "(*(long *)(param_1 + 4) != 0)" ( (binary_expression "*(long *)(param_1 + 4) != 0" (pointer_expression "*(long *)(param_1 + 4)" * (cast_expression "(long *)(param_1 + 4)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }" { (expression_statement "piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));" (assignment_expression "piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" identifier = (cast_expression "(int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" ( (binary_expression "(ulong)local_44 * 0x10 + *(long *)(param_1 + 4)" (binary_expression "(ulong)local_44 * 0x10" (cast_expression "(ulong)local_44" ( (type_descriptor "ulong" type_identifier) ) identifier) * number_literal) + (pointer_expression "*(long *)(param_1 + 4)" * (cast_expression "(long *)(param_1 + 4)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) )))) ;) (if_statement "if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }" if (parenthesized_expression "(plVar6 == *(long **)(piVar10 + 2))" ( (binary_expression "plVar6 == *(long **)(piVar10 + 2)" identifier == (pointer_expression "*(long **)(piVar10 + 2)" * (cast_expression "(long **)(piVar10 + 2)" ( (type_descriptor "long **" (sized_type_specifier "long" long) (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(piVar10 + 2)" ( (binary_expression "piVar10 + 2" identifier + number_literal) ))))) )) (compound_statement "{\n        *(long *)(piVar10 + 2) = *plVar6;\n      }" { (expression_statement "*(long *)(piVar10 + 2) = *plVar6;" (assignment_expression "*(long *)(piVar10 + 2) = *plVar6" (pointer_expression "*(long *)(piVar10 + 2)" * (cast_expression "(long *)(piVar10 + 2)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(piVar10 + 2)" ( (binary_expression "piVar10 + 2" identifier + number_literal) )))) = (pointer_expression "*plVar6" * identifier)) ;) })) (expression_statement "*piVar10 = *piVar10 + -1;" (assignment_expression "*piVar10 = *piVar10 + -1" (pointer_expression "*piVar10" * identifier) = (binary_expression "*piVar10 + -1" (pointer_expression "*piVar10" * identifier) + number_literal)) ;) })) (expression_statement "sqlite3_free(plVar6);" (call_expression "sqlite3_free(plVar6)" identifier (argument_list "(plVar6)" ( identifier ))) ;) (expression_statement "uVar4 = param_1[1];" (assignment_expression "uVar4 = param_1[1]" identifier = (subscript_expression "param_1[1]" identifier [ number_literal ])) ;) (expression_statement "param_1[1] = uVar4 - 1;" (assignment_expression "param_1[1] = uVar4 - 1" (subscript_expression "param_1[1]" identifier [ number_literal ]) = (binary_expression "uVar4 - 1" identifier - number_literal)) ;) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" identifier = identifier) ;) (if_statement "if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }" if (parenthesized_expression "(uVar4 - 1 == 0)" ( (binary_expression "uVar4 - 1 == 0" (binary_expression "uVar4 - 1" identifier - number_literal) == number_literal) )) (compound_statement "{\n      FUN_0011ad1b(param_1);\n    }" { (expression_statement "FUN_0011ad1b(param_1);" (call_expression "FUN_0011ad1b(param_1)" identifier (argument_list "(param_1)" ( identifier ))) ;) })) }) (else_clause "else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" else (compound_statement "{\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" { (expression_statement "plVar6[2] = param_3;" (assignment_expression "plVar6[2] = param_3" (subscript_expression "plVar6[2]" identifier [ number_literal ]) = identifier) ;) (expression_statement "plVar6[3] = param_2;" (assignment_expression "plVar6[3] = param_2" (subscript_expression "plVar6[3]" identifier [ number_literal ]) = identifier) ;) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" identifier = identifier) ;) }))))) (if_statement "if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }" if (parenthesized_expression "(local_40 == *(long *)(in_FS_OFFSET + 0x28))" ( (binary_expression "local_40 == *(long *)(in_FS_OFFSET + 0x28)" identifier == (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" * (cast_expression "(long *)(in_FS_OFFSET + 0x28)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_FS_OFFSET + 0x28)" ( (binary_expression "in_FS_OFFSET + 0x28" identifier + number_literal) ))))) )) (compound_statement "{\n    return param_3;\n  }" { (return_statement "return param_3;" return identifier ;) })) (expression_statement "__stack_chk_fail();" (call_expression "__stack_chk_fail()" identifier (argument_list "()" ( ))) ;) })))
(translation_unit (function_definition (sized_type_specifier long) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration (sized_type_specifier long) IDENT) , (parameter_declaration (sized_type_specifier long) IDENT) ))) (compound_statement { (declaration (sized_type_specifier long) IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration (sized_type_specifier long) (pointer_declarator * IDENT) ;) (declaration (sized_type_specifier long) IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration (sized_type_specifier long) IDENT ;) (declaration (sized_type_specifier long) IDENT ;) (declaration TYPE IDENT ;) (declaration (sized_type_specifier long) IDENT ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , IDENT , (pointer_expression & IDENT) ))))) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (call_expression IDENT (argument_list ( LIT )))) , (binary_expression IDENT != LIT)) ))) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression (subscript_expression IDENT [ LIT ]) + LIT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression LIT < IDENT) )) && (parenthesized_expression ( (binary_expression (binary_expression (pointer_expression * IDENT) * LIT) < IDENT) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT * LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) })) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != IDENT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) << LIT) ))))) ;) (expression_statement (call_expression IDENT (argument_list ( ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT)) >> LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , LIT , (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) << LIT) ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (while_statement while (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (subscript_expression IDENT [ LIT ]) )))) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT , (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT) + (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) % (parenthesized_expression ( (binary_expression IDENT & LIT) ))) )) * LIT)) ))) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) % (parenthesized_expression ( IDENT ))) * IDENT) )))) ;) })) })) })) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) * LIT))) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) }) (else_clause else (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (subscript_expression IDENT [ LIT ])) == (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (pointer_expression * IDENT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (subscript_expression IDENT [ LIT ]))) = (pointer_expression * IDENT)) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) + LIT) )))) = (subscript_expression IDENT [ LIT ])) ;) })) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) * LIT) + (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (pointer_expression * IDENT)) ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression (pointer_expression * IDENT) + LIT)) ;) })) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (binary_expression IDENT - LIT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression IDENT - LIT) == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) })) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) }))))) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) (compound_statement { (return_statement return IDENT ;) })) (expression_statement (call_expression IDENT (argument_list ( ))) ;) })))
(function_definition "long FUN_0011be09(uint *param_1,long param_2,long param_3)\n\n{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    \n  __stack_chk_fail();\n}" (sized_type_specifier "long" (long "long")) (function_declarator "FUN_0011be09(uint *param_1,long param_2,long param_3)" (identifier "FUN_0011be09") (parameter_list "(uint *param_1,long param_2,long param_3)" (( "(") (parameter_declaration "uint *param_1" (type_identifier "uint") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "long param_2" (sized_type_specifier "long" (long "long")) (identifier "param_2")) (, ",") (parameter_declaration "long param_3" (sized_type_specifier "long" (long "long")) (identifier "param_3")) () ")"))) (compound_statement "{\n  long lVar1;\n  undefined8 *puVar2;\n  undefined8 *puVar3;\n  uint uVar4;\n  int iVar5;\n  long *plVar6;\n  long lVar7;\n  void *__s;\n  ulong uVar8;\n  ulong uVar9;\n  int *piVar10;\n  long lVar11;\n  long in_FS_OFFSET;\n  uint local_44;\n  long local_40;\n  \n  local_40 = *(long *)(in_FS_OFFSET + 0x28);\n  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);\n  lVar1 = plVar6[2];\n  if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }\n  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }\n                    \n  __stack_chk_fail();\n}" ({ "{") (declaration "long lVar1;" (sized_type_specifier "long" (long "long")) (identifier "lVar1") (; ";")) (declaration "undefined8 *puVar2;" (type_identifier "undefined8") (pointer_declarator "*puVar2" (* "*") (identifier "puVar2")) (; ";")) (declaration "undefined8 *puVar3;" (type_identifier "undefined8") (pointer_declarator "*puVar3" (* "*") (identifier "puVar3")) (; ";")) (declaration "uint uVar4;" (type_identifier "uint") (identifier "uVar4") (; ";")) (declaration "int iVar5;" (primitive_type "int") (identifier "iVar5") (; ";")) (declaration "long *plVar6;" (sized_type_specifier "long" (long "long")) (pointer_declarator "*plVar6" (* "*") (identifier "plVar6")) (; ";")) (declaration "long lVar7;" (sized_type_specifier "long" (long "long")) (identifier "lVar7") (; ";")) (declaration "void *__s;" (primitive_type "void") (pointer_declarator "*__s" (* "*") (identifier "__s")) (; ";")) (declaration "ulong uVar8;" (type_identifier "ulong") (identifier "uVar8") (; ";")) (declaration "ulong uVar9;" (type_identifier "ulong") (identifier "uVar9") (; ";")) (declaration "int *piVar10;" (primitive_type "int") (pointer_declarator "*piVar10" (* "*") (identifier "piVar10")) (; ";")) (declaration "long lVar11;" (sized_type_specifier "long" (long "long")) (identifier "lVar11") (; ";")) (declaration "long in_FS_OFFSET;" (sized_type_specifier "long" (long "long")) (identifier "in_FS_OFFSET") (; ";")) (declaration "uint local_44;" (type_identifier "uint") (identifier "local_44") (; ";")) (declaration "long local_40;" (sized_type_specifier "long" (long "long")) (identifier "local_40") (; ";")) (expression_statement "local_40 = *(long *)(in_FS_OFFSET + 0x28);" (assignment_expression "local_40 = *(long *)(in_FS_OFFSET + 0x28)" (identifier "local_40") (= "=") (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" (* "*") (cast_expression "(long *)(in_FS_OFFSET + 0x28)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_FS_OFFSET + 0x28)" (( "(") (binary_expression "in_FS_OFFSET + 0x28" (identifier "in_FS_OFFSET") (+ "+") (number_literal "0x28")) () ")"))))) (; ";")) (expression_statement "plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);" (assignment_expression "plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44)" (identifier "plVar6") (= "=") (cast_expression "(long *)FUN_0010d8aa(param_1,param_2,&local_44)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0010d8aa(param_1,param_2,&local_44)" (identifier "FUN_0010d8aa") (argument_list "(param_1,param_2,&local_44)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (pointer_expression "&local_44" (& "&") (identifier "local_44")) () ")"))))) (; ";")) (expression_statement "lVar1 = plVar6[2];" (assignment_expression "lVar1 = plVar6[2]" (identifier "lVar1") (= "=") (subscript_expression "plVar6[2]" (identifier "plVar6") ([ "[") (number_literal "2") (] "]"))) (; ";")) (if_statement "if (lVar1 == 0) {\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }\n  else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" (if "if") (parenthesized_expression "(lVar1 == 0)" (( "(") (binary_expression "lVar1 == 0" (identifier "lVar1") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }\n  }" ({ "{") (if_statement "if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }" (if "if") (parenthesized_expression "((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0))" (( "(") (binary_expression "(param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)" (parenthesized_expression "(param_3 != 0)" (( "(") (binary_expression "param_3 != 0" (identifier "param_3") (!= "!=") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "(lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)" (( "(") (comma_expression "lVar7 = FUN_0011bd0f(0x20), lVar7 != 0" (assignment_expression "lVar7 = FUN_0011bd0f(0x20)" (identifier "lVar7") (= "=") (call_expression "FUN_0011bd0f(0x20)" (identifier "FUN_0011bd0f") (argument_list "(0x20)" (( "(") (number_literal "0x20") () ")")))) (, ",") (binary_expression "lVar7 != 0" (identifier "lVar7") (!= "!=") (number_literal "0"))) () ")"))) () ")")) (compound_statement "{\n      *(long *)(lVar7 + 0x18) = param_2;\n      *(long *)(lVar7 + 0x10) = param_3;\n      uVar4 = param_1[1] + 1;\n      param_1[1] = uVar4;\n      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }\n      lVar11 = *(long *)(param_1 + 4);\n      if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }\n      FUN_0010d840(param_1,lVar11,lVar7);\n      param_3 = lVar1;\n    }" ({ "{") (expression_statement "*(long *)(lVar7 + 0x18) = param_2;" (assignment_expression "*(long *)(lVar7 + 0x18) = param_2" (pointer_expression "*(long *)(lVar7 + 0x18)" (* "*") (cast_expression "(long *)(lVar7 + 0x18)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(lVar7 + 0x18)" (( "(") (binary_expression "lVar7 + 0x18" (identifier "lVar7") (+ "+") (number_literal "0x18")) () ")")))) (= "=") (identifier "param_2")) (; ";")) (expression_statement "*(long *)(lVar7 + 0x10) = param_3;" (assignment_expression "*(long *)(lVar7 + 0x10) = param_3" (pointer_expression "*(long *)(lVar7 + 0x10)" (* "*") (cast_expression "(long *)(lVar7 + 0x10)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(lVar7 + 0x10)" (( "(") (binary_expression "lVar7 + 0x10" (identifier "lVar7") (+ "+") (number_literal "0x10")) () ")")))) (= "=") (identifier "param_3")) (; ";")) (expression_statement "uVar4 = param_1[1] + 1;" (assignment_expression "uVar4 = param_1[1] + 1" (identifier "uVar4") (= "=") (binary_expression "param_1[1] + 1" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (+ "+") (number_literal "1"))) (; ";")) (expression_statement "param_1[1] = uVar4;" (assignment_expression "param_1[1] = uVar4" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (= "=") (identifier "uVar4")) (; ";")) (if_statement "if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }" (if "if") (parenthesized_expression "((9 < uVar4) && (*param_1 * 2 < uVar4))" (( "(") (binary_expression "(9 < uVar4) && (*param_1 * 2 < uVar4)" (parenthesized_expression "(9 < uVar4)" (( "(") (binary_expression "9 < uVar4" (number_literal "9") (< "<") (identifier "uVar4")) () ")")) (&& "&&") (parenthesized_expression "(*param_1 * 2 < uVar4)" (( "(") (binary_expression "*param_1 * 2 < uVar4" (binary_expression "*param_1 * 2" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (* "*") (number_literal "2")) (< "<") (identifier "uVar4")) () ")"))) () ")")) (compound_statement "{\n        uVar4 = uVar4 * 2;\n        if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }\n        if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }\n      }" ({ "{") (expression_statement "uVar4 = uVar4 * 2;" (assignment_expression "uVar4 = uVar4 * 2" (identifier "uVar4") (= "=") (binary_expression "uVar4 * 2" (identifier "uVar4") (* "*") (number_literal "2"))) (; ";")) (if_statement "if (0x40 < uVar4) {\n          uVar4 = 0x40;\n        }" (if "if") (parenthesized_expression "(0x40 < uVar4)" (( "(") (binary_expression "0x40 < uVar4" (number_literal "0x40") (< "<") (identifier "uVar4")) () ")")) (compound_statement "{\n          uVar4 = 0x40;\n        }" ({ "{") (expression_statement "uVar4 = 0x40;" (assignment_expression "uVar4 = 0x40" (identifier "uVar4") (= "=") (number_literal "0x40")) (; ";")) (} "}"))) (if_statement "if (*param_1 != uVar4) {\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }" (if "if") (parenthesized_expression "(*param_1 != uVar4)" (( "(") (binary_expression "*param_1 != uVar4" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (!= "!=") (identifier "uVar4")) () ")")) (compound_statement "{\n          FUN_0010cba2();\n          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);\n          FUN_0010cbbb();\n          if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }\n        }" ({ "{") (expression_statement "FUN_0010cba2();" (call_expression "FUN_0010cba2()" (identifier "FUN_0010cba2") (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "__s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);" (assignment_expression "__s = (void *)FUN_0011bd0f((ulong)uVar4 << 4)" (identifier "__s") (= "=") (cast_expression "(void *)FUN_0011bd0f((ulong)uVar4 << 4)" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0011bd0f((ulong)uVar4 << 4)" (identifier "FUN_0011bd0f") (argument_list "((ulong)uVar4 << 4)" (( "(") (binary_expression "(ulong)uVar4 << 4" (cast_expression "(ulong)uVar4" (( "(") (type_descriptor "ulong" (type_identifier "ulong")) () ")") (identifier "uVar4")) (<< "<<") (number_literal "4")) () ")"))))) (; ";")) (expression_statement "FUN_0010cbbb();" (call_expression "FUN_0010cbbb()" (identifier "FUN_0010cbbb") (argument_list "()" (( "(") () ")"))) (; ";")) (if_statement "if (__s != (void *)0x0) {\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }" (if "if") (parenthesized_expression "(__s != (void *)0x0)" (( "(") (binary_expression "__s != (void *)0x0" (identifier "__s") (!= "!=") (cast_expression "(void *)0x0" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n            sqlite3_free(*(undefined8 *)(param_1 + 4));\n            *(void **)(param_1 + 4) = __s;\n            iVar5 = FUN_0010ccbd(__s);\n            uVar8 = (ulong)(long)iVar5 >> 4;\n            *param_1 = (uint)uVar8;\n            memset(__s,0,(uVar8 & 0xffffffff) << 4);\n            puVar2 = *(undefined8 **)(param_1 + 2);\n            param_1[2] = 0;\n            param_1[3] = 0;\n            while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }\n            uVar8 = FUN_0010d806(param_2);\n            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);\n          }" ({ "{") (expression_statement "sqlite3_free(*(undefined8 *)(param_1 + 4));" (call_expression "sqlite3_free(*(undefined8 *)(param_1 + 4))" (identifier "sqlite3_free") (argument_list "(*(undefined8 *)(param_1 + 4))" (( "(") (pointer_expression "*(undefined8 *)(param_1 + 4)" (* "*") (cast_expression "(undefined8 *)(param_1 + 4)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")")))) () ")"))) (; ";")) (expression_statement "*(void **)(param_1 + 4) = __s;" (assignment_expression "*(void **)(param_1 + 4) = __s" (pointer_expression "*(void **)(param_1 + 4)" (* "*") (cast_expression "(void **)(param_1 + 4)" (( "(") (type_descriptor "void **" (primitive_type "void") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")")))) (= "=") (identifier "__s")) (; ";")) (expression_statement "iVar5 = FUN_0010ccbd(__s);" (assignment_expression "iVar5 = FUN_0010ccbd(__s)" (identifier "iVar5") (= "=") (call_expression "FUN_0010ccbd(__s)" (identifier "FUN_0010ccbd") (argument_list "(__s)" (( "(") (identifier "__s") () ")")))) (; ";")) (expression_statement "uVar8 = (ulong)(long)iVar5 >> 4;" (assignment_expression "uVar8 = (ulong)(long)iVar5 >> 4" (identifier "uVar8") (= "=") (binary_expression "(ulong)(long)iVar5 >> 4" (cast_expression "(ulong)(long)iVar5" (( "(") (type_descriptor "ulong" (type_identifier "ulong")) () ")") (cast_expression "(long)iVar5" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "iVar5"))) (>> ">>") (number_literal "4"))) (; ";")) (expression_statement "*param_1 = (uint)uVar8;" (assignment_expression "*param_1 = (uint)uVar8" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (= "=") (cast_expression "(uint)uVar8" (( "(") (type_descriptor "uint" (type_identifier "uint")) () ")") (identifier "uVar8"))) (; ";")) (expression_statement "memset(__s,0,(uVar8 & 0xffffffff) << 4);" (call_expression "memset(__s,0,(uVar8 & 0xffffffff) << 4)" (identifier "memset") (argument_list "(__s,0,(uVar8 & 0xffffffff) << 4)" (( "(") (identifier "__s") (, ",") (number_literal "0") (, ",") (binary_expression "(uVar8 & 0xffffffff) << 4" (parenthesized_expression "(uVar8 & 0xffffffff)" (( "(") (binary_expression "uVar8 & 0xffffffff" (identifier "uVar8") (& "&") (number_literal "0xffffffff")) () ")")) (<< "<<") (number_literal "4")) () ")"))) (; ";")) (expression_statement "puVar2 = *(undefined8 **)(param_1 + 2);" (assignment_expression "puVar2 = *(undefined8 **)(param_1 + 2)" (identifier "puVar2") (= "=") (pointer_expression "*(undefined8 **)(param_1 + 2)" (* "*") (cast_expression "(undefined8 **)(param_1 + 2)" (( "(") (type_descriptor "undefined8 **" (type_identifier "undefined8") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1 + 2)" (( "(") (binary_expression "param_1 + 2" (identifier "param_1") (+ "+") (number_literal "2")) () ")"))))) (; ";")) (expression_statement "param_1[2] = 0;" (assignment_expression "param_1[2] = 0" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "param_1[3] = 0;" (assignment_expression "param_1[3] = 0" (subscript_expression "param_1[3]" (identifier "param_1") ([ "[") (number_literal "3") (] "]")) (= "=") (number_literal "0")) (; ";")) (while_statement "while (puVar2 != (undefined8 *)0x0) {\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }" (while "while") (parenthesized_expression "(puVar2 != (undefined8 *)0x0)" (( "(") (binary_expression "puVar2 != (undefined8 *)0x0" (identifier "puVar2") (!= "!=") (cast_expression "(undefined8 *)0x0" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n              uVar9 = FUN_0010d806(puVar2[3]);\n              puVar3 = (undefined8 *)*puVar2;\n              FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);\n              puVar2 = puVar3;\n            }" ({ "{") (expression_statement "uVar9 = FUN_0010d806(puVar2[3]);" (assignment_expression "uVar9 = FUN_0010d806(puVar2[3])" (identifier "uVar9") (= "=") (call_expression "FUN_0010d806(puVar2[3])" (identifier "FUN_0010d806") (argument_list "(puVar2[3])" (( "(") (subscript_expression "puVar2[3]" (identifier "puVar2") ([ "[") (number_literal "3") (] "]")) () ")")))) (; ";")) (expression_statement "puVar3 = (undefined8 *)*puVar2;" (assignment_expression "puVar3 = (undefined8 *)*puVar2" (identifier "puVar3") (= "=") (cast_expression "(undefined8 *)*puVar2" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*puVar2" (* "*") (identifier "puVar2")))) (; ";")) (expression_statement "FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2);" (call_expression "FUN_0010d840(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2)" (identifier "FUN_0010d840") (argument_list "(param_1,(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),\n                           puVar2)" (( "(") (identifier "param_1") (, ",") (cast_expression "(void *)((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10)" (( "(") (type_descriptor "void *" (primitive_type "void") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10)" (( "(") (binary_expression "(long)__s +\n                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10" (cast_expression "(long)__s" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "__s")) (+ "+") (binary_expression "((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10" (parenthesized_expression "((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff))" (( "(") (binary_expression "(uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)" (parenthesized_expression "(uVar9 & 0xffffffff)" (( "(") (binary_expression "uVar9 & 0xffffffff" (identifier "uVar9") (& "&") (number_literal "0xffffffff")) () ")")) (% "%") (parenthesized_expression "(uVar8 & 0xffffffff)" (( "(") (binary_expression "uVar8 & 0xffffffff" (identifier "uVar8") (& "&") (number_literal "0xffffffff")) () ")"))) () ")")) (* "*") (number_literal "0x10"))) () ")"))) (, ",") (identifier "puVar2") () ")"))) (; ";")) (expression_statement "puVar2 = puVar3;" (assignment_expression "puVar2 = puVar3" (identifier "puVar2") (= "=") (identifier "puVar3")) (; ";")) (} "}"))) (expression_statement "uVar8 = FUN_0010d806(param_2);" (assignment_expression "uVar8 = FUN_0010d806(param_2)" (identifier "uVar8") (= "=") (call_expression "FUN_0010d806(param_2)" (identifier "FUN_0010d806") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (expression_statement "local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);" (assignment_expression "local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1)" (identifier "local_44") (= "=") (call_expression "(uint)((uVar8 & 0xffffffff) % (ulong)*param_1)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "((uVar8 & 0xffffffff) % (ulong)*param_1)" (( "(") (binary_expression "(uVar8 & 0xffffffff) % (ulong)*param_1" (binary_expression "(uVar8 & 0xffffffff) % (ulong)" (parenthesized_expression "(uVar8 & 0xffffffff)" (( "(") (binary_expression "uVar8 & 0xffffffff" (identifier "uVar8") (& "&") (number_literal "0xffffffff")) () ")")) (% "%") (parenthesized_expression "(ulong)" (( "(") (identifier "ulong") () ")"))) (* "*") (identifier "param_1")) () ")")))) (; ";")) (} "}"))) (} "}"))) (} "}"))) (expression_statement "lVar11 = *(long *)(param_1 + 4);" (assignment_expression "lVar11 = *(long *)(param_1 + 4)" (identifier "lVar11") (= "=") (pointer_expression "*(long *)(param_1 + 4)" (* "*") (cast_expression "(long *)(param_1 + 4)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (if_statement "if (lVar11 != 0) {\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }" (if "if") (parenthesized_expression "(lVar11 != 0)" (( "(") (binary_expression "lVar11 != 0" (identifier "lVar11") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        lVar11 = lVar11 + (ulong)local_44 * 0x10;\n      }" ({ "{") (expression_statement "lVar11 = lVar11 + (ulong)local_44 * 0x10;" (assignment_expression "lVar11 = lVar11 + (ulong)local_44 * 0x10" (identifier "lVar11") (= "=") (binary_expression "lVar11 + (ulong)local_44 * 0x10" (identifier "lVar11") (+ "+") (binary_expression "(ulong)local_44 * 0x10" (cast_expression "(ulong)local_44" (( "(") (type_descriptor "ulong" (type_identifier "ulong")) () ")") (identifier "local_44")) (* "*") (number_literal "0x10")))) (; ";")) (} "}"))) (expression_statement "FUN_0010d840(param_1,lVar11,lVar7);" (call_expression "FUN_0010d840(param_1,lVar11,lVar7)" (identifier "FUN_0010d840") (argument_list "(param_1,lVar11,lVar7)" (( "(") (identifier "param_1") (, ",") (identifier "lVar11") (, ",") (identifier "lVar7") () ")"))) (; ";")) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" (identifier "param_3") (= "=") (identifier "lVar1")) (; ";")) (} "}"))) (} "}")) (else_clause "else if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" (else "else") (if_statement "if (param_3 == 0) {\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }\n  else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" (if "if") (parenthesized_expression "(param_3 == 0)" (( "(") (binary_expression "param_3 == 0" (identifier "param_3") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }\n    if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }\n    if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }\n    sqlite3_free(plVar6);\n    uVar4 = param_1[1];\n    param_1[1] = uVar4 - 1;\n    param_3 = lVar1;\n    if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }\n  }" ({ "{") (if_statement "if ((long *)plVar6[1] == (long *)0x0) {\n      *(long *)(param_1 + 2) = *plVar6;\n    }\n    else {\n      *(long *)plVar6[1] = *plVar6;\n    }" (if "if") (parenthesized_expression "((long *)plVar6[1] == (long *)0x0)" (( "(") (binary_expression "(long *)plVar6[1] == (long *)0x0" (cast_expression "(long *)plVar6[1]" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (subscript_expression "plVar6[1]" (identifier "plVar6") ([ "[") (number_literal "1") (] "]"))) (== "==") (cast_expression "(long *)0x0" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n      *(long *)(param_1 + 2) = *plVar6;\n    }" ({ "{") (expression_statement "*(long *)(param_1 + 2) = *plVar6;" (assignment_expression "*(long *)(param_1 + 2) = *plVar6" (pointer_expression "*(long *)(param_1 + 2)" (* "*") (cast_expression "(long *)(param_1 + 2)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 2)" (( "(") (binary_expression "param_1 + 2" (identifier "param_1") (+ "+") (number_literal "2")) () ")")))) (= "=") (pointer_expression "*plVar6" (* "*") (identifier "plVar6"))) (; ";")) (} "}")) (else_clause "else {\n      *(long *)plVar6[1] = *plVar6;\n    }" (else "else") (compound_statement "{\n      *(long *)plVar6[1] = *plVar6;\n    }" ({ "{") (expression_statement "*(long *)plVar6[1] = *plVar6;" (assignment_expression "*(long *)plVar6[1] = *plVar6" (pointer_expression "*(long *)plVar6[1]" (* "*") (cast_expression "(long *)plVar6[1]" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (subscript_expression "plVar6[1]" (identifier "plVar6") ([ "[") (number_literal "1") (] "]")))) (= "=") (pointer_expression "*plVar6" (* "*") (identifier "plVar6"))) (; ";")) (} "}")))) (if_statement "if (*plVar6 != 0) {\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }" (if "if") (parenthesized_expression "(*plVar6 != 0)" (( "(") (binary_expression "*plVar6 != 0" (pointer_expression "*plVar6" (* "*") (identifier "plVar6")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      *(long *)(*plVar6 + 8) = plVar6[1];\n    }" ({ "{") (expression_statement "*(long *)(*plVar6 + 8) = plVar6[1];" (assignment_expression "*(long *)(*plVar6 + 8) = plVar6[1]" (pointer_expression "*(long *)(*plVar6 + 8)" (* "*") (cast_expression "(long *)(*plVar6 + 8)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(*plVar6 + 8)" (( "(") (binary_expression "*plVar6 + 8" (pointer_expression "*plVar6" (* "*") (identifier "plVar6")) (+ "+") (number_literal "8")) () ")")))) (= "=") (subscript_expression "plVar6[1]" (identifier "plVar6") ([ "[") (number_literal "1") (] "]"))) (; ";")) (} "}"))) (if_statement "if (*(long *)(param_1 + 4) != 0) {\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }" (if "if") (parenthesized_expression "(*(long *)(param_1 + 4) != 0)" (( "(") (binary_expression "*(long *)(param_1 + 4) != 0" (pointer_expression "*(long *)(param_1 + 4)" (* "*") (cast_expression "(long *)(param_1 + 4)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")")))) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));\n      if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }\n      *piVar10 = *piVar10 + -1;\n    }" ({ "{") (expression_statement "piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));" (assignment_expression "piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" (identifier "piVar10") (= "=") (cast_expression "(int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((ulong)local_44 * 0x10 + *(long *)(param_1 + 4))" (( "(") (binary_expression "(ulong)local_44 * 0x10 + *(long *)(param_1 + 4)" (binary_expression "(ulong)local_44 * 0x10" (cast_expression "(ulong)local_44" (( "(") (type_descriptor "ulong" (type_identifier "ulong")) () ")") (identifier "local_44")) (* "*") (number_literal "0x10")) (+ "+") (pointer_expression "*(long *)(param_1 + 4)" (* "*") (cast_expression "(long *)(param_1 + 4)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")"))))) () ")")))) (; ";")) (if_statement "if (plVar6 == *(long **)(piVar10 + 2)) {\n        *(long *)(piVar10 + 2) = *plVar6;\n      }" (if "if") (parenthesized_expression "(plVar6 == *(long **)(piVar10 + 2))" (( "(") (binary_expression "plVar6 == *(long **)(piVar10 + 2)" (identifier "plVar6") (== "==") (pointer_expression "*(long **)(piVar10 + 2)" (* "*") (cast_expression "(long **)(piVar10 + 2)" (( "(") (type_descriptor "long **" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(piVar10 + 2)" (( "(") (binary_expression "piVar10 + 2" (identifier "piVar10") (+ "+") (number_literal "2")) () ")"))))) () ")")) (compound_statement "{\n        *(long *)(piVar10 + 2) = *plVar6;\n      }" ({ "{") (expression_statement "*(long *)(piVar10 + 2) = *plVar6;" (assignment_expression "*(long *)(piVar10 + 2) = *plVar6" (pointer_expression "*(long *)(piVar10 + 2)" (* "*") (cast_expression "(long *)(piVar10 + 2)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(piVar10 + 2)" (( "(") (binary_expression "piVar10 + 2" (identifier "piVar10") (+ "+") (number_literal "2")) () ")")))) (= "=") (pointer_expression "*plVar6" (* "*") (identifier "plVar6"))) (; ";")) (} "}"))) (expression_statement "*piVar10 = *piVar10 + -1;" (assignment_expression "*piVar10 = *piVar10 + -1" (pointer_expression "*piVar10" (* "*") (identifier "piVar10")) (= "=") (binary_expression "*piVar10 + -1" (pointer_expression "*piVar10" (* "*") (identifier "piVar10")) (+ "+") (number_literal "-1"))) (; ";")) (} "}"))) (expression_statement "sqlite3_free(plVar6);" (call_expression "sqlite3_free(plVar6)" (identifier "sqlite3_free") (argument_list "(plVar6)" (( "(") (identifier "plVar6") () ")"))) (; ";")) (expression_statement "uVar4 = param_1[1];" (assignment_expression "uVar4 = param_1[1]" (identifier "uVar4") (= "=") (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]"))) (; ";")) (expression_statement "param_1[1] = uVar4 - 1;" (assignment_expression "param_1[1] = uVar4 - 1" (subscript_expression "param_1[1]" (identifier "param_1") ([ "[") (number_literal "1") (] "]")) (= "=") (binary_expression "uVar4 - 1" (identifier "uVar4") (- "-") (number_literal "1"))) (; ";")) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" (identifier "param_3") (= "=") (identifier "lVar1")) (; ";")) (if_statement "if (uVar4 - 1 == 0) {\n      FUN_0011ad1b(param_1);\n    }" (if "if") (parenthesized_expression "(uVar4 - 1 == 0)" (( "(") (binary_expression "uVar4 - 1 == 0" (binary_expression "uVar4 - 1" (identifier "uVar4") (- "-") (number_literal "1")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      FUN_0011ad1b(param_1);\n    }" ({ "{") (expression_statement "FUN_0011ad1b(param_1);" (call_expression "FUN_0011ad1b(param_1)" (identifier "FUN_0011ad1b") (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" (else "else") (compound_statement "{\n    plVar6[2] = param_3;\n    plVar6[3] = param_2;\n    param_3 = lVar1;\n  }" ({ "{") (expression_statement "plVar6[2] = param_3;" (assignment_expression "plVar6[2] = param_3" (subscript_expression "plVar6[2]" (identifier "plVar6") ([ "[") (number_literal "2") (] "]")) (= "=") (identifier "param_3")) (; ";")) (expression_statement "plVar6[3] = param_2;" (assignment_expression "plVar6[3] = param_2" (subscript_expression "plVar6[3]" (identifier "plVar6") ([ "[") (number_literal "3") (] "]")) (= "=") (identifier "param_2")) (; ";")) (expression_statement "param_3 = lVar1;" (assignment_expression "param_3 = lVar1" (identifier "param_3") (= "=") (identifier "lVar1")) (; ";")) (} "}")))))) (if_statement "if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {\n    return param_3;\n  }" (if "if") (parenthesized_expression "(local_40 == *(long *)(in_FS_OFFSET + 0x28))" (( "(") (binary_expression "local_40 == *(long *)(in_FS_OFFSET + 0x28)" (identifier "local_40") (== "==") (pointer_expression "*(long *)(in_FS_OFFSET + 0x28)" (* "*") (cast_expression "(long *)(in_FS_OFFSET + 0x28)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(in_FS_OFFSET + 0x28)" (( "(") (binary_expression "in_FS_OFFSET + 0x28" (identifier "in_FS_OFFSET") (+ "+") (number_literal "0x28")) () ")"))))) () ")")) (compound_statement "{\n    return param_3;\n  }" ({ "{") (return_statement "return param_3;" (return "return") (identifier "param_3") (; ";")) (} "}"))) (expression_statement "__stack_chk_fail();" (call_expression "__stack_chk_fail()" (identifier "__stack_chk_fail") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))

void * function_1(type_1 *pH,char *pKey,void *var_4)

{
  void *var_3;
  type_2 *var_14;
  type_2 *pHVar2;
  type_3 var_7;
  int iVar4;
  type_3 var_17;
  type_2 *var_6;
  type_4 *var_10;
  long var_1;
  type_3 var_18;
  long var_20;
  
  var_20 = *(long *)(var_1 + 0x28);
  var_6 = var_2(pH,pKey,&var_18);
  var_3 = var_6->var_4;
  if (var_3 == (void *)0x0) {
    if ((var_4 != (void *)0x0) &&
       (var_6 = (type_2 *)var_5(0x20), var_6 != (type_2 *)0x0)) {
      var_6->pKey = pKey;
      var_6->var_4 = var_4;
      var_7 = pH->count + 1;
      pH->count = var_7;
      if ((9 < var_7) && (pH->htsize * 2 < var_7)) {
        var_7 = var_7 * 2;
        if (0x40 < var_7) {
          var_7 = 0x40;
        }
        if (pH->htsize != var_7) {
          var_8();
          var_10 = (type_4 *)var_5((type_5)var_7 << 4);
          var_9();
          if (var_10 != (type_4 *)0x0) {
            var_11(pH->ht);
            pH->ht = var_10;
            iVar4 = var_12(var_10);
            var_7 = (type_3)((type_5)(long)iVar4 >> 4);
            pH->htsize = var_7;
            var_13(var_10,0,((type_5)(long)iVar4 >> 4 & 0xffffffff) << 4);
            var_14 = pH->first;
            pH->first = (type_2 *)0x0;
            while (var_14 != (type_2 *)0x0) {
              var_17 = var_15(var_14->pKey);
              pHVar2 = var_14->next;
              var_16(pH,var_10 + var_17 % var_7,var_14);
              var_14 = pHVar2;
            }
            var_7 = var_15(pKey);
            var_18 = var_7 % pH->htsize;
          }
        }
      }
      var_10 = pH->ht;
      if (var_10 != (type_4 *)0x0) {
        var_10 = var_10 + var_18;
      }
      var_16(pH,var_10,var_6);
      var_4 = var_3;
    }
  }
  else if (var_4 == (void *)0x0) {
    if (var_6->prev == (type_2 *)0x0) {
      pH->first = var_6->next;
    }
    else {
      var_6->prev->next = var_6->next;
    }
    if (var_6->next != (type_2 *)0x0) {
      var_6->next->prev = var_6->prev;
    }
    if (pH->ht != (type_4 *)0x0) {
      var_10 = pH->ht + var_18;
      if (var_6 == var_10->chain) {
        var_10->chain = var_6->next;
      }
      var_10->count = var_10->count - 1;
    }
    var_11(var_6);
    var_7 = pH->count - 1;
    pH->count = var_7;
    var_4 = var_3;
    if (var_7 == 0) {
      var_19(pH);
    }
  }
  else {
    var_6->var_4 = var_4;
    var_6->pKey = pKey;
    var_4 = var_3;
  }
  if (var_20 == *(long *)(var_1 + 0x28)) {
    return var_4;
  }
                    /* WARNING: Subroutine does not return */
  var_21();
}


(translation_unit (function_definition type: (sized_type_specifier) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (sized_type_specifier) declarator: (identifier)) (parameter_declaration type: (sized_type_specifier) declarator: (identifier)))) body: (compound_statement (declaration type: (sized_type_specifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (sized_type_specifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (sized_type_specifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (sized_type_specifier) declarator: (identifier)) (declaration type: (sized_type_specifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (sized_type_specifier) declarator: (identifier)) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (pointer_expression argument: (identifier))))))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (number_literal)))) right: (binary_expression left: (identifier) right: (number_literal)))))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (number_literal) right: (identifier))) right: (parenthesized_expression (binary_expression left: (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal)) right: (identifier))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (number_literal) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (identifier))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (cast_expression type: (type_descriptor type: (type_identifier)) value: (cast_expression type: (type_descriptor type: (sized_type_specifier)) value: (identifier))) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal) (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (while_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (subscript_expression argument: (identifier) index: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (sized_type_specifier)) value: (identifier)) right: (binary_expression left: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))))) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (identifier))) right: (identifier)))))))))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (binary_expression left: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))))) alternative: (else_clause (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (subscript_expression argument: (identifier) index: (number_literal))) right: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (pointer_expression argument: (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (subscript_expression argument: (identifier) index: (number_literal)))) right: (pointer_expression argument: (identifier))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))))) right: (subscript_expression argument: (identifier) index: (number_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (binary_expression left: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)) right: (number_literal)) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (pointer_expression argument: (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal)))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier))))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (identifier)))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) consequence: (compound_statement (return_statement (identifier)))) (expression_statement (call_expression function: (identifier) arguments: (argument_list))))))

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

{
  long lVar1;
  undefined8 *puVar2;
  undefined8 *puVar3;
  uint uVar4;
  int iVar5;
  long *plVar6;
  long lVar7;
  void *__s;
  ulong uVar8;
  ulong uVar9;
  int *piVar10;
  long lVar11;
  long in_FS_OFFSET;
  uint local_44;
  long local_40;
  
  local_40 = *(long *)(in_FS_OFFSET + 0x28);
  plVar6 = (long *)FUN_0010d8aa(param_1,param_2,&local_44);
  lVar1 = plVar6[2];
  if (lVar1 == 0) {
    if ((param_3 != 0) && (lVar7 = FUN_0011bd0f(0x20), lVar7 != 0)) {
      *(long *)(lVar7 + 0x18) = param_2;
      *(long *)(lVar7 + 0x10) = param_3;
      uVar4 = param_1[1] + 1;
      param_1[1] = uVar4;
      if ((9 < uVar4) && (*param_1 * 2 < uVar4)) {
        uVar4 = uVar4 * 2;
        if (0x40 < uVar4) {
          uVar4 = 0x40;
        }
        if (*param_1 != uVar4) {
          FUN_0010cba2();
          __s = (void *)FUN_0011bd0f((ulong)uVar4 << 4);
          FUN_0010cbbb();
          if (__s != (void *)0x0) {
            sqlite3_free(*(undefined8 *)(param_1 + 4));
            *(void **)(param_1 + 4) = __s;
            iVar5 = FUN_0010ccbd(__s);
            uVar8 = (ulong)(long)iVar5 >> 4;
            *param_1 = (uint)uVar8;
            memset(__s,0,(uVar8 & 0xffffffff) << 4);
            puVar2 = *(undefined8 **)(param_1 + 2);
            param_1[2] = 0;
            param_1[3] = 0;
            while (puVar2 != (undefined8 *)0x0) {
              uVar9 = FUN_0010d806(puVar2[3]);
              puVar3 = (undefined8 *)*puVar2;
              FUN_0010d840(param_1,(void *)((long)__s +
                                           ((uVar9 & 0xffffffff) % (uVar8 & 0xffffffff)) * 0x10),
                           puVar2);
              puVar2 = puVar3;
            }
            uVar8 = FUN_0010d806(param_2);
            local_44 = (uint)((uVar8 & 0xffffffff) % (ulong)*param_1);
          }
        }
      }
      lVar11 = *(long *)(param_1 + 4);
      if (lVar11 != 0) {
        lVar11 = lVar11 + (ulong)local_44 * 0x10;
      }
      FUN_0010d840(param_1,lVar11,lVar7);
      param_3 = lVar1;
    }
  }
  else if (param_3 == 0) {
    if ((long *)plVar6[1] == (long *)0x0) {
      *(long *)(param_1 + 2) = *plVar6;
    }
    else {
      *(long *)plVar6[1] = *plVar6;
    }
    if (*plVar6 != 0) {
      *(long *)(*plVar6 + 8) = plVar6[1];
    }
    if (*(long *)(param_1 + 4) != 0) {
      piVar10 = (int *)((ulong)local_44 * 0x10 + *(long *)(param_1 + 4));
      if (plVar6 == *(long **)(piVar10 + 2)) {
        *(long *)(piVar10 + 2) = *plVar6;
      }
      *piVar10 = *piVar10 + -1;
    }
    sqlite3_free(plVar6);
    uVar4 = param_1[1];
    param_1[1] = uVar4 - 1;
    param_3 = lVar1;
    if (uVar4 - 1 == 0) {
      FUN_0011ad1b(param_1);
    }
  }
  else {
    plVar6[2] = param_3;
    plVar6[3] = param_2;
    param_3 = lVar1;
  }
  if (local_40 == *(long *)(in_FS_OFFSET + 0x28)) {
    return param_3;
  }
                    /* WARNING: Subroutine does not return */
  __stack_chk_fail();
}

