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

int sqlite3_create_function_v2
              (sqlite3 *db,char *zFunc,int nArg,int enc,void *p,
              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xSFunc,
              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xStep,
              _func_void_sqlite3_context_ptr *xFinal,_func_void_void_ptr *xDestroy)

{
  FuncDestructor *pDestructor;
  uint uVar1;
  u64 in_stack_ffffffd4;
  
  sqlite3_mutex_enter(db->mutex);
  if (xDestroy == (_func_void_void_ptr *)0x0) {
    uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,
                              (_func_void_sqlite3_context_ptr *)0x0,
                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,
                              (FuncDestructor *)0x0);
LAB_00050d40:
    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {
LAB_00050da0:
      uVar1 = apiOomError(db);
      goto LAB_00050d52;
    }
  }
  else {
    if (sqlite3Config.bMemstat == 0) {
      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);
    }
    else {
      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);
    }
    if (pDestructor != (FuncDestructor *)0x0) {
      pDestructor->nRef = 0;
      pDestructor->xDestroy = xDestroy;
      pDestructor->pUserData = p;
      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,
                                (_func_void_sqlite3_context_ptr *)0x0,
                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,
                                pDestructor);
      if (pDestructor->nRef == 0) {
        (*xDestroy)(p);
        sqlite3_free(pDestructor);
      }
      goto LAB_00050d40;
    }
    uVar1._0_1_ = db->temp_store;
    uVar1._1_1_ = db->mallocFailed;
    uVar1._2_1_ = db->bBenignMalloc;
    uVar1._3_1_ = db->dfltLockMode;
    if ((uVar1 & 0xffff00) == 0) {
      sqlite3OomFault(db);
    }
    (*xDestroy)(p);
    uVar1 = 1;
    if (db->mallocFailed != '\0') goto LAB_00050da0;
  }
  uVar1 = uVar1 & db->errMask;
LAB_00050d52:
  sqlite3_mutex_leave(db->mutex);
  return uVar1;
}



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

uint sqlite3_create_function_v2
               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,
               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)

{
  int *piVar1;
  uint uVar2;
  
  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));
  if (param_9 == (code *)0x0) {
    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);
LAB_00050d40:
    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {
LAB_00050da0:
      uVar2 = FUN_0002ad10();
      goto LAB_00050d52;
    }
  }
  else {
    if (DAT_00106360 == 0) {
      piVar1 = (int *)(*DAT_00106380)(0xc);
    }
    else {
      piVar1 = (int *)FUN_000280e0();
    }
    if (piVar1 != (int *)0x0) {
      *piVar1 = 0;
      piVar1[1] = (int)param_9;
      piVar1[2] = param_5;
      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);
      if (*piVar1 == 0) {
        (*param_9)(param_5);
        sqlite3_free(piVar1);
      }
      goto LAB_00050d40;
    }
    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {
      FUN_000265f0();
    }
    (*param_9)(param_5);
    uVar2 = 1;
    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;
  }
  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);
LAB_00050d52:
  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));
  return uVar2;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
