Function at 0x4049f0
Capabilities:
Check if file exists

Disassembly:
push ebp
lea ebp, [esp - 0x2e04]
mov eax, 0x2e04
call fcn.0042cb20
push 0xffffffffffffffff
push 0x43f900
mov eax, dword fs:[0]
push eax
sub esp, 0x10
mov eax, dword [0x4575e0]
xor eax, ebp
mov dword [ebp + 0x2e00], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0x2e0c]
mov dword [ebp - 0x18], eax
mov esi, edx
mov edi, dword [ebp + 0x2e10]
mov dword [ebp - 0x1c], ecx
mov ebx, dword [ebp + 0x2e14]
mov dword [ebp - 4], 0
test esi, esi
je 0x404ae5
test edi, edi
je 0x404ae5
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x404a66
sub eax, edx
sar eax, 1
je 0x404ae5
push 0x800
push 0
lea edx, [ebp]
push edx
call fcn.0042a280
push 0x200
push 0
lea eax, [ebp + 0x2000]
push eax
call fcn.0042a280
push str.DRIVER_NAME
push edi
push str._s__s
push 0x400
lea ecx, [ebp]
push ecx
call fcn.0042984c
add esp, 0x2c
push 0
push 0x100
lea edx, [ebp + 0x2000]
push edx
lea edx, [ebp]
mov ecx, esi
call fcn.00407760
test eax, eax
je 0x404b0c
push edi
push str.Invalid_printer_component__Driver_Name_was_not_defined_______s_
mov ecx, 0x45c218
call fcn.004055f0
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x2e00]
xor ecx, ebp
call fcn.0042955b
add ebp, 0x2e04
mov esp, ebp
pop ebp
ret 0xc
push 0x200
push 0
lea eax, [ebp + 0x2c00]
push eax
call fcn.0042a280
add esp, 0xc
push 0x100
mov edx, edi
cmp byte [0x45c43c], 0
je 0x404b59
lea ecx, [ebp + 0x2c00]
push ecx
push str.inf_x64
mov ecx, esi
call fcn.00408200
test eax, eax
je 0x404b86
push 0x200
push 0
lea edx, [ebp + 0x2c00]
push edx
jmp 0x404b7e
lea eax, [ebp + 0x2c00]
push eax
push str.inf_x86
mov ecx, esi
call fcn.00408200
test eax, eax
je 0x404b86
push 0x200
push 0
lea ecx, [ebp + 0x2c00]
push ecx
call fcn.0042a280
add esp, 0xc
lea eax, [ebp + 0x2c00]
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x404b90
sub eax, edx
sar eax, 1
jne 0x404be0
push 0x200
push 0
lea edx, [ebp + 0x2c00]
push edx
call fcn.0042a280
add esp, 0xc
push 0x100
lea eax, [ebp + 0x2c00]
push eax
push 0x44b328
mov edx, edi
mov ecx, esi
call fcn.00408200
test eax, eax
je 0x404be0
push edi
push str.Invalid_printer_component__Inf_Name_was_not_defined_______s_
jmp 0x404ad8
push 0x200
push 0
lea ecx, [ebp + 0x2a00]
push ecx
call fcn.0042a280
add esp, 0xc
push 0x100
lea edx, [ebp + 0x2a00]
push edx
push 0x44b3ac
mov edx, edi
mov ecx, esi
call fcn.00408200
test eax, eax
je 0x404c2a
push 0x200
push 0
lea eax, [ebp + 0x2a00]
push eax
call fcn.0042a280
add esp, 0xc
push 0x800
push 0
lea ecx, [ebp + 0x2200]
push ecx
call fcn.0042a280
add esp, 0xc
push 0x400
lea edx, [ebp + 0x2200]
push edx
push str.index
mov edx, edi
mov ecx, esi
call fcn.00408200
test eax, eax
jne 0x404c71
lea eax, [ebp + 0x2200]
push eax
call fcn.004298c8
add esp, 4
mov esi, eax
jmp 0x404c74
or esi, 0xffffffff
push 0x800
push 0
lea ecx, [ebp + 0x1800]
push ecx
call fcn.0042a280
add esp, 0xc
lea eax, [ebp + 0x2a00]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x404c93
sub eax, edx
sar eax, 1
je 0x404cd7
lea edx, [ebp + 0x2c00]
push edx
lea eax, [ebp + 0x2a00]
push eax
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx + 0x204]
push edx
push str._s_s_s
push 0x400
lea eax, [ebp + 0x1800]
push eax
call fcn.0042984c
add esp, 0x18
jmp 0x404d01
lea ecx, [ebp + 0x2c00]
push ecx
mov edx, dword [ebp - 0x18]
mov eax, dword [edx + 0x204]
push eax
push str._s_s
push 0x400
lea ecx, [ebp + 0x1800]
push ecx
call fcn.0042984c
add esp, 0x14
lea edx, [ebp + 0x1800]
push edx
push str.INF_:___s_
mov ecx, 0x45c218
call fcn.004055f0
add esp, 8
lea eax, [ebp + 0x1800]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x404d4a
lea ecx, [ebp + 0x1800]
push ecx
push edi
push str.Invalid_Inf_Path___s__:___s_
mov ecx, 0x45c218
call fcn.004055f0
add esp, 0xc
jmp 0x404ae5
push 0x800
push 0
lea edx, [ebp + 0x1000]
push edx
call fcn.0042a280
lea eax, [ebp + 0x1800]
push eax
push str.__s___W__r
push 0x400
lea ecx, [ebp + 0x1000]
push ecx
call fcn.0042984c
add esp, 0x1c
test ebx, ebx
je 0x404df1
mov eax, ebx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x404d86
sub eax, edx
sar eax, 1
je 0x404df1
push 0x800
push 0
lea edx, [ebp + 0x2200]
push edx
call fcn.0042a280
push ebx
push str._N___s_
push 0x400
lea eax, [ebp + 0x2200]
push eax
call fcn.0042984c
push 0x3ff
lea ecx, [ebp + 0x2200]
push ecx
push 0x400
lea edx, [ebp + 0x1000]
push edx
call fcn.004298cd
push ebx
push str.Port_Name_:___s_
mov ecx, 0x45c218
call fcn.004055f0
add esp, 0x34
mov edi, dword [ebp - 0x1c]
test edi, edi
je 0x404e6b
mov eax, edi
lea edx, [eax + 2]
lea ecx, [ecx]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x404e00
sub eax, edx
sar eax, 1
je 0x404e6b
push 0x800
push 0
lea eax, [ebp + 0x2200]
push eax
call fcn.0042a280
push edi
push str._M__s_
push 0x400
lea ecx, [ebp + 0x2200]
push ecx
call fcn.0042984c
push 0x3ff
lea edx, [ebp + 0x2200]
push edx
push 0x400
lea eax, [ebp + 0x1000]
push eax
call fcn.004298cd
push edi
push str.MFG_Name_:___s_
mov ecx, 0x45c218
call fcn.004055f0
add esp, 0x34
cmp esi, 0xffffffff
jne 0x404eca
push 0x800
push 0
lea ecx, [ebp + 0x2200]
push ecx
call fcn.0042a280
push esi
push str._i_d
push 0x400
lea edx, [ebp + 0x2200]
push edx
call fcn.0042984c
push 0x3ff
lea eax, [ebp + 0x2200]
push eax
push 0x400
lea ecx, [ebp + 0x1000]
push ecx
call fcn.004298cd
push esi
push str.Index_:___d_
mov ecx, 0x45c218
call fcn.004055f0
add esp, 0x34
push 0x800
push 0
lea edx, [ebp + 0x800]
push edx
call fcn.0042a280
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax + 0x204]
push ecx
push str.__swiainst.exe_
push 0x400
lea edx, [ebp + 0x800]
push edx
call fcn.0042984c
add esp, 0x1c
lea edx, [ebp + 0x1000]
lea ecx, [ebp + 0x800]
call fcn.00404fb0
mov dword [ebp - 4], 0xffffffff
jmp 0x404ae5