
int __regparm3 querySharedCacheTableLock(Btree *p,Pgno iTab,u8 eLock)

{
  BtShared *pBVar1;
  BtLock *pBVar2;
  
  if (p->sharable != '\0') {
    pBVar1 = p->pBt;
    if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {
      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);
      return 0x106;
    }
    for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {
      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {
        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);
        if (eLock != '\x02') {
          return 0x106;
        }
        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;
        return 0x106;
      }
    }
  }
  return 0;
}



undefined4 __regparm3 FUN_0004e1e0(int param_1,int param_2,char param_3)

{
  int iVar1;
  int *piVar2;
  
  if (*(char *)(param_1 + 9) != '\0') {
    iVar1 = *(int *)(param_1 + 4);
    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {
      FUN_0004e100();
      return 0x106;
    }
    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {
      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {
        FUN_0004e100();
        if (param_3 != '\x02') {
          return 0x106;
        }
        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;
        return 0x106;
      }
    }
  }
  return 0;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
SUB ESP,0xc
CMP byte ptr [EAX + 0x9],0x0
JZ 0x0004e248
MOV EBP,dword ptr [EAX + 0x4]
MOV EDI,ECX
MOV EBX,dword ptr [EBP + 0x4c]
CMP EBX,EAX
JZ 0x0004e1ff
TEST byte ptr [EBP + 0x16],0x40
JNZ 0x0004e252
MOV EBX,dword ptr [EBP + 0x48]
TEST EBX,EBX
JNZ 0x0004e217
JMP 0x0004e248
MOV EBX,dword ptr [EBX + 0xc]
TEST EBX,EBX
JZ 0x0004e248
MOV ESI,dword ptr [EBX]
CMP ESI,EAX
JZ 0x0004e210
CMP dword ptr [EBX + 0x4],EDX
JNZ 0x0004e210
CMP byte ptr [EBX + 0x8],CL
JZ 0x0004e210
MOV EAX,dword ptr [EAX]
MOV EDX,dword ptr [ESI]
CALL 0x0004e100
MOV ECX,EDI
MOV EAX,0x106
CMP CL,0x2
JNZ 0x0004e24a
OR word ptr [EBP + 0x16],0x80
JMP 0x0004e24a
XOR EAX,EAX
ADD ESP,0xc
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV EAX,dword ptr [EAX]
MOV EDX,dword ptr [EBX]
CALL 0x0004e100
MOV EAX,0x106
JMP 0x0004e24a
(translation_unit "undefined4 __regparm3 FUN_0004e1e0(int param_1,int param_2,char param_3)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}\n\n" (function_definition "undefined4 __regparm3 FUN_0004e1e0(int param_1,int param_2,char param_3)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_0004e1e0(int param_1,int param_2,char param_3)" identifier (parameter_list "(int param_1,int param_2,char param_3)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "char param_3" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (if_statement "if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }" if (parenthesized_expression "(*(char *)(param_1 + 9) != '\0')" ( (binary_expression "*(char *)(param_1 + 9) != '\0'" (pointer_expression "*(char *)(param_1 + 9)" * (cast_expression "(char *)(param_1 + 9)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 9)" ( (binary_expression "param_1 + 9" identifier + number_literal) )))) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }" { (expression_statement "iVar1 = *(int *)(param_1 + 4);" (assignment_expression "iVar1 = *(int *)(param_1 + 4)" identifier = (pointer_expression "*(int *)(param_1 + 4)" * (cast_expression "(int *)(param_1 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) (if_statement "if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }" if (parenthesized_expression "((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0))" ( (binary_expression "(*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)" (parenthesized_expression "(*(int *)(iVar1 + 0x4c) != param_1)" ( (binary_expression "*(int *)(iVar1 + 0x4c) != param_1" (pointer_expression "*(int *)(iVar1 + 0x4c)" * (cast_expression "(int *)(iVar1 + 0x4c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x4c)" ( (binary_expression "iVar1 + 0x4c" identifier + number_literal) )))) != identifier) )) && (parenthesized_expression "((*(byte *)(iVar1 + 0x16) & 0x40) != 0)" ( (binary_expression "(*(byte *)(iVar1 + 0x16) & 0x40) != 0" (parenthesized_expression "(*(byte *)(iVar1 + 0x16) & 0x40)" ( (binary_expression "*(byte *)(iVar1 + 0x16) & 0x40" (pointer_expression "*(byte *)(iVar1 + 0x16)" * (cast_expression "(byte *)(iVar1 + 0x16)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x16)" ( (binary_expression "iVar1 + 0x16" identifier + number_literal) )))) & number_literal) )) != number_literal) ))) )) (compound_statement "{\n      FUN_0004e100();\n      return 0x106;\n    }" { (expression_statement "FUN_0004e100();" (call_expression "FUN_0004e100()" identifier (argument_list "()" ( ))) ;) (return_statement "return 0x106;" return number_literal ;) })) (for_statement "for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }" for ( (assignment_expression "piVar2 = *(int **)(iVar1 + 0x48)" identifier = (pointer_expression "*(int **)(iVar1 + 0x48)" * (cast_expression "(int **)(iVar1 + 0x48)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(iVar1 + 0x48)" ( (binary_expression "iVar1 + 0x48" identifier + number_literal) ))))) ; (binary_expression "piVar2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ; (assignment_expression "piVar2 = (int *)piVar2[3]" identifier = (cast_expression "(int *)piVar2[3]" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar2[3]" identifier [ number_literal ]))) ) (compound_statement "{\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }" { (if_statement "if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }" if (parenthesized_expression "(((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3))" ( (binary_expression "((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)" (parenthesized_expression "((*piVar2 != param_1) && (piVar2[1] == param_2))" ( (binary_expression "(*piVar2 != param_1) && (piVar2[1] == param_2)" (parenthesized_expression "(*piVar2 != param_1)" ( (binary_expression "*piVar2 != param_1" (pointer_expression "*piVar2" * identifier) != identifier) )) && (parenthesized_expression "(piVar2[1] == param_2)" ( (binary_expression "piVar2[1] == param_2" (subscript_expression "piVar2[1]" identifier [ number_literal ]) == identifier) ))) )) && (parenthesized_expression "((char)piVar2[2] != param_3)" ( (binary_expression "(char)piVar2[2] != param_3" (cast_expression "(char)piVar2[2]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "piVar2[2]" identifier [ number_literal ])) != identifier) ))) )) (compound_statement "{\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }" { (expression_statement "FUN_0004e100();" (call_expression "FUN_0004e100()" identifier (argument_list "()" ( ))) ;) (if_statement "if (param_3 != '\x02') {\n          return 0x106;\n        }" if (parenthesized_expression "(param_3 != '\x02')" ( (binary_expression "param_3 != '\x02'" identifier != (char_literal "'\x02'" ' escape_sequence ')) )) (compound_statement "{\n          return 0x106;\n        }" { (return_statement "return 0x106;" return number_literal ;) })) (expression_statement "*(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;" (assignment_expression "*(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80" (pointer_expression "*(ushort *)(iVar1 + 0x16)" * (cast_expression "(ushort *)(iVar1 + 0x16)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x16)" ( (binary_expression "iVar1 + 0x16" identifier + number_literal) )))) = (binary_expression "*(ushort *)(iVar1 + 0x16) | 0x80" (pointer_expression "*(ushort *)(iVar1 + 0x16)" * (cast_expression "(ushort *)(iVar1 + 0x16)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x16)" ( (binary_expression "iVar1 + 0x16" identifier + number_literal) )))) | number_literal)) ;) (return_statement "return 0x106;" return number_literal ;) })) })) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "int __regparm3 querySharedCacheTableLock(Btree *p,Pgno iTab,u8 eLock)\n\n{\n  BtShared *pBVar1;\n  BtLock *pBVar2;\n  \n  if (p->sharable != '\0') {\n    pBVar1 = p->pBt;\n    if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }\n    for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}\n\n" (function_definition "int __regparm3 querySharedCacheTableLock(Btree *p,Pgno iTab,u8 eLock)\n\n{\n  BtShared *pBVar1;\n  BtLock *pBVar2;\n  \n  if (p->sharable != '\0') {\n    pBVar1 = p->pBt;\n    if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }\n    for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "querySharedCacheTableLock(Btree *p,Pgno iTab,u8 eLock)" identifier (parameter_list "(Btree *p,Pgno iTab,u8 eLock)" ( (parameter_declaration "Btree *p" type_identifier (pointer_declarator "*p" * identifier)) , (parameter_declaration "Pgno iTab" type_identifier identifier) , (parameter_declaration "u8 eLock" type_identifier identifier) ))) (compound_statement "{\n  BtShared *pBVar1;\n  BtLock *pBVar2;\n  \n  if (p->sharable != '\0') {\n    pBVar1 = p->pBt;\n    if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }\n    for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" { (declaration "BtShared *pBVar1;" type_identifier (pointer_declarator "*pBVar1" * identifier) ;) (declaration "BtLock *pBVar2;" type_identifier (pointer_declarator "*pBVar2" * identifier) ;) (if_statement "if (p->sharable != '\0') {\n    pBVar1 = p->pBt;\n    if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }\n    for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }\n  }" if (parenthesized_expression "(p->sharable != '\0')" ( (binary_expression "p->sharable != '\0'" (field_expression "p->sharable" identifier -> field_identifier) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    pBVar1 = p->pBt;\n    if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }\n    for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }\n  }" { (expression_statement "pBVar1 = p->pBt;" (assignment_expression "pBVar1 = p->pBt" identifier = (field_expression "p->pBt" identifier -> field_identifier)) ;) (if_statement "if ((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)) {\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }" if (parenthesized_expression "((pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0))" ( (binary_expression "(pBVar1->pWriter != p) && ((pBVar1->btsFlags & 0x40) != 0)" (parenthesized_expression "(pBVar1->pWriter != p)" ( (binary_expression "pBVar1->pWriter != p" (field_expression "pBVar1->pWriter" identifier -> field_identifier) != identifier) )) && (parenthesized_expression "((pBVar1->btsFlags & 0x40) != 0)" ( (binary_expression "(pBVar1->btsFlags & 0x40) != 0" (parenthesized_expression "(pBVar1->btsFlags & 0x40)" ( (binary_expression "pBVar1->btsFlags & 0x40" (field_expression "pBVar1->btsFlags" identifier -> field_identifier) & number_literal) )) != number_literal) ))) )) (compound_statement "{\n      sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);\n      return 0x106;\n    }" { (expression_statement "sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db);" (call_expression "sqlite3ConnectionBlocked(p->db,pBVar1->pWriter->db)" identifier (argument_list "(p->db,pBVar1->pWriter->db)" ( (field_expression "p->db" identifier -> field_identifier) , (field_expression "pBVar1->pWriter->db" (field_expression "pBVar1->pWriter" identifier -> field_identifier) -> field_identifier) ))) ;) (return_statement "return 0x106;" return number_literal ;) })) (for_statement "for (pBVar2 = pBVar1->pLock; pBVar2 != (BtLock *)0x0; pBVar2 = pBVar2->pNext) {\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }" for ( (assignment_expression "pBVar2 = pBVar1->pLock" identifier = (field_expression "pBVar1->pLock" identifier -> field_identifier)) ; (binary_expression "pBVar2 != (BtLock *)0x0" identifier != (cast_expression "(BtLock *)0x0" ( (type_descriptor "BtLock *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) ; (assignment_expression "pBVar2 = pBVar2->pNext" identifier = (field_expression "pBVar2->pNext" identifier -> field_identifier)) ) (compound_statement "{\n      if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }\n    }" { (if_statement "if (((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)) {\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }" if (parenthesized_expression "(((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock))" ( (binary_expression "((pBVar2->pBtree != p) && (pBVar2->iTable == iTab)) && (pBVar2->eLock != eLock)" (parenthesized_expression "((pBVar2->pBtree != p) && (pBVar2->iTable == iTab))" ( (binary_expression "(pBVar2->pBtree != p) && (pBVar2->iTable == iTab)" (parenthesized_expression "(pBVar2->pBtree != p)" ( (binary_expression "pBVar2->pBtree != p" (field_expression "pBVar2->pBtree" identifier -> field_identifier) != identifier) )) && (parenthesized_expression "(pBVar2->iTable == iTab)" ( (binary_expression "pBVar2->iTable == iTab" (field_expression "pBVar2->iTable" identifier -> field_identifier) == identifier) ))) )) && (parenthesized_expression "(pBVar2->eLock != eLock)" ( (binary_expression "pBVar2->eLock != eLock" (field_expression "pBVar2->eLock" identifier -> field_identifier) != identifier) ))) )) (compound_statement "{\n        sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);\n        if (eLock != '\x02') {\n          return 0x106;\n        }\n        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;\n        return 0x106;\n      }" { (expression_statement "sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db);" (call_expression "sqlite3ConnectionBlocked(p->db,pBVar2->pBtree->db)" identifier (argument_list "(p->db,pBVar2->pBtree->db)" ( (field_expression "p->db" identifier -> field_identifier) , (field_expression "pBVar2->pBtree->db" (field_expression "pBVar2->pBtree" identifier -> field_identifier) -> field_identifier) ))) ;) (if_statement "if (eLock != '\x02') {\n          return 0x106;\n        }" if (parenthesized_expression "(eLock != '\x02')" ( (binary_expression "eLock != '\x02'" identifier != (char_literal "'\x02'" ' escape_sequence ')) )) (compound_statement "{\n          return 0x106;\n        }" { (return_statement "return 0x106;" return number_literal ;) })) (expression_statement "pBVar1->btsFlags = pBVar1->btsFlags | 0x80;" (assignment_expression "pBVar1->btsFlags = pBVar1->btsFlags | 0x80" (field_expression "pBVar1->btsFlags" identifier -> field_identifier) = (binary_expression "pBVar1->btsFlags | 0x80" (field_expression "pBVar1->btsFlags" identifier -> field_identifier) | number_literal)) ;) (return_statement "return 0x106;" return number_literal ;) })) })) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit "undefined4 __regparm3 FUN_0004e1e0(int param_1,int param_2,char param_3)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}\n\n" (function_definition "undefined4 __regparm3 FUN_0004e1e0(int param_1,int param_2,char param_3)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" type_identifier (ERROR "__regparm3" identifier) (function_declarator "FUN_0004e1e0(int param_1,int param_2,char param_3)" identifier (parameter_list "(int param_1,int param_2,char param_3)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) , (parameter_declaration "char param_3" primitive_type identifier) ))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "int *piVar2;" primitive_type (pointer_declarator "*piVar2" * identifier) ;) (if_statement "if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }" if (parenthesized_expression "(*(char *)(param_1 + 9) != '\0')" ( (binary_expression "*(char *)(param_1 + 9) != '\0'" (pointer_expression "*(char *)(param_1 + 9)" * (cast_expression "(char *)(param_1 + 9)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 9)" ( (binary_expression "param_1 + 9" identifier + number_literal) )))) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }" { (expression_statement "iVar1 = *(int *)(param_1 + 4);" (assignment_expression "iVar1 = *(int *)(param_1 + 4)" identifier = (pointer_expression "*(int *)(param_1 + 4)" * (cast_expression "(int *)(param_1 + 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 4)" ( (binary_expression "param_1 + 4" identifier + number_literal) ))))) ;) (if_statement "if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }" if (parenthesized_expression "((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0))" ( (binary_expression "(*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)" (parenthesized_expression "(*(int *)(iVar1 + 0x4c) != param_1)" ( (binary_expression "*(int *)(iVar1 + 0x4c) != param_1" (pointer_expression "*(int *)(iVar1 + 0x4c)" * (cast_expression "(int *)(iVar1 + 0x4c)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x4c)" ( (binary_expression "iVar1 + 0x4c" identifier + number_literal) )))) != identifier) )) && (parenthesized_expression "((*(byte *)(iVar1 + 0x16) & 0x40) != 0)" ( (binary_expression "(*(byte *)(iVar1 + 0x16) & 0x40) != 0" (parenthesized_expression "(*(byte *)(iVar1 + 0x16) & 0x40)" ( (binary_expression "*(byte *)(iVar1 + 0x16) & 0x40" (pointer_expression "*(byte *)(iVar1 + 0x16)" * (cast_expression "(byte *)(iVar1 + 0x16)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x16)" ( (binary_expression "iVar1 + 0x16" identifier + number_literal) )))) & number_literal) )) != number_literal) ))) )) (compound_statement "{\n      FUN_0004e100();\n      return 0x106;\n    }" { (expression_statement "FUN_0004e100();" (call_expression "FUN_0004e100()" identifier (argument_list "()" ( ))) ;) (return_statement "return 0x106;" return number_literal ;) })) (for_statement "for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }" for ( (assignment_expression "piVar2 = *(int **)(iVar1 + 0x48)" identifier = (pointer_expression "*(int **)(iVar1 + 0x48)" * (cast_expression "(int **)(iVar1 + 0x48)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(iVar1 + 0x48)" ( (binary_expression "iVar1 + 0x48" identifier + number_literal) ))))) ; (binary_expression "piVar2 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ; (assignment_expression "piVar2 = (int *)piVar2[3]" identifier = (cast_expression "(int *)piVar2[3]" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (subscript_expression "piVar2[3]" identifier [ number_literal ]))) ) (compound_statement "{\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }" { (if_statement "if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }" if (parenthesized_expression "(((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3))" ( (binary_expression "((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)" (parenthesized_expression "((*piVar2 != param_1) && (piVar2[1] == param_2))" ( (binary_expression "(*piVar2 != param_1) && (piVar2[1] == param_2)" (parenthesized_expression "(*piVar2 != param_1)" ( (binary_expression "*piVar2 != param_1" (pointer_expression "*piVar2" * identifier) != identifier) )) && (parenthesized_expression "(piVar2[1] == param_2)" ( (binary_expression "piVar2[1] == param_2" (subscript_expression "piVar2[1]" identifier [ number_literal ]) == identifier) ))) )) && (parenthesized_expression "((char)piVar2[2] != param_3)" ( (binary_expression "(char)piVar2[2] != param_3" (cast_expression "(char)piVar2[2]" ( (type_descriptor "char" primitive_type) ) (subscript_expression "piVar2[2]" identifier [ number_literal ])) != identifier) ))) )) (compound_statement "{\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }" { (expression_statement "FUN_0004e100();" (call_expression "FUN_0004e100()" identifier (argument_list "()" ( ))) ;) (if_statement "if (param_3 != '\x02') {\n          return 0x106;\n        }" if (parenthesized_expression "(param_3 != '\x02')" ( (binary_expression "param_3 != '\x02'" identifier != (char_literal "'\x02'" ' escape_sequence ')) )) (compound_statement "{\n          return 0x106;\n        }" { (return_statement "return 0x106;" return number_literal ;) })) (expression_statement "*(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;" (assignment_expression "*(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80" (pointer_expression "*(ushort *)(iVar1 + 0x16)" * (cast_expression "(ushort *)(iVar1 + 0x16)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x16)" ( (binary_expression "iVar1 + 0x16" identifier + number_literal) )))) = (binary_expression "*(ushort *)(iVar1 + 0x16) | 0x80" (pointer_expression "*(ushort *)(iVar1 + 0x16)" * (cast_expression "(ushort *)(iVar1 + 0x16)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar1 + 0x16)" ( (binary_expression "iVar1 + 0x16" identifier + number_literal) )))) | number_literal)) ;) (return_statement "return 0x106;" return number_literal ;) })) })) })) (return_statement "return 0;" return number_literal ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != IDENT) )) && (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT) )) != LIT) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) (return_statement return LIT ;) })) (for_statement for ( (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ; (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) ; (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (subscript_expression IDENT [ LIT ]))) ) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != IDENT) )) && (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) == IDENT) ))) )) && (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ])) != IDENT) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (char_literal ' escape_sequence ')) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) | LIT)) ;) (return_statement return LIT ;) })) })) })) (return_statement return LIT ;) })))
(function_definition "undefined4 __regparm3 FUN_0004e1e0(int param_1,int param_2,char param_3)\n\n{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" (type_identifier "undefined4") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_0004e1e0(int param_1,int param_2,char param_3)" (identifier "FUN_0004e1e0") (parameter_list "(int param_1,int param_2,char param_3)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) (, ",") (parameter_declaration "char param_3" (primitive_type "char") (identifier "param_3")) () ")"))) (compound_statement "{\n  int iVar1;\n  int *piVar2;\n  \n  if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }\n  return 0;\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "int *piVar2;" (primitive_type "int") (pointer_declarator "*piVar2" (* "*") (identifier "piVar2")) (; ";")) (if_statement "if (*(char *)(param_1 + 9) != '\0') {\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }" (if "if") (parenthesized_expression "(*(char *)(param_1 + 9) != '\0')" (( "(") (binary_expression "*(char *)(param_1 + 9) != '\0'" (pointer_expression "*(char *)(param_1 + 9)" (* "*") (cast_expression "(char *)(param_1 + 9)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 9)" (( "(") (binary_expression "param_1 + 9" (identifier "param_1") (+ "+") (number_literal "9")) () ")")))) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n    iVar1 = *(int *)(param_1 + 4);\n    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }\n    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }\n  }" ({ "{") (expression_statement "iVar1 = *(int *)(param_1 + 4);" (assignment_expression "iVar1 = *(int *)(param_1 + 4)" (identifier "iVar1") (= "=") (pointer_expression "*(int *)(param_1 + 4)" (* "*") (cast_expression "(int *)(param_1 + 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 4)" (( "(") (binary_expression "param_1 + 4" (identifier "param_1") (+ "+") (number_literal "4")) () ")"))))) (; ";")) (if_statement "if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {\n      FUN_0004e100();\n      return 0x106;\n    }" (if "if") (parenthesized_expression "((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0))" (( "(") (binary_expression "(*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)" (parenthesized_expression "(*(int *)(iVar1 + 0x4c) != param_1)" (( "(") (binary_expression "*(int *)(iVar1 + 0x4c) != param_1" (pointer_expression "*(int *)(iVar1 + 0x4c)" (* "*") (cast_expression "(int *)(iVar1 + 0x4c)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0x4c)" (( "(") (binary_expression "iVar1 + 0x4c" (identifier "iVar1") (+ "+") (number_literal "0x4c")) () ")")))) (!= "!=") (identifier "param_1")) () ")")) (&& "&&") (parenthesized_expression "((*(byte *)(iVar1 + 0x16) & 0x40) != 0)" (( "(") (binary_expression "(*(byte *)(iVar1 + 0x16) & 0x40) != 0" (parenthesized_expression "(*(byte *)(iVar1 + 0x16) & 0x40)" (( "(") (binary_expression "*(byte *)(iVar1 + 0x16) & 0x40" (pointer_expression "*(byte *)(iVar1 + 0x16)" (* "*") (cast_expression "(byte *)(iVar1 + 0x16)" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0x16)" (( "(") (binary_expression "iVar1 + 0x16" (identifier "iVar1") (+ "+") (number_literal "0x16")) () ")")))) (& "&") (number_literal "0x40")) () ")")) (!= "!=") (number_literal "0")) () ")"))) () ")")) (compound_statement "{\n      FUN_0004e100();\n      return 0x106;\n    }" ({ "{") (expression_statement "FUN_0004e100();" (call_expression "FUN_0004e100()" (identifier "FUN_0004e100") (argument_list "()" (( "(") () ")"))) (; ";")) (return_statement "return 0x106;" (return "return") (number_literal "0x106") (; ";")) (} "}"))) (for_statement "for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }" (for "for") (( "(") (assignment_expression "piVar2 = *(int **)(iVar1 + 0x48)" (identifier "piVar2") (= "=") (pointer_expression "*(int **)(iVar1 + 0x48)" (* "*") (cast_expression "(int **)(iVar1 + 0x48)" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(iVar1 + 0x48)" (( "(") (binary_expression "iVar1 + 0x48" (identifier "iVar1") (+ "+") (number_literal "0x48")) () ")"))))) (; ";") (binary_expression "piVar2 != (int *)0x0" (identifier "piVar2") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) (; ";") (assignment_expression "piVar2 = (int *)piVar2[3]" (identifier "piVar2") (= "=") (cast_expression "(int *)piVar2[3]" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (subscript_expression "piVar2[3]" (identifier "piVar2") ([ "[") (number_literal "3") (] "]")))) () ")") (compound_statement "{\n      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }\n    }" ({ "{") (if_statement "if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }" (if "if") (parenthesized_expression "(((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3))" (( "(") (binary_expression "((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)" (parenthesized_expression "((*piVar2 != param_1) && (piVar2[1] == param_2))" (( "(") (binary_expression "(*piVar2 != param_1) && (piVar2[1] == param_2)" (parenthesized_expression "(*piVar2 != param_1)" (( "(") (binary_expression "*piVar2 != param_1" (pointer_expression "*piVar2" (* "*") (identifier "piVar2")) (!= "!=") (identifier "param_1")) () ")")) (&& "&&") (parenthesized_expression "(piVar2[1] == param_2)" (( "(") (binary_expression "piVar2[1] == param_2" (subscript_expression "piVar2[1]" (identifier "piVar2") ([ "[") (number_literal "1") (] "]")) (== "==") (identifier "param_2")) () ")"))) () ")")) (&& "&&") (parenthesized_expression "((char)piVar2[2] != param_3)" (( "(") (binary_expression "(char)piVar2[2] != param_3" (cast_expression "(char)piVar2[2]" (( "(") (type_descriptor "char" (primitive_type "char")) () ")") (subscript_expression "piVar2[2]" (identifier "piVar2") ([ "[") (number_literal "2") (] "]"))) (!= "!=") (identifier "param_3")) () ")"))) () ")")) (compound_statement "{\n        FUN_0004e100();\n        if (param_3 != '\x02') {\n          return 0x106;\n        }\n        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;\n        return 0x106;\n      }" ({ "{") (expression_statement "FUN_0004e100();" (call_expression "FUN_0004e100()" (identifier "FUN_0004e100") (argument_list "()" (( "(") () ")"))) (; ";")) (if_statement "if (param_3 != '\x02') {\n          return 0x106;\n        }" (if "if") (parenthesized_expression "(param_3 != '\x02')" (( "(") (binary_expression "param_3 != '\x02'" (identifier "param_3") (!= "!=") (char_literal "'\x02'" (' "'") (escape_sequence "\x02") (' "'"))) () ")")) (compound_statement "{\n          return 0x106;\n        }" ({ "{") (return_statement "return 0x106;" (return "return") (number_literal "0x106") (; ";")) (} "}"))) (expression_statement "*(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;" (assignment_expression "*(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80" (pointer_expression "*(ushort *)(iVar1 + 0x16)" (* "*") (cast_expression "(ushort *)(iVar1 + 0x16)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0x16)" (( "(") (binary_expression "iVar1 + 0x16" (identifier "iVar1") (+ "+") (number_literal "0x16")) () ")")))) (= "=") (binary_expression "*(ushort *)(iVar1 + 0x16) | 0x80" (pointer_expression "*(ushort *)(iVar1 + 0x16)" (* "*") (cast_expression "(ushort *)(iVar1 + 0x16)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar1 + 0x16)" (( "(") (binary_expression "iVar1 + 0x16" (identifier "iVar1") (+ "+") (number_literal "0x16")) () ")")))) (| "|") (number_literal "0x80"))) (; ";")) (return_statement "return 0x106;" (return "return") (number_literal "0x106") (; ";")) (} "}"))) (} "}"))) (} "}"))) (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}")))

int __regparm3 function_1(type_1 *var_1,type_2 var_4,type_3 var_5)

{
  type_4 *pBVar1;
  type_5 *var_3;
  
  if (var_1->sharable != '\0') {
    pBVar1 = var_1->pBt;
    if ((pBVar1->pWriter != var_1) && ((pBVar1->btsFlags & 0x40) != 0)) {
      var_2(var_1->db,pBVar1->pWriter->db);
      return 0x106;
    }
    for (var_3 = pBVar1->pLock; var_3 != (type_5 *)0x0; var_3 = var_3->pNext) {
      if (((var_3->pBtree != var_1) && (var_3->iTable == var_4)) && (var_3->var_5 != var_5)) {
        var_2(var_1->db,var_3->pBtree->db);
        if (var_5 != '\x02') {
          return 0x106;
        }
        pBVar1->btsFlags = pBVar1->btsFlags | 0x80;
        return 0x106;
      }
    }
  }
  return 0;
}


(translation_unit (function_definition type: (type_identifier) (ERROR (identifier)) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (char_literal (escape_sequence)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) right: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) right: (number_literal))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (return_statement (number_literal)))) (for_statement initializer: (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) condition: (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal))) update: (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (subscript_expression argument: (identifier) index: (number_literal)))) body: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (identifier))) right: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))))) right: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))) right: (identifier))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (escape_sequence)))) consequence: (compound_statement (return_statement (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))) (return_statement (number_literal)))))))) (return_statement (number_literal)))))

undefined4 __regparm3 MASKED(int param_1,int param_2,char param_3)

{
  int iVar1;
  int *piVar2;
  
  if (*(char *)(param_1 + 9) != '\0') {
    iVar1 = *(int *)(param_1 + 4);
    if ((*(int *)(iVar1 + 0x4c) != param_1) && ((*(byte *)(iVar1 + 0x16) & 0x40) != 0)) {
      FUN_0004e100();
      return 0x106;
    }
    for (piVar2 = *(int **)(iVar1 + 0x48); piVar2 != (int *)0x0; piVar2 = (int *)piVar2[3]) {
      if (((*piVar2 != param_1) && (piVar2[1] == param_2)) && ((char)piVar2[2] != param_3)) {
        FUN_0004e100();
        if (param_3 != '\x02') {
          return 0x106;
        }
        *(ushort *)(iVar1 + 0x16) = *(ushort *)(iVar1 + 0x16) | 0x80;
        return 0x106;
      }
    }
  }
  return 0;
}