CALL 0x0001ddf0
ADD EBX,0xb5367
SUB ESP,0x28
MOV ESI,dword ptr [ESP + 0x3c]
MOV EBP,dword ptr [ESP + 0x5c]
PUSH dword ptr [ESI + 0xc]
CALL 0x000168d0
ADD ESP,0x10
TEST EBP,EBP
JZ 0x00050db0
MOV ECX,dword ptr [EBX + 0x360]
TEST ECX,ECX
JNZ 0x00050de8
SUB ESP,0xc
PUSH 0xc
CALL dword ptr [EBX + 0x380]
ADD ESP,0x10
MOV EDI,EAX
TEST EDI,EDI
JZ 0x00050d70
MOV EAX,dword ptr [ESP + 0x40]
MOV dword ptr [EDI],0x0
MOV dword ptr [EDI + 0x4],EBP
MOV dword ptr [EDI + 0x8],EAX
PUSH EDI
MOV EAX,ESI
PUSH 0x0
PUSH 0x0
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
MOV EDX,dword ptr [ESP + 0x54]
MOV ECX,dword ptr [ESP + 0x58]
CALL 0x00050620
MOV EDX,dword ptr [EDI]
ADD ESP,0x20
TEST EDX,EDX
JNZ 0x00050d40
MOV dword ptr [ESP + 0xc],EAX
SUB ESP,0xc
PUSH dword ptr [ESP + 0x4c]
CALL EBP
MOV dword ptr [ESP],EDI
CALL 0x00016d30
ADD ESP,0x10
MOV EAX,dword ptr [ESP + 0xc]
CMP byte ptr [ESI + 0x4d],0x0
JNZ 0x00050da0
CMP EAX,0xc0a
JZ 0x00050da0
AND EAX,dword ptr [ESI + 0x40]
MOV EDI,EAX
SUB ESP,0xc
PUSH dword ptr [ESI + 0xc]
CALL 0x00016830
ADD ESP,0x2c
MOV EAX,EDI
POP EBX
POP ESI
POP EDI
POP EBP
RET
TEST dword ptr [ESI + 0x4c],0xffff00
JNZ 0x00050d80
MOV EAX,ESI
CALL 0x000265f0
SUB ESP,0xc
PUSH dword ptr [ESP + 0x4c]
CALL EBP
ADD ESP,0x10
CMP byte ptr [ESI + 0x4d],0x0
MOV EAX,0x1
JZ 0x00050d4d
MOV ESI,ESI
LEA EDI,[EDI]
MOV EAX,ESI
CALL 0x0002ad10
MOV EDI,EAX
JMP 0x00050d52
PUSH 0x0
PUSH 0x0
MOV EAX,ESI
PUSH 0x0
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
PUSH dword ptr [ESP + 0x58]
MOV ECX,dword ptr [ESP + 0x58]
MOV EDX,dword ptr [ESP + 0x54]
CALL 0x00050620
ADD ESP,0x20
JMP 0x00050d40
MOV EAX,0xc
XOR EDX,EDX
CALL 0x000280e0
MOV EDI,EAX
JMP 0x00050cdb
(translation_unit "/* WARNING: Function: __i686.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n\nuint sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)\n\n{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}\n\n" comment (function_definition "uint sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)\n\n{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}" type_identifier (function_declarator "sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)" identifier (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) , (parameter_declaration "int param_5" primitive_type identifier) , (parameter_declaration "undefined4 param_6" type_identifier identifier) , (parameter_declaration "undefined4 param_7" type_identifier identifier) , (parameter_declaration "undefined4 param_8" type_identifier identifier) , (parameter_declaration "code *param_9" type_identifier (pointer_declarator "*param_9" * identifier)) ))) (compound_statement "{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));" (call_expression "sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc))" identifier (argument_list "(*(undefined4 *)(param_1 + 0xc))" ( (pointer_expression "*(undefined4 *)(param_1 + 0xc)" * (cast_expression "(undefined4 *)(param_1 + 0xc)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) ))) ;) (if_statement "if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" if (parenthesized_expression "(param_9 == (code *)0x0)" ( (binary_expression "param_9 == (code *)0x0" identifier == (cast_expression "(code *)0x0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }" { (expression_statement "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);" (assignment_expression "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0)" identifier = (call_expression "FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0)" identifier (argument_list "(param_4,param_5,param_6,param_7,param_8,0,0,0)" ( identifier , identifier , identifier , identifier , identifier , number_literal , number_literal , number_literal )))) ;) (labeled_statement "LAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" statement_identifier : (if_statement "if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" if (parenthesized_expression "((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a))" ( (binary_expression "(*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)" (parenthesized_expression "(*(char *)(param_1 + 0x4d) != '\0')" ( (binary_expression "*(char *)(param_1 + 0x4d) != '\0'" (pointer_expression "*(char *)(param_1 + 0x4d)" * (cast_expression "(char *)(param_1 + 0x4d)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x4d)" ( (binary_expression "param_1 + 0x4d" identifier + number_literal) )))) != (char_literal "'\0'" ' escape_sequence ')) )) || (parenthesized_expression "(uVar2 == 0xc0a)" ( (binary_expression "uVar2 == 0xc0a" identifier == number_literal) ))) )) (compound_statement "{\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" { (labeled_statement "LAB_00050da0:\n      uVar2 = FUN_0002ad10();" statement_identifier : (expression_statement "uVar2 = FUN_0002ad10();" (assignment_expression "uVar2 = FUN_0002ad10()" identifier = (call_expression "FUN_0002ad10()" identifier (argument_list "()" ( )))) ;)) (goto_statement "goto LAB_00050d52;" goto statement_identifier ;) }))) }) (else_clause "else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" else (compound_statement "{\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" { (if_statement "if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }" if (parenthesized_expression "(DAT_00106360 == 0)" ( (binary_expression "DAT_00106360 == 0" identifier == number_literal) )) (compound_statement "{\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }" { (expression_statement "piVar1 = (int *)(*DAT_00106380)(0xc);" (assignment_expression "piVar1 = (int *)(*DAT_00106380)(0xc)" identifier = (cast_expression "(int *)(*DAT_00106380)(0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*DAT_00106380)(0xc)" (parenthesized_expression "(*DAT_00106380)" ( (pointer_expression "*DAT_00106380" * identifier) )) (argument_list "(0xc)" ( number_literal ))))) ;) }) (else_clause "else {\n      piVar1 = (int *)FUN_000280e0();\n    }" else (compound_statement "{\n      piVar1 = (int *)FUN_000280e0();\n    }" { (expression_statement "piVar1 = (int *)FUN_000280e0();" (assignment_expression "piVar1 = (int *)FUN_000280e0()" identifier = (cast_expression "(int *)FUN_000280e0()" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_000280e0()" identifier (argument_list "()" ( ))))) ;) }))) (if_statement "if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }" if (parenthesized_expression "(piVar1 != (int *)0x0)" ( (binary_expression "piVar1 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }" { (expression_statement "*piVar1 = 0;" (assignment_expression "*piVar1 = 0" (pointer_expression "*piVar1" * identifier) = number_literal) ;) (expression_statement "piVar1[1] = (int)param_9;" (assignment_expression "piVar1[1] = (int)param_9" (subscript_expression "piVar1[1]" identifier [ number_literal ]) = (cast_expression "(int)param_9" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "piVar1[2] = param_5;" (assignment_expression "piVar1[2] = param_5" (subscript_expression "piVar1[2]" identifier [ number_literal ]) = identifier) ;) (expression_statement "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);" (assignment_expression "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" identifier = (call_expression "FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" identifier (argument_list "(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" ( identifier , identifier , identifier , identifier , identifier , number_literal , number_literal , identifier )))) ;) (if_statement "if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }" if (parenthesized_expression "(*piVar1 == 0)" ( (binary_expression "*piVar1 == 0" (pointer_expression "*piVar1" * identifier) == number_literal) )) (compound_statement "{\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }" { (expression_statement "(*param_9)(param_5);" (call_expression "(*param_9)(param_5)" (parenthesized_expression "(*param_9)" ( (pointer_expression "*param_9" * identifier) )) (argument_list "(param_5)" ( identifier ))) ;) (expression_statement "sqlite3_free(piVar1);" (call_expression "sqlite3_free(piVar1)" identifier (argument_list "(piVar1)" ( identifier ))) ;) })) (goto_statement "goto LAB_00050d40;" goto statement_identifier ;) })) (if_statement "if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }" if (parenthesized_expression "((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0)" ( (binary_expression "(*(uint *)(param_1 + 0x4c) & 0xffff00) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0x4c) & 0xffff00)" ( (binary_expression "*(uint *)(param_1 + 0x4c) & 0xffff00" (pointer_expression "*(uint *)(param_1 + 0x4c)" * (cast_expression "(uint *)(param_1 + 0x4c)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x4c)" ( (binary_expression "param_1 + 0x4c" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n      FUN_000265f0();\n    }" { (expression_statement "FUN_000265f0();" (call_expression "FUN_000265f0()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "(*param_9)(param_5);" (call_expression "(*param_9)(param_5)" (parenthesized_expression "(*param_9)" ( (pointer_expression "*param_9" * identifier) )) (argument_list "(param_5)" ( identifier ))) ;) (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" identifier = number_literal) ;) (if_statement "if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;" if (parenthesized_expression "(*(char *)(param_1 + 0x4d) != '\0')" ( (binary_expression "*(char *)(param_1 + 0x4d) != '\0'" (pointer_expression "*(char *)(param_1 + 0x4d)" * (cast_expression "(char *)(param_1 + 0x4d)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x4d)" ( (binary_expression "param_1 + 0x4d" identifier + number_literal) )))) != (char_literal "'\0'" ' escape_sequence ')) )) (goto_statement "goto LAB_00050da0;" goto statement_identifier ;)) }))) (expression_statement "uVar2 = uVar2 & *(uint *)(param_1 + 0x40);" (assignment_expression "uVar2 = uVar2 & *(uint *)(param_1 + 0x40)" identifier = (binary_expression "uVar2 & *(uint *)(param_1 + 0x40)" identifier & (pointer_expression "*(uint *)(param_1 + 0x40)" * (cast_expression "(uint *)(param_1 + 0x40)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x40)" ( (binary_expression "param_1 + 0x40" identifier + number_literal) )))))) ;) (labeled_statement "LAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));" statement_identifier : (expression_statement "sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));" (call_expression "sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc))" identifier (argument_list "(*(undefined4 *)(param_1 + 0xc))" ( (pointer_expression "*(undefined4 *)(param_1 + 0xc)" * (cast_expression "(undefined4 *)(param_1 + 0xc)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) ))) ;)) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit "/* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */\n/* WARNING: Unknown calling convention */\n\nint sqlite3_create_function_v2\n              (sqlite3 *db,char *zFunc,int nArg,int enc,void *p,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xSFunc,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xStep,\n              _func_void_sqlite3_context_ptr *xFinal,_func_void_void_ptr *xDestroy)\n\n{\n  FuncDestructor *pDestructor;\n  uint uVar1;\n  u64 in_stack_ffffffd4;\n  \n  sqlite3_mutex_enter(db->mutex);\n  if (xDestroy == (_func_void_void_ptr *)0x0) {\n    uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0);\nLAB_00050d40:\n    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }\n    if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }\n    uVar1._0_1_ = db->temp_store;\n    uVar1._1_1_ = db->mallocFailed;\n    uVar1._2_1_ = db->bBenignMalloc;\n    uVar1._3_1_ = db->dfltLockMode;\n    if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }\n    (*xDestroy)(p);\n    uVar1 = 1;\n    if (db->mallocFailed != '\0') goto LAB_00050da0;\n  }\n  uVar1 = uVar1 & db->errMask;\nLAB_00050d52:\n  sqlite3_mutex_leave(db->mutex);\n  return uVar1;\n}\n\n" comment comment (function_definition "int sqlite3_create_function_v2\n              (sqlite3 *db,char *zFunc,int nArg,int enc,void *p,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xSFunc,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xStep,\n              _func_void_sqlite3_context_ptr *xFinal,_func_void_void_ptr *xDestroy)\n\n{\n  FuncDestructor *pDestructor;\n  uint uVar1;\n  u64 in_stack_ffffffd4;\n  \n  sqlite3_mutex_enter(db->mutex);\n  if (xDestroy == (_func_void_void_ptr *)0x0) {\n    uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0);\nLAB_00050d40:\n    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }\n    if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }\n    uVar1._0_1_ = db->temp_store;\n    uVar1._1_1_ = db->mallocFailed;\n    uVar1._2_1_ = db->bBenignMalloc;\n    uVar1._3_1_ = db->dfltLockMode;\n    if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }\n    (*xDestroy)(p);\n    uVar1 = 1;\n    if (db->mallocFailed != '\0') goto LAB_00050da0;\n  }\n  uVar1 = uVar1 & db->errMask;\nLAB_00050d52:\n  sqlite3_mutex_leave(db->mutex);\n  return uVar1;\n}" primitive_type (function_declarator "sqlite3_create_function_v2\n              (sqlite3 *db,char *zFunc,int nArg,int enc,void *p,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xSFunc,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xStep,\n              _func_void_sqlite3_context_ptr *xFinal,_func_void_void_ptr *xDestroy)" identifier (parameter_list "(sqlite3 *db,char *zFunc,int nArg,int enc,void *p,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xSFunc,\n              _func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xStep,\n              _func_void_sqlite3_context_ptr *xFinal,_func_void_void_ptr *xDestroy)" ( (parameter_declaration "sqlite3 *db" type_identifier (pointer_declarator "*db" * identifier)) , (parameter_declaration "char *zFunc" primitive_type (pointer_declarator "*zFunc" * identifier)) , (parameter_declaration "int nArg" primitive_type identifier) , (parameter_declaration "int enc" primitive_type identifier) , (parameter_declaration "void *p" primitive_type (pointer_declarator "*p" * identifier)) , (parameter_declaration "_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xSFunc" type_identifier (pointer_declarator "*xSFunc" * identifier)) , (parameter_declaration "_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *xStep" type_identifier (pointer_declarator "*xStep" * identifier)) , (parameter_declaration "_func_void_sqlite3_context_ptr *xFinal" type_identifier (pointer_declarator "*xFinal" * identifier)) , (parameter_declaration "_func_void_void_ptr *xDestroy" type_identifier (pointer_declarator "*xDestroy" * identifier)) ))) (compound_statement "{\n  FuncDestructor *pDestructor;\n  uint uVar1;\n  u64 in_stack_ffffffd4;\n  \n  sqlite3_mutex_enter(db->mutex);\n  if (xDestroy == (_func_void_void_ptr *)0x0) {\n    uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0);\nLAB_00050d40:\n    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }\n    if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }\n    uVar1._0_1_ = db->temp_store;\n    uVar1._1_1_ = db->mallocFailed;\n    uVar1._2_1_ = db->bBenignMalloc;\n    uVar1._3_1_ = db->dfltLockMode;\n    if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }\n    (*xDestroy)(p);\n    uVar1 = 1;\n    if (db->mallocFailed != '\0') goto LAB_00050da0;\n  }\n  uVar1 = uVar1 & db->errMask;\nLAB_00050d52:\n  sqlite3_mutex_leave(db->mutex);\n  return uVar1;\n}" { (declaration "FuncDestructor *pDestructor;" type_identifier (pointer_declarator "*pDestructor" * identifier) ;) (declaration "uint uVar1;" type_identifier identifier ;) (declaration "u64 in_stack_ffffffd4;" type_identifier identifier ;) (expression_statement "sqlite3_mutex_enter(db->mutex);" (call_expression "sqlite3_mutex_enter(db->mutex)" identifier (argument_list "(db->mutex)" ( (field_expression "db->mutex" identifier -> field_identifier) ))) ;) (if_statement "if (xDestroy == (_func_void_void_ptr *)0x0) {\n    uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0);\nLAB_00050d40:\n    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }\n    if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }\n    uVar1._0_1_ = db->temp_store;\n    uVar1._1_1_ = db->mallocFailed;\n    uVar1._2_1_ = db->bBenignMalloc;\n    uVar1._3_1_ = db->dfltLockMode;\n    if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }\n    (*xDestroy)(p);\n    uVar1 = 1;\n    if (db->mallocFailed != '\0') goto LAB_00050da0;\n  }" if (parenthesized_expression "(xDestroy == (_func_void_void_ptr *)0x0)" ( (binary_expression "xDestroy == (_func_void_void_ptr *)0x0" identifier == (cast_expression "(_func_void_void_ptr *)0x0" ( (type_descriptor "_func_void_void_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0);\nLAB_00050d40:\n    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }\n  }" { (expression_statement "uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0);" (assignment_expression "uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0)" identifier = (call_expression "sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0)" identifier (argument_list "(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                              (_func_void_sqlite3_context_ptr *)0x0,\n                              (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                              (FuncDestructor *)0x0)" ( identifier , identifier , identifier , identifier , identifier , identifier , identifier , identifier , (cast_expression "(_func_void_sqlite3_context_ptr *)0x0" ( (type_descriptor "_func_void_sqlite3_context_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) , (cast_expression "(_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0" ( (type_descriptor "_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) , (cast_expression "(FuncDestructor *)0x0" ( (type_descriptor "FuncDestructor *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) )))) ;) (labeled_statement "LAB_00050d40:\n    if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }" statement_identifier : (if_statement "if ((db->mallocFailed != '\0') || (uVar1 == 0xc0a)) {\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }" if (parenthesized_expression "((db->mallocFailed != '\0') || (uVar1 == 0xc0a))" ( (binary_expression "(db->mallocFailed != '\0') || (uVar1 == 0xc0a)" (parenthesized_expression "(db->mallocFailed != '\0')" ( (binary_expression "db->mallocFailed != '\0'" (field_expression "db->mallocFailed" identifier -> field_identifier) != (char_literal "'\0'" ' escape_sequence ')) )) || (parenthesized_expression "(uVar1 == 0xc0a)" ( (binary_expression "uVar1 == 0xc0a" identifier == number_literal) ))) )) (compound_statement "{\nLAB_00050da0:\n      uVar1 = apiOomError(db);\n      goto LAB_00050d52;\n    }" { (labeled_statement "LAB_00050da0:\n      uVar1 = apiOomError(db);" statement_identifier : (expression_statement "uVar1 = apiOomError(db);" (assignment_expression "uVar1 = apiOomError(db)" identifier = (call_expression "apiOomError(db)" identifier (argument_list "(db)" ( identifier )))) ;)) (goto_statement "goto LAB_00050d52;" goto statement_identifier ;) }))) }) (else_clause "else {\n    if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }\n    if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }\n    uVar1._0_1_ = db->temp_store;\n    uVar1._1_1_ = db->mallocFailed;\n    uVar1._2_1_ = db->bBenignMalloc;\n    uVar1._3_1_ = db->dfltLockMode;\n    if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }\n    (*xDestroy)(p);\n    uVar1 = 1;\n    if (db->mallocFailed != '\0') goto LAB_00050da0;\n  }" else (compound_statement "{\n    if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }\n    if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }\n    uVar1._0_1_ = db->temp_store;\n    uVar1._1_1_ = db->mallocFailed;\n    uVar1._2_1_ = db->bBenignMalloc;\n    uVar1._3_1_ = db->dfltLockMode;\n    if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }\n    (*xDestroy)(p);\n    uVar1 = 1;\n    if (db->mallocFailed != '\0') goto LAB_00050da0;\n  }" { (if_statement "if (sqlite3Config.bMemstat == 0) {\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }\n    else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }" if (parenthesized_expression "(sqlite3Config.bMemstat == 0)" ( (binary_expression "sqlite3Config.bMemstat == 0" (field_expression "sqlite3Config.bMemstat" identifier . field_identifier) == number_literal) )) (compound_statement "{\n      pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);\n    }" { (expression_statement "pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc);" (assignment_expression "pDestructor = (FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc)" identifier = (cast_expression "(FuncDestructor *)(*sqlite3Config.m.xMalloc)(0xc)" ( (type_descriptor "FuncDestructor *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "(*sqlite3Config.m.xMalloc)(0xc)" (parenthesized_expression "(*sqlite3Config.m.xMalloc)" ( (pointer_expression "*sqlite3Config.m.xMalloc" * (field_expression "sqlite3Config.m.xMalloc" (field_expression "sqlite3Config.m" identifier . field_identifier) . field_identifier)) )) (argument_list "(0xc)" ( number_literal ))))) ;) }) (else_clause "else {\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }" else (compound_statement "{\n      pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);\n    }" { (expression_statement "pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4);" (assignment_expression "pDestructor = (FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4)" identifier = (cast_expression "(FuncDestructor *)sqlite3Malloc(in_stack_ffffffd4)" ( (type_descriptor "FuncDestructor *" type_identifier (abstract_pointer_declarator "*" *)) ) (call_expression "sqlite3Malloc(in_stack_ffffffd4)" identifier (argument_list "(in_stack_ffffffd4)" ( identifier ))))) ;) }))) (if_statement "if (pDestructor != (FuncDestructor *)0x0) {\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }" if (parenthesized_expression "(pDestructor != (FuncDestructor *)0x0)" ( (binary_expression "pDestructor != (FuncDestructor *)0x0" identifier != (cast_expression "(FuncDestructor *)0x0" ( (type_descriptor "FuncDestructor *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      pDestructor->nRef = 0;\n      pDestructor->xDestroy = xDestroy;\n      pDestructor->pUserData = p;\n      uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);\n      if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }\n      goto LAB_00050d40;\n    }" { (expression_statement "pDestructor->nRef = 0;" (assignment_expression "pDestructor->nRef = 0" (field_expression "pDestructor->nRef" identifier -> field_identifier) = number_literal) ;) (expression_statement "pDestructor->xDestroy = xDestroy;" (assignment_expression "pDestructor->xDestroy = xDestroy" (field_expression "pDestructor->xDestroy" identifier -> field_identifier) = identifier) ;) (expression_statement "pDestructor->pUserData = p;" (assignment_expression "pDestructor->pUserData = p" (field_expression "pDestructor->pUserData" identifier -> field_identifier) = identifier) ;) (expression_statement "uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor);" (assignment_expression "uVar1 = sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor)" identifier = (call_expression "sqlite3CreateFunc(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor)" identifier (argument_list "(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,\n                                (_func_void_sqlite3_context_ptr *)0x0,\n                                (_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0,\n                                pDestructor)" ( identifier , identifier , identifier , identifier , identifier , identifier , identifier , identifier , (cast_expression "(_func_void_sqlite3_context_ptr *)0x0" ( (type_descriptor "_func_void_sqlite3_context_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) , (cast_expression "(_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *)0x0" ( (type_descriptor "_func_void_sqlite3_context_ptr_int_sqlite3_value_ptr_ptr *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) , identifier )))) ;) (if_statement "if (pDestructor->nRef == 0) {\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }" if (parenthesized_expression "(pDestructor->nRef == 0)" ( (binary_expression "pDestructor->nRef == 0" (field_expression "pDestructor->nRef" identifier -> field_identifier) == number_literal) )) (compound_statement "{\n        (*xDestroy)(p);\n        sqlite3_free(pDestructor);\n      }" { (expression_statement "(*xDestroy)(p);" (call_expression "(*xDestroy)(p)" (parenthesized_expression "(*xDestroy)" ( (pointer_expression "*xDestroy" * identifier) )) (argument_list "(p)" ( identifier ))) ;) (expression_statement "sqlite3_free(pDestructor);" (call_expression "sqlite3_free(pDestructor)" identifier (argument_list "(pDestructor)" ( identifier ))) ;) })) (goto_statement "goto LAB_00050d40;" goto statement_identifier ;) })) (expression_statement "uVar1._0_1_ = db->temp_store;" (assignment_expression "uVar1._0_1_ = db->temp_store" (field_expression "uVar1._0_1_" identifier . field_identifier) = (field_expression "db->temp_store" identifier -> field_identifier)) ;) (expression_statement "uVar1._1_1_ = db->mallocFailed;" (assignment_expression "uVar1._1_1_ = db->mallocFailed" (field_expression "uVar1._1_1_" identifier . field_identifier) = (field_expression "db->mallocFailed" identifier -> field_identifier)) ;) (expression_statement "uVar1._2_1_ = db->bBenignMalloc;" (assignment_expression "uVar1._2_1_ = db->bBenignMalloc" (field_expression "uVar1._2_1_" identifier . field_identifier) = (field_expression "db->bBenignMalloc" identifier -> field_identifier)) ;) (expression_statement "uVar1._3_1_ = db->dfltLockMode;" (assignment_expression "uVar1._3_1_ = db->dfltLockMode" (field_expression "uVar1._3_1_" identifier . field_identifier) = (field_expression "db->dfltLockMode" identifier -> field_identifier)) ;) (if_statement "if ((uVar1 & 0xffff00) == 0) {\n      sqlite3OomFault(db);\n    }" if (parenthesized_expression "((uVar1 & 0xffff00) == 0)" ( (binary_expression "(uVar1 & 0xffff00) == 0" (parenthesized_expression "(uVar1 & 0xffff00)" ( (binary_expression "uVar1 & 0xffff00" identifier & number_literal) )) == number_literal) )) (compound_statement "{\n      sqlite3OomFault(db);\n    }" { (expression_statement "sqlite3OomFault(db);" (call_expression "sqlite3OomFault(db)" identifier (argument_list "(db)" ( identifier ))) ;) })) (expression_statement "(*xDestroy)(p);" (call_expression "(*xDestroy)(p)" (parenthesized_expression "(*xDestroy)" ( (pointer_expression "*xDestroy" * identifier) )) (argument_list "(p)" ( identifier ))) ;) (expression_statement "uVar1 = 1;" (assignment_expression "uVar1 = 1" identifier = number_literal) ;) (if_statement "if (db->mallocFailed != '\0') goto LAB_00050da0;" if (parenthesized_expression "(db->mallocFailed != '\0')" ( (binary_expression "db->mallocFailed != '\0'" (field_expression "db->mallocFailed" identifier -> field_identifier) != (char_literal "'\0'" ' escape_sequence ')) )) (goto_statement "goto LAB_00050da0;" goto statement_identifier ;)) }))) (expression_statement "uVar1 = uVar1 & db->errMask;" (assignment_expression "uVar1 = uVar1 & db->errMask" identifier = (binary_expression "uVar1 & db->errMask" identifier & (field_expression "db->errMask" identifier -> field_identifier))) ;) (labeled_statement "LAB_00050d52:\n  sqlite3_mutex_leave(db->mutex);" statement_identifier : (expression_statement "sqlite3_mutex_leave(db->mutex);" (call_expression "sqlite3_mutex_leave(db->mutex)" identifier (argument_list "(db->mutex)" ( (field_expression "db->mutex" identifier -> field_identifier) ))) ;)) (return_statement "return uVar1;" return identifier ;) })))
(translation_unit "uint sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)\n\n{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}\n\n" (function_definition "uint sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)\n\n{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}" type_identifier (function_declarator "sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)" identifier (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "undefined4 param_2" type_identifier identifier) , (parameter_declaration "undefined4 param_3" type_identifier identifier) , (parameter_declaration "undefined4 param_4" type_identifier identifier) , (parameter_declaration "int param_5" primitive_type identifier) , (parameter_declaration "undefined4 param_6" type_identifier identifier) , (parameter_declaration "undefined4 param_7" type_identifier identifier) , (parameter_declaration "undefined4 param_8" type_identifier identifier) , (parameter_declaration "code *param_9" type_identifier (pointer_declarator "*param_9" * identifier)) ))) (compound_statement "{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}" { (declaration "int *piVar1;" primitive_type (pointer_declarator "*piVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (expression_statement "sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));" (call_expression "sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc))" identifier (argument_list "(*(undefined4 *)(param_1 + 0xc))" ( (pointer_expression "*(undefined4 *)(param_1 + 0xc)" * (cast_expression "(undefined4 *)(param_1 + 0xc)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) ))) ;) (if_statement "if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" if (parenthesized_expression "(param_9 == (code *)0x0)" ( (binary_expression "param_9 == (code *)0x0" identifier == (cast_expression "(code *)0x0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }" { (expression_statement "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);" (assignment_expression "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0)" identifier = (call_expression "FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0)" identifier (argument_list "(param_4,param_5,param_6,param_7,param_8,0,0,0)" ( identifier , identifier , identifier , identifier , identifier , number_literal , number_literal , number_literal )))) ;) (labeled_statement "LAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" statement_identifier : (if_statement "if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" if (parenthesized_expression "((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a))" ( (binary_expression "(*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)" (parenthesized_expression "(*(char *)(param_1 + 0x4d) != '\0')" ( (binary_expression "*(char *)(param_1 + 0x4d) != '\0'" (pointer_expression "*(char *)(param_1 + 0x4d)" * (cast_expression "(char *)(param_1 + 0x4d)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x4d)" ( (binary_expression "param_1 + 0x4d" identifier + number_literal) )))) != (char_literal "'\0'" ' escape_sequence ')) )) || (parenthesized_expression "(uVar2 == 0xc0a)" ( (binary_expression "uVar2 == 0xc0a" identifier == number_literal) ))) )) (compound_statement "{\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" { (labeled_statement "LAB_00050da0:\n      uVar2 = FUN_0002ad10();" statement_identifier : (expression_statement "uVar2 = FUN_0002ad10();" (assignment_expression "uVar2 = FUN_0002ad10()" identifier = (call_expression "FUN_0002ad10()" identifier (argument_list "()" ( )))) ;)) (goto_statement "goto LAB_00050d52;" goto statement_identifier ;) }))) }) (else_clause "else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" else (compound_statement "{\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" { (if_statement "if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }" if (parenthesized_expression "(DAT_00106360 == 0)" ( (binary_expression "DAT_00106360 == 0" identifier == number_literal) )) (compound_statement "{\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }" { (expression_statement "piVar1 = (int *)(*DAT_00106380)(0xc);" (assignment_expression "piVar1 = (int *)(*DAT_00106380)(0xc)" identifier = (cast_expression "(int *)(*DAT_00106380)(0xc)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "(*DAT_00106380)(0xc)" (parenthesized_expression "(*DAT_00106380)" ( (pointer_expression "*DAT_00106380" * identifier) )) (argument_list "(0xc)" ( number_literal ))))) ;) }) (else_clause "else {\n      piVar1 = (int *)FUN_000280e0();\n    }" else (compound_statement "{\n      piVar1 = (int *)FUN_000280e0();\n    }" { (expression_statement "piVar1 = (int *)FUN_000280e0();" (assignment_expression "piVar1 = (int *)FUN_000280e0()" identifier = (cast_expression "(int *)FUN_000280e0()" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_000280e0()" identifier (argument_list "()" ( ))))) ;) }))) (if_statement "if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }" if (parenthesized_expression "(piVar1 != (int *)0x0)" ( (binary_expression "piVar1 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }" { (expression_statement "*piVar1 = 0;" (assignment_expression "*piVar1 = 0" (pointer_expression "*piVar1" * identifier) = number_literal) ;) (expression_statement "piVar1[1] = (int)param_9;" (assignment_expression "piVar1[1] = (int)param_9" (subscript_expression "piVar1[1]" identifier [ number_literal ]) = (cast_expression "(int)param_9" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "piVar1[2] = param_5;" (assignment_expression "piVar1[2] = param_5" (subscript_expression "piVar1[2]" identifier [ number_literal ]) = identifier) ;) (expression_statement "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);" (assignment_expression "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" identifier = (call_expression "FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" identifier (argument_list "(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" ( identifier , identifier , identifier , identifier , identifier , number_literal , number_literal , identifier )))) ;) (if_statement "if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }" if (parenthesized_expression "(*piVar1 == 0)" ( (binary_expression "*piVar1 == 0" (pointer_expression "*piVar1" * identifier) == number_literal) )) (compound_statement "{\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }" { (expression_statement "(*param_9)(param_5);" (call_expression "(*param_9)(param_5)" (parenthesized_expression "(*param_9)" ( (pointer_expression "*param_9" * identifier) )) (argument_list "(param_5)" ( identifier ))) ;) (expression_statement "sqlite3_free(piVar1);" (call_expression "sqlite3_free(piVar1)" identifier (argument_list "(piVar1)" ( identifier ))) ;) })) (goto_statement "goto LAB_00050d40;" goto statement_identifier ;) })) (if_statement "if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }" if (parenthesized_expression "((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0)" ( (binary_expression "(*(uint *)(param_1 + 0x4c) & 0xffff00) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0x4c) & 0xffff00)" ( (binary_expression "*(uint *)(param_1 + 0x4c) & 0xffff00" (pointer_expression "*(uint *)(param_1 + 0x4c)" * (cast_expression "(uint *)(param_1 + 0x4c)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x4c)" ( (binary_expression "param_1 + 0x4c" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n      FUN_000265f0();\n    }" { (expression_statement "FUN_000265f0();" (call_expression "FUN_000265f0()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "(*param_9)(param_5);" (call_expression "(*param_9)(param_5)" (parenthesized_expression "(*param_9)" ( (pointer_expression "*param_9" * identifier) )) (argument_list "(param_5)" ( identifier ))) ;) (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" identifier = number_literal) ;) (if_statement "if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;" if (parenthesized_expression "(*(char *)(param_1 + 0x4d) != '\0')" ( (binary_expression "*(char *)(param_1 + 0x4d) != '\0'" (pointer_expression "*(char *)(param_1 + 0x4d)" * (cast_expression "(char *)(param_1 + 0x4d)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x4d)" ( (binary_expression "param_1 + 0x4d" identifier + number_literal) )))) != (char_literal "'\0'" ' escape_sequence ')) )) (goto_statement "goto LAB_00050da0;" goto statement_identifier ;)) }))) (expression_statement "uVar2 = uVar2 & *(uint *)(param_1 + 0x40);" (assignment_expression "uVar2 = uVar2 & *(uint *)(param_1 + 0x40)" identifier = (binary_expression "uVar2 & *(uint *)(param_1 + 0x40)" identifier & (pointer_expression "*(uint *)(param_1 + 0x40)" * (cast_expression "(uint *)(param_1 + 0x40)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x40)" ( (binary_expression "param_1 + 0x40" identifier + number_literal) )))))) ;) (labeled_statement "LAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));" statement_identifier : (expression_statement "sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));" (call_expression "sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc))" identifier (argument_list "(*(undefined4 *)(param_1 + 0xc))" ( (pointer_expression "*(undefined4 *)(param_1 + 0xc)" * (cast_expression "(undefined4 *)(param_1 + 0xc)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) )))) ))) ;)) (return_statement "return uVar2;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (if_statement if (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 ( IDENT , IDENT , IDENT , IDENT , IDENT , LIT , LIT , LIT )))) ;) (labeled_statement statement_identifier : (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) )))) != (char_literal ' escape_sequence ')) )) || (parenthesized_expression ( (binary_expression IDENT == LIT) ))) )) (compound_statement { (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;)) (goto_statement goto statement_identifier ;) }))) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( LIT ))))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (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 (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT , IDENT , IDENT , LIT , LIT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT ))) ;) (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;) })) (goto_statement goto statement_identifier ;) })) (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) )))) & LIT) )) == LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (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 ')) )) (goto_statement goto statement_identifier ;)) }))) (expression_statement (assignment_expression IDENT = (binary_expression IDENT & (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))))) ;) (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;)) (return_statement return IDENT ;) })))
(function_definition "uint sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)\n\n{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}" (type_identifier "uint") (function_declarator "sqlite3_create_function_v2\n               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)" (identifier "sqlite3_create_function_v2") (parameter_list "(int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,\n               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "undefined4 param_2" (type_identifier "undefined4") (identifier "param_2")) (, ",") (parameter_declaration "undefined4 param_3" (type_identifier "undefined4") (identifier "param_3")) (, ",") (parameter_declaration "undefined4 param_4" (type_identifier "undefined4") (identifier "param_4")) (, ",") (parameter_declaration "int param_5" (primitive_type "int") (identifier "param_5")) (, ",") (parameter_declaration "undefined4 param_6" (type_identifier "undefined4") (identifier "param_6")) (, ",") (parameter_declaration "undefined4 param_7" (type_identifier "undefined4") (identifier "param_7")) (, ",") (parameter_declaration "undefined4 param_8" (type_identifier "undefined4") (identifier "param_8")) (, ",") (parameter_declaration "code *param_9" (type_identifier "code") (pointer_declarator "*param_9" (* "*") (identifier "param_9"))) () ")"))) (compound_statement "{\n  int *piVar1;\n  uint uVar2;\n  \n  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));\n  if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }\n  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);\nLAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));\n  return uVar2;\n}" ({ "{") (declaration "int *piVar1;" (primitive_type "int") (pointer_declarator "*piVar1" (* "*") (identifier "piVar1")) (; ";")) (declaration "uint uVar2;" (type_identifier "uint") (identifier "uVar2") (; ";")) (expression_statement "sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));" (call_expression "sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc))" (identifier "sqlite3_mutex_enter") (argument_list "(*(undefined4 *)(param_1 + 0xc))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0xc)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0xc)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) () ")"))) (; ";")) (if_statement "if (param_9 == (code *)0x0) {\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }\n  else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" (if "if") (parenthesized_expression "(param_9 == (code *)0x0)" (( "(") (binary_expression "param_9 == (code *)0x0" (identifier "param_9") (== "==") (cast_expression "(code *)0x0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);\nLAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }\n  }" ({ "{") (expression_statement "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);" (assignment_expression "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0)" (identifier "uVar2") (= "=") (call_expression "FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0)" (identifier "FUN_00050620") (argument_list "(param_4,param_5,param_6,param_7,param_8,0,0,0)" (( "(") (identifier "param_4") (, ",") (identifier "param_5") (, ",") (identifier "param_6") (, ",") (identifier "param_7") (, ",") (identifier "param_8") (, ",") (number_literal "0") (, ",") (number_literal "0") (, ",") (number_literal "0") () ")")))) (; ";")) (labeled_statement "LAB_00050d40:\n    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" (statement_identifier "LAB_00050d40") (: ":") (if_statement "if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" (if "if") (parenthesized_expression "((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a))" (( "(") (binary_expression "(*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)" (parenthesized_expression "(*(char *)(param_1 + 0x4d) != '\0')" (( "(") (binary_expression "*(char *)(param_1 + 0x4d) != '\0'" (pointer_expression "*(char *)(param_1 + 0x4d)" (* "*") (cast_expression "(char *)(param_1 + 0x4d)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x4d)" (( "(") (binary_expression "param_1 + 0x4d" (identifier "param_1") (+ "+") (number_literal "0x4d")) () ")")))) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (|| "||") (parenthesized_expression "(uVar2 == 0xc0a)" (( "(") (binary_expression "uVar2 == 0xc0a" (identifier "uVar2") (== "==") (number_literal "0xc0a")) () ")"))) () ")")) (compound_statement "{\nLAB_00050da0:\n      uVar2 = FUN_0002ad10();\n      goto LAB_00050d52;\n    }" ({ "{") (labeled_statement "LAB_00050da0:\n      uVar2 = FUN_0002ad10();" (statement_identifier "LAB_00050da0") (: ":") (expression_statement "uVar2 = FUN_0002ad10();" (assignment_expression "uVar2 = FUN_0002ad10()" (identifier "uVar2") (= "=") (call_expression "FUN_0002ad10()" (identifier "FUN_0002ad10") (argument_list "()" (( "(") () ")")))) (; ";"))) (goto_statement "goto LAB_00050d52;" (goto "goto") (statement_identifier "LAB_00050d52") (; ";")) (} "}")))) (} "}")) (else_clause "else {\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" (else "else") (compound_statement "{\n    if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }\n    if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }\n    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }\n    (*param_9)(param_5);\n    uVar2 = 1;\n    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;\n  }" ({ "{") (if_statement "if (DAT_00106360 == 0) {\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }\n    else {\n      piVar1 = (int *)FUN_000280e0();\n    }" (if "if") (parenthesized_expression "(DAT_00106360 == 0)" (( "(") (binary_expression "DAT_00106360 == 0" (identifier "DAT_00106360") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      piVar1 = (int *)(*DAT_00106380)(0xc);\n    }" ({ "{") (expression_statement "piVar1 = (int *)(*DAT_00106380)(0xc);" (assignment_expression "piVar1 = (int *)(*DAT_00106380)(0xc)" (identifier "piVar1") (= "=") (cast_expression "(int *)(*DAT_00106380)(0xc)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "(*DAT_00106380)(0xc)" (parenthesized_expression "(*DAT_00106380)" (( "(") (pointer_expression "*DAT_00106380" (* "*") (identifier "DAT_00106380")) () ")")) (argument_list "(0xc)" (( "(") (number_literal "0xc") () ")"))))) (; ";")) (} "}")) (else_clause "else {\n      piVar1 = (int *)FUN_000280e0();\n    }" (else "else") (compound_statement "{\n      piVar1 = (int *)FUN_000280e0();\n    }" ({ "{") (expression_statement "piVar1 = (int *)FUN_000280e0();" (assignment_expression "piVar1 = (int *)FUN_000280e0()" (identifier "piVar1") (= "=") (cast_expression "(int *)FUN_000280e0()" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_000280e0()" (identifier "FUN_000280e0") (argument_list "()" (( "(") () ")"))))) (; ";")) (} "}")))) (if_statement "if (piVar1 != (int *)0x0) {\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }" (if "if") (parenthesized_expression "(piVar1 != (int *)0x0)" (( "(") (binary_expression "piVar1 != (int *)0x0" (identifier "piVar1") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n      *piVar1 = 0;\n      piVar1[1] = (int)param_9;\n      piVar1[2] = param_5;\n      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);\n      if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }\n      goto LAB_00050d40;\n    }" ({ "{") (expression_statement "*piVar1 = 0;" (assignment_expression "*piVar1 = 0" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (= "=") (number_literal "0")) (; ";")) (expression_statement "piVar1[1] = (int)param_9;" (assignment_expression "piVar1[1] = (int)param_9" (subscript_expression "piVar1[1]" (identifier "piVar1") ([ "[") (number_literal "1") (] "]")) (= "=") (cast_expression "(int)param_9" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "param_9"))) (; ";")) (expression_statement "piVar1[2] = param_5;" (assignment_expression "piVar1[2] = param_5" (subscript_expression "piVar1[2]" (identifier "piVar1") ([ "[") (number_literal "2") (] "]")) (= "=") (identifier "param_5")) (; ";")) (expression_statement "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);" (assignment_expression "uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" (identifier "uVar2") (= "=") (call_expression "FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" (identifier "FUN_00050620") (argument_list "(param_4,param_5,param_6,param_7,param_8,0,0,piVar1)" (( "(") (identifier "param_4") (, ",") (identifier "param_5") (, ",") (identifier "param_6") (, ",") (identifier "param_7") (, ",") (identifier "param_8") (, ",") (number_literal "0") (, ",") (number_literal "0") (, ",") (identifier "piVar1") () ")")))) (; ";")) (if_statement "if (*piVar1 == 0) {\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }" (if "if") (parenthesized_expression "(*piVar1 == 0)" (( "(") (binary_expression "*piVar1 == 0" (pointer_expression "*piVar1" (* "*") (identifier "piVar1")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        (*param_9)(param_5);\n        sqlite3_free(piVar1);\n      }" ({ "{") (expression_statement "(*param_9)(param_5);" (call_expression "(*param_9)(param_5)" (parenthesized_expression "(*param_9)" (( "(") (pointer_expression "*param_9" (* "*") (identifier "param_9")) () ")")) (argument_list "(param_5)" (( "(") (identifier "param_5") () ")"))) (; ";")) (expression_statement "sqlite3_free(piVar1);" (call_expression "sqlite3_free(piVar1)" (identifier "sqlite3_free") (argument_list "(piVar1)" (( "(") (identifier "piVar1") () ")"))) (; ";")) (} "}"))) (goto_statement "goto LAB_00050d40;" (goto "goto") (statement_identifier "LAB_00050d40") (; ";")) (} "}"))) (if_statement "if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {\n      FUN_000265f0();\n    }" (if "if") (parenthesized_expression "((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0)" (( "(") (binary_expression "(*(uint *)(param_1 + 0x4c) & 0xffff00) == 0" (parenthesized_expression "(*(uint *)(param_1 + 0x4c) & 0xffff00)" (( "(") (binary_expression "*(uint *)(param_1 + 0x4c) & 0xffff00" (pointer_expression "*(uint *)(param_1 + 0x4c)" (* "*") (cast_expression "(uint *)(param_1 + 0x4c)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x4c)" (( "(") (binary_expression "param_1 + 0x4c" (identifier "param_1") (+ "+") (number_literal "0x4c")) () ")")))) (& "&") (number_literal "0xffff00")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      FUN_000265f0();\n    }" ({ "{") (expression_statement "FUN_000265f0();" (call_expression "FUN_000265f0()" (identifier "FUN_000265f0") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (expression_statement "(*param_9)(param_5);" (call_expression "(*param_9)(param_5)" (parenthesized_expression "(*param_9)" (( "(") (pointer_expression "*param_9" (* "*") (identifier "param_9")) () ")")) (argument_list "(param_5)" (( "(") (identifier "param_5") () ")"))) (; ";")) (expression_statement "uVar2 = 1;" (assignment_expression "uVar2 = 1" (identifier "uVar2") (= "=") (number_literal "1")) (; ";")) (if_statement "if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;" (if "if") (parenthesized_expression "(*(char *)(param_1 + 0x4d) != '\0')" (( "(") (binary_expression "*(char *)(param_1 + 0x4d) != '\0'" (pointer_expression "*(char *)(param_1 + 0x4d)" (* "*") (cast_expression "(char *)(param_1 + 0x4d)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x4d)" (( "(") (binary_expression "param_1 + 0x4d" (identifier "param_1") (+ "+") (number_literal "0x4d")) () ")")))) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (goto_statement "goto LAB_00050da0;" (goto "goto") (statement_identifier "LAB_00050da0") (; ";"))) (} "}")))) (expression_statement "uVar2 = uVar2 & *(uint *)(param_1 + 0x40);" (assignment_expression "uVar2 = uVar2 & *(uint *)(param_1 + 0x40)" (identifier "uVar2") (= "=") (binary_expression "uVar2 & *(uint *)(param_1 + 0x40)" (identifier "uVar2") (& "&") (pointer_expression "*(uint *)(param_1 + 0x40)" (* "*") (cast_expression "(uint *)(param_1 + 0x40)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x40)" (( "(") (binary_expression "param_1 + 0x40" (identifier "param_1") (+ "+") (number_literal "0x40")) () ")")))))) (; ";")) (labeled_statement "LAB_00050d52:\n  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));" (statement_identifier "LAB_00050d52") (: ":") (expression_statement "sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));" (call_expression "sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc))" (identifier "sqlite3_mutex_leave") (argument_list "(*(undefined4 *)(param_1 + 0xc))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0xc)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0xc)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")")))) () ")"))) (; ";"))) (return_statement "return uVar2;" (return "return") (identifier "uVar2") (; ";")) (} "}")))

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

int function_1
              (type_1 *db,char *zFunc,int nArg,int enc,void *p,
              type_2 *xSFunc,
              type_2 *xStep,
              type_3 *xFinal,type_4 *var_2)

{
  type_5 *var_7;
  type_6 var_4;
  type_7 in_stack_ffffffd4;
  
  var_1(db->mutex);
  if (var_2 == (type_4 *)0x0) {
    var_4 = var_3(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,
                              (type_3 *)0x0,
                              (type_2 *)0x0,
                              (type_5 *)0x0);
LAB_00050d40:
    if ((db->mallocFailed != '\0') || (var_4 == 0xc0a)) {
LAB_00050da0:
      var_4 = var_5(db);
      goto LAB_00050d52;
    }
  }
  else {
    if (sqlite3Config.bMemstat == 0) {
      var_7 = (type_5 *)(*sqlite3Config.m.xMalloc)(0xc);
    }
    else {
      var_7 = (type_5 *)var_6(in_stack_ffffffd4);
    }
    if (var_7 != (type_5 *)0x0) {
      var_7->nRef = 0;
      var_7->var_2 = var_2;
      var_7->pUserData = p;
      var_4 = var_3(db,zFunc,nArg,enc,p,xSFunc,xStep,xFinal,
                                (type_3 *)0x0,
                                (type_2 *)0x0,
                                var_7);
      if (var_7->nRef == 0) {
        (*var_2)(p);
        var_8(var_7);
      }
      goto LAB_00050d40;
    }
    var_4._0_1_ = db->temp_store;
    var_4._1_1_ = db->mallocFailed;
    var_4._2_1_ = db->bBenignMalloc;
    var_4._3_1_ = db->dfltLockMode;
    if ((var_4 & 0xffff00) == 0) {
      var_9(db);
    }
    (*var_2)(p);
    var_4 = 1;
    if (db->mallocFailed != '\0') goto LAB_00050da0;
  }
  var_4 = var_4 & db->errMask;
LAB_00050d52:
  var_10(db->mutex);
  return var_4;
}


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

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

uint MASKED
               (int param_1,undefined4 param_2,undefined4 param_3,undefined4 param_4,int param_5,
               undefined4 param_6,undefined4 param_7,undefined4 param_8,code *param_9)

{
  int *piVar1;
  uint uVar2;
  
  sqlite3_mutex_enter(*(undefined4 *)(param_1 + 0xc));
  if (param_9 == (code *)0x0) {
    uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,0);
LAB_00050d40:
    if ((*(char *)(param_1 + 0x4d) != '\0') || (uVar2 == 0xc0a)) {
LAB_00050da0:
      uVar2 = FUN_0002ad10();
      goto LAB_00050d52;
    }
  }
  else {
    if (DAT_00106360 == 0) {
      piVar1 = (int *)(*DAT_00106380)(0xc);
    }
    else {
      piVar1 = (int *)FUN_000280e0();
    }
    if (piVar1 != (int *)0x0) {
      *piVar1 = 0;
      piVar1[1] = (int)param_9;
      piVar1[2] = param_5;
      uVar2 = FUN_00050620(param_4,param_5,param_6,param_7,param_8,0,0,piVar1);
      if (*piVar1 == 0) {
        (*param_9)(param_5);
        sqlite3_free(piVar1);
      }
      goto LAB_00050d40;
    }
    if ((*(uint *)(param_1 + 0x4c) & 0xffff00) == 0) {
      FUN_000265f0();
    }
    (*param_9)(param_5);
    uVar2 = 1;
    if (*(char *)(param_1 + 0x4d) != '\0') goto LAB_00050da0;
  }
  uVar2 = uVar2 & *(uint *)(param_1 + 0x40);
LAB_00050d52:
  sqlite3_mutex_leave(*(undefined4 *)(param_1 + 0xc));
  return uVar2;
}

