// File: PepiJK[P]Mail-Server-Client/src/myhelper/myhelper.cpp
// Function: MyHelper::checkClientArguments(int, char**)
void MyHelper::checkClientArguments(int argc, char *argv[])
{
    if (argc < 3)
    {
        cout << "Usage: " << argv[0] << " <address> <port>" << endl;
        exit(EXIT_FAILURE);
    }

    if (!stringIsInt(argv[2]) || stoi(argv[2]) < 1024 || stoi(argv[2]) > 65535)
    {
        cout << "Invalid Port" << endl;
        exit(EXIT_FAILURE);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xf0, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0xa8(%rbp)
cmpl $0x3, -0xc(%rbp)
jge 0x3ce1
movq 0xa332(%rip), %rdi      # 0xdfd0
leaq 0x635f(%rip), %rsi      # 0xa004
callq 0x3350
movq %rax, %rdi
movq -0x18(%rbp), %rax
movq (%rax), %rsi
callq 0x3350
movq %rax, %rdi
leaq 0x637a(%rip), %rsi      # 0xa03d
callq 0x3350
movq %rax, %rdi
movq 0xa2e6(%rip), %rsi      # 0xdfb8
callq 0x3390
movl $0x1, %edi
callq 0x3410
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0xb8(%rbp)
leaq -0x39(%rbp), %rdi
movq %rdi, -0xb0(%rbp)
callq 0x35d0
movq -0xb8(%rbp), %rsi
movq -0xb0(%rbp), %rdx
movb $0x0, -0x72(%rbp)
movb $0x0, -0x73(%rbp)
movb $0x0, -0x9a(%rbp)
movb $0x0, -0x9b(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x4420
jmp 0x3d2f
movq -0xa8(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x3bd0
movb %al, -0xb9(%rbp)
jmp 0x3d47
movb -0xb9(%rbp), %cl
movb $0x1, %al
testb $0x1, %cl
movb %al, -0xba(%rbp)
jne 0x3d5f
jmp 0x3e4c
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0xd0(%rbp)
leaq -0x71(%rbp), %rdi
movq %rdi, -0xc8(%rbp)
callq 0x35d0
movq -0xd0(%rbp), %rsi
movq -0xc8(%rbp), %rdx
movb $0x1, -0x72(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x4420
jmp 0x3d9b
movb $0x1, -0x73(%rbp)
xorl %eax, %eax
movl %eax, %esi
leaq -0x70(%rbp), %rdi
movl $0xa, %edx
callq 0x44d0
movl %eax, -0xd4(%rbp)
jmp 0x3db9
movl -0xd4(%rbp), %ecx
movb $0x1, %al
cmpl $0x400, %ecx            # imm = 0x400
movb %al, -0xba(%rbp)
jl 0x3e4c
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0xe8(%rbp)
leaq -0x99(%rbp), %rdi
movq %rdi, -0xe0(%rbp)
callq 0x35d0
movq -0xe8(%rbp), %rsi
movq -0xe0(%rbp), %rdx
movb $0x1, -0x9a(%rbp)
leaq -0x98(%rbp), %rdi
callq 0x4420
jmp 0x3e14
movb $0x1, -0x9b(%rbp)
xorl %eax, %eax
movl %eax, %esi
leaq -0x98(%rbp), %rdi
movl $0xa, %edx
callq 0x44d0
movl %eax, -0xec(%rbp)
jmp 0x3e38
movl -0xec(%rbp), %eax
cmpl $0xffff, %eax           # imm = 0xFFFF
setg %al
movb %al, -0xba(%rbp)
movb -0xba(%rbp), %al
movb %al, -0xed(%rbp)
testb $0x1, -0x9b(%rbp)
jne 0x3e63
jmp 0x3e6f
leaq -0x98(%rbp), %rdi
callq 0x3210
testb $0x1, -0x9a(%rbp)
jne 0x3e7a
jmp 0x3e86
leaq -0x99(%rbp), %rdi
callq 0x33c0
testb $0x1, -0x73(%rbp)
jne 0x3e8e
jmp 0x3e97
leaq -0x70(%rbp), %rdi
callq 0x3210
testb $0x1, -0x72(%rbp)
jne 0x3e9f
jmp 0x3ea8
leaq -0x71(%rbp), %rdi
callq 0x33c0
leaq -0x38(%rbp), %rdi
callq 0x3210
leaq -0x39(%rbp), %rdi
callq 0x33c0
movb -0xed(%rbp), %al
testb $0x1, %al
jne 0x3ec9
jmp 0x3fb9
movq 0xa100(%rip), %rdi      # 0xdfd0
leaq 0x6178(%rip), %rsi      # 0xa04f
callq 0x3350
movq %rax, %rdi
movq 0xa0d2(%rip), %rsi      # 0xdfb8
callq 0x3390
movl $0x1, %edi
callq 0x3410
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x3fae
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x3fa5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x3f92
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x3f7f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0x3f66
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
testb $0x1, -0x9b(%rbp)
jne 0x3f58
jmp 0x3f64
leaq -0x98(%rbp), %rdi
callq 0x3210
jmp 0x3f66
testb $0x1, -0x9a(%rbp)
jne 0x3f71
jmp 0x3f7d
leaq -0x99(%rbp), %rdi
callq 0x33c0
jmp 0x3f7f
testb $0x1, -0x73(%rbp)
jne 0x3f87
jmp 0x3f90
leaq -0x70(%rbp), %rdi
callq 0x3210
jmp 0x3f92
testb $0x1, -0x72(%rbp)
jne 0x3f9a
jmp 0x3fa3
leaq -0x71(%rbp), %rdi
callq 0x33c0
jmp 0x3fa5
leaq -0x38(%rbp), %rdi
callq 0x3210
leaq -0x39(%rbp), %rdi
callq 0x33c0
jmp 0x3fc2
addq $0xf0, %rsp
popq %rbp
retq
movq -0x48(%rbp), %rdi
callq 0x35c0
nopl (%rax,%rax)