83 lines
2.5 KiB
C
83 lines
2.5 KiB
C
/* DBCServer_Release_x64.exe sha256 d9e4fccdf3482e50247686d4452c0b13c75a53efc4bd7320668eece8d1ce828c
|
|
* Ghidra 12.1.2 decompiler output for 0x1401e1e10 FUN_1401e1e10
|
|
* Pseudocode, not original source. */
|
|
|
|
undefined2 * FUN_1401e1e10(longlong *param_1,longlong param_2,undefined8 param_3,undefined8 param_4)
|
|
|
|
{
|
|
longlong *plVar1;
|
|
longlong lVar2;
|
|
char cVar3;
|
|
undefined2 *puVar4;
|
|
bool bVar5;
|
|
undefined8 uVar6;
|
|
longlong *plVar7;
|
|
undefined1 uVar8;
|
|
|
|
uVar6 = 0xfffffffffffffffe;
|
|
if ((int)param_1[8] == 2) {
|
|
bVar5 = *(int *)(*param_1 + 0x14) != 0;
|
|
plVar1 = param_1 + 0xe;
|
|
plVar7 = plVar1;
|
|
if (bVar5) {
|
|
FUN_14016db50();
|
|
}
|
|
*(undefined1 *)(param_1 + 0x15) = 1;
|
|
uVar8 = bVar5;
|
|
if (((*(int *)(*param_1 + 0x14) == 0) && (*(longlong *)(*param_1 + 0x18) != 0)) &&
|
|
(cVar3 = FUN_14016dc80(), cVar3 == '\0')) {
|
|
FUN_14016f090();
|
|
}
|
|
if (param_2 != 0) {
|
|
if (param_1[0xd] == 0) {
|
|
param_1[0xd] = param_2;
|
|
}
|
|
else if (param_1[0xd] != param_2) {
|
|
*(undefined1 *)(param_1 + 0x15) = 0;
|
|
/* WARNING: Subroutine does not return */
|
|
FUN_14016d6b0();
|
|
}
|
|
lVar2 = param_1[9];
|
|
if (lVar2 == 0) {
|
|
puVar4 = (undefined2 *)
|
|
(**(code **)**(undefined8 **)(*param_1 + 8))
|
|
(*(undefined8 **)(*param_1 + 8),param_2 + 0x20,param_3,param_4,uVar6,
|
|
plVar7,uVar8);
|
|
if (puVar4 != (undefined2 *)0x0) {
|
|
puVar4[0xc] = 0;
|
|
*(undefined8 *)(puVar4 + 8) = 0;
|
|
*puVar4 = 0x10e1;
|
|
}
|
|
*(longlong *)(puVar4 + 4) = param_1[0xd];
|
|
puVar4[0xc] = (short)param_1[0xc];
|
|
param_1[0xb] = param_1[0xb] + 1;
|
|
*(undefined1 *)(param_1 + 0x15) = 0;
|
|
if (!bVar5) {
|
|
return puVar4 + 0x10;
|
|
}
|
|
FUN_14016dbe0(plVar1);
|
|
return puVar4 + 0x10;
|
|
}
|
|
param_1[9] = *(longlong *)(lVar2 + 0x10);
|
|
*(undefined8 *)(lVar2 + 0x10) = 0;
|
|
*(short *)(lVar2 + 0x18) = (short)param_1[0xc];
|
|
param_1[10] = param_1[10] + -1;
|
|
*(undefined1 *)(param_1 + 0x15) = 0;
|
|
if (!bVar5) {
|
|
return (undefined2 *)(lVar2 + 0x20);
|
|
}
|
|
FUN_14016dbe0(plVar1);
|
|
return (undefined2 *)(lVar2 + 0x20);
|
|
}
|
|
*(undefined1 *)(param_1 + 0x15) = 0;
|
|
if (bVar5) {
|
|
FUN_14016dbe0(plVar1);
|
|
}
|
|
}
|
|
else {
|
|
FUN_14016f090(L"CLookasideAllocator.Alloc() is called after the allocator is already disposed!")
|
|
;
|
|
}
|
|
return (undefined2 *)0x0;
|
|
}
|
|
|