// File: vianna274[P]dropbox/src/Server.cpp
// Function: Dropbox::Server::listenToServers(Dropbox::WrapperSocket*)
void Server::listenToServers(WrapperSocket * socket){
    string ipDoBackup;
    WrapperSocket *talkToBackup;
    MessageData * data = NULL;
    while(true){
        this->electionMutex.lock();
        if (this->status == BEGIN_ELECTION) {
            this->status = STATUS_ELECTION;
            this->electionMutex.unlock();
            if (this->getHighers().size() > 0) {
                this->startElection(this->getHighers());
            }
            else {
                this->becomeMain();
            }
        }
        else {
            this->electionMutex.unlock();
            data = socket->receive(TIMEOUT_ON, 5);
        }
        if (data == NULL)
            continue;
        string username = string(data->username);
        User * user = getUser(username);
        string ip;
        FileRecord fileRecord;
        switch (data->type)
        {
            case TYPE_MAKE_CONNECTION:
                talkToPrimaryMtx.lock();
                this->talkToPrimary = new WrapperSocket(ipMain, stoi(data->payload));
                synchronize();
                talkToPrimaryMtx.unlock();
                this->electionMutex.lock();
                this->status = STATUS_NORMAL;
                this->electionMutex.unlock();
                break;
            case TYPE_COORDINATOR:
                handleReceiveCoordinator(data);
                break;
            case TYPE_ANSWER:
                if(!this->waitForCoordinator() && this->status == STATUS_ELECTION) {
                    this->becomeMain();
                }
                break;
            case TYPE_ELECTION:
                ip = string(data->payload);
                this->answer(ip);
                this->electionMutex.lock();
                if (this->status == STATUS_NORMAL) {
                    this->status = STATUS_ELECTION;
                    this->electionMutex.unlock();
                    if (this->getHighers().size() > 0) {
                        this->startElection(this->getHighers());
                    }
                    else {
                        this->becomeMain();
                    }
                }
                this->electionMutex.unlock(); 
                break;
            case TYPE_MAKE_BACKUP:
                ipDoBackup = string(data->payload);
                talkToBackup = new WrapperSocket(ipDoBackup, BACKUPS_PORT);
                this->backupsSockets.push_back(talkToBackup);
                this->createNewPortBackup(talkToBackup);
                break;
            case TYPE_PING:
                //cout << "PINGING" << endl;
                break;
            case TYPE_CREATE_USER:
                this->usersIp.push_back(string(data->payload));
                if(user == nullptr) {
                    user = new User(username, rootDir+username+"/");
                    users.push_back(user);
                }
                break;
            case TYPE_DELETE: 
                deleteFile(user->getDirPath() + string(data->payload));
                user->removeFileRecord(string(data->payload));
                break;
            case TYPE_SEND_FILE:
                fileRecord = *((FileRecord *)data->payload);
                receiveFile(&listenToServersSocket, string(data->payload), user->getDirPath());
                user->updateFileRecord(fileRecord);
                break;
            //case de propagar coisas 
            default:
                cout << "PACOTE INCORRETO! " << data->type << endl;
                break;
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x740, %rsp            # imm = 0x740
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x540(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x3490
movq $0x0, -0x40(%rbp)
jmp 0xcdc1
movq -0x540(%rbp), %rdi
addq $0x20, %rdi
callq 0x6a60
jmp 0xcdd3
movq -0x540(%rbp), %rax
cmpl $0x1c, 0x180(%rax)
jne 0xcea7
movq -0x540(%rbp), %rdi
movl $0x19, 0x180(%rdi)
addq $0x20, %rdi
callq 0x6a90
jmp 0xce03
movq -0x540(%rbp), %rsi
leaq -0x68(%rbp), %rdi
callq 0xe900
jmp 0xce15
leaq -0x68(%rbp), %rdi
callq 0x122a0
movq %rax, -0x548(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x11a00
movq -0x548(%rbp), %rax
cmpq $0x0, %rax
jbe 0xce95
movq -0x540(%rbp), %rsi
leaq -0x80(%rbp), %rdi
callq 0xe900
jmp 0xce4d
movq -0x540(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0xecb0
jmp 0xce5f
leaq -0x80(%rbp), %rdi
callq 0x11a00
jmp 0xcea5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xdb4e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x80(%rbp), %rdi
callq 0x11a00
jmp 0xdb4e
movq -0x540(%rbp), %rdi
callq 0xe6f0
jmp 0xcea3
jmp 0xcea5
jmp 0xcee0
movq -0x540(%rbp), %rdi
addq $0x20, %rdi
callq 0x6a90
jmp 0xceb9
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x5, %edx
callq 0x17bc0
movq %rax, -0x550(%rbp)
jmp 0xced5
movq -0x550(%rbp), %rax
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
jne 0xceec
jmp 0xcdbf
movq -0x40(%rbp), %rax
addq $0xfb4, %rax            # imm = 0xFB4
movq %rax, -0x560(%rbp)
leaq -0xa1(%rbp), %rdi
movq %rdi, -0x558(%rbp)
callq 0x3620
movq -0x560(%rbp), %rsi
movq -0x558(%rbp), %rdx
leaq -0xa0(%rbp), %rdi
callq 0x3480
jmp 0xcf2c
leaq -0xa1(%rbp), %rdi
callq 0x33e0
leaq -0xd0(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0x3190
jmp 0xcf4d
movq -0x540(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0xf3b0
movq %rax, -0x568(%rbp)
jmp 0xcf69
leaq -0xd0(%rbp), %rdi
callq 0x3280
movq -0x568(%rbp), %rax
movq %rax, -0xb0(%rbp)
leaq -0xf0(%rbp), %rdi
callq 0x3490
movq -0x40(%rbp), %rax
movl (%rax), %eax
addl $-0x2, %eax
movl %eax, %ecx
movq %rcx, -0x570(%rbp)
subl $0x14, %eax
ja 0xdacb
movq -0x570(%rbp), %rax
leaq 0xc370(%rip), %rcx      # 0x19328
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0xa1(%rbp), %rdi
callq 0x33e0
jmp 0xdb4e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xdb42
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0xd0(%rbp), %rdi
callq 0x3280
jmp 0xdb42
movq -0x540(%rbp), %rdi
addq $0xc0, %rdi
callq 0x6a60
jmp 0xd021
movl $0x48, %edi
callq 0x33b0
movq %rax, -0x578(%rbp)
jmp 0xd034
movq -0x540(%rbp), %rsi
movb $0x1, -0x21a(%rbp)
addq $0x9d8, %rsi            # imm = 0x9D8
leaq -0x1f8(%rbp), %rdi
callq 0x3190
jmp 0xd057
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x588(%rbp)
leaq -0x219(%rbp), %rdi
movq %rdi, -0x580(%rbp)
callq 0x3620
movq -0x588(%rbp), %rsi
movq -0x580(%rbp), %rdx
leaq -0x218(%rbp), %rdi
callq 0x3480
jmp 0xd095
xorl %eax, %eax
movl %eax, %esi
leaq -0x218(%rbp), %rdi
movl $0xa, %edx
callq 0x68d0
movl %eax, -0x58c(%rbp)
jmp 0xd0b2
movl -0x58c(%rbp), %edx
movq -0x578(%rbp), %rdi
leaq -0x1f8(%rbp), %rsi
callq 0x17690
jmp 0xd0cd
movq -0x540(%rbp), %rax
movq -0x578(%rbp), %rcx
movb $0x0, -0x21a(%rbp)
movq %rcx, 0x178(%rax)
leaq -0x218(%rbp), %rdi
callq 0x3280
leaq -0x219(%rbp), %rdi
callq 0x33e0
leaq -0x1f8(%rbp), %rdi
callq 0x3280
callq 0xf380
jmp 0xd114
movq -0x540(%rbp), %rdi
addq $0xc0, %rdi
callq 0x6a90
jmp 0xd129
movq -0x540(%rbp), %rdi
addq $0x20, %rdi
callq 0x6a60
jmp 0xd13b
movq -0x540(%rbp), %rdi
movl $0x18, 0x180(%rdi)
addq $0x20, %rdi
callq 0x6a90
jmp 0xd157
jmp 0xdb19
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xdb36
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd1b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd1a1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x218(%rbp), %rdi
callq 0x3280
leaq -0x219(%rbp), %rdi
callq 0x33e0
leaq -0x1f8(%rbp), %rdi
callq 0x3280
testb $0x1, -0x21a(%rbp)
jne 0xd1c4
jmp 0xd1d0
movq -0x578(%rbp), %rdi
callq 0x3370
jmp 0xdb36
movq -0x540(%rbp), %rdi
movq -0x40(%rbp), %rsi
callq 0xf0d0
jmp 0xd1e7
jmp 0xdb19
movq -0x540(%rbp), %rdi
callq 0xee20
movb %al, -0x58d(%rbp)
jmp 0xd200
movb -0x58d(%rbp), %al
testb $0x1, %al
jne 0xd22c
jmp 0xd20c
movq -0x540(%rbp), %rax
cmpl $0x19, 0x180(%rax)
jne 0xd22c
movq -0x540(%rbp), %rdi
callq 0xe6f0
jmp 0xd22a
jmp 0xd22c
jmp 0xdb19
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x5a0(%rbp)
leaq -0x241(%rbp), %rdi
movq %rdi, -0x598(%rbp)
callq 0x3620
movq -0x5a0(%rbp), %rsi
movq -0x598(%rbp), %rdx
leaq -0x240(%rbp), %rdi
callq 0x3480
jmp 0xd26f
leaq -0xf0(%rbp), %rdi
movq %rdi, -0x5a8(%rbp)
leaq -0x240(%rbp), %rsi
movq %rsi, -0x5b0(%rbp)
callq 0x3430
movq -0x5b0(%rbp), %rdi
callq 0x3280
leaq -0x241(%rbp), %rdi
callq 0x33e0
movq -0x5a8(%rbp), %rsi
leaq -0x268(%rbp), %rdi
callq 0x3190
jmp 0xd2bd
movq -0x540(%rbp), %rdi
leaq -0x268(%rbp), %rsi
callq 0xe600
jmp 0xd2d2
leaq -0x268(%rbp), %rdi
callq 0x3280
movq -0x540(%rbp), %rdi
addq $0x20, %rdi
callq 0x6a60
jmp 0xd2f0
movq -0x540(%rbp), %rax
cmpl $0x18, 0x180(%rax)
jne 0xd406
movq -0x540(%rbp), %rdi
movl $0x19, 0x180(%rdi)
addq $0x20, %rdi
callq 0x6a90
jmp 0xd320
movq -0x540(%rbp), %rsi
leaq -0x280(%rbp), %rdi
callq 0xe900
jmp 0xd335
leaq -0x280(%rbp), %rdi
callq 0x122a0
movq %rax, -0x5b8(%rbp)
leaq -0x280(%rbp), %rdi
callq 0x11a00
movq -0x5b8(%rbp), %rax
cmpq $0x0, %rax
jbe 0xd3f4
movq -0x540(%rbp), %rsi
leaq -0x298(%rbp), %rdi
callq 0xe900
jmp 0xd37a
movq -0x540(%rbp), %rdi
leaq -0x298(%rbp), %rsi
callq 0xecb0
jmp 0xd38f
leaq -0x298(%rbp), %rdi
callq 0x11a00
jmp 0xd404
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x241(%rbp), %rdi
callq 0x33e0
jmp 0xdb36
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x268(%rbp), %rdi
callq 0x3280
jmp 0xdb36
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x298(%rbp), %rdi
callq 0x11a00
jmp 0xdb36
movq -0x540(%rbp), %rdi
callq 0xe6f0
jmp 0xd402
jmp 0xd404
jmp 0xd406
movq -0x540(%rbp), %rdi
addq $0x20, %rdi
callq 0x6a90
jmp 0xd418
jmp 0xdb19
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x5c8(%rbp)
leaq -0x2b9(%rbp), %rdi
movq %rdi, -0x5c0(%rbp)
callq 0x3620
movq -0x5c8(%rbp), %rsi
movq -0x5c0(%rbp), %rdx
leaq -0x2b8(%rbp), %rdi
callq 0x3480
jmp 0xd45b
leaq -0x30(%rbp), %rdi
leaq -0x2b8(%rbp), %rsi
movq %rsi, -0x5d8(%rbp)
callq 0x3430
movq -0x5d8(%rbp), %rdi
callq 0x3280
leaq -0x2b9(%rbp), %rdi
callq 0x33e0
movl $0x48, %edi
callq 0x33b0
movq %rax, -0x5d0(%rbp)
jmp 0xd49d
movb $0x1, -0x2e1(%rbp)
leaq -0x2e0(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x3190
jmp 0xd4b6
movq -0x5d0(%rbp), %rdi
leaq -0x2e0(%rbp), %rsi
movl $0x2328, %edx           # imm = 0x2328
callq 0x17690
jmp 0xd4d0
movq -0x5d0(%rbp), %rax
movb $0x0, -0x2e1(%rbp)
movq %rax, -0x38(%rbp)
leaq -0x2e0(%rbp), %rdi
callq 0x3280
movq -0x540(%rbp), %rdi
addq $0x9a0, %rdi            # imm = 0x9A0
leaq -0x38(%rbp), %rsi
callq 0x122c0
jmp 0xd507
movq -0x540(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0xee90
jmp 0xd519
jmp 0xdb19
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x2b9(%rbp), %rdi
callq 0x33e0
jmp 0xdb36
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd561
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x2e0(%rbp), %rdi
callq 0x3280
testb $0x1, -0x2e1(%rbp)
jne 0xd56c
jmp 0xd578
movq -0x5d0(%rbp), %rdi
callq 0x3370
jmp 0xdb36
jmp 0xdb19
movq -0x540(%rbp), %rax
addq $0x988, %rax            # imm = 0x988
movq %rax, -0x5f0(%rbp)
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x5e8(%rbp)
leaq -0x309(%rbp), %rdi
movq %rdi, -0x5e0(%rbp)
callq 0x3620
movq -0x5e8(%rbp), %rsi
movq -0x5e0(%rbp), %rdx
leaq -0x308(%rbp), %rdi
callq 0x3480
jmp 0xd5d4
movq -0x5f0(%rbp), %rdi
leaq -0x308(%rbp), %rsi
callq 0x12330
jmp 0xd5e9
leaq -0x308(%rbp), %rdi
callq 0x3280
leaq -0x309(%rbp), %rdi
callq 0x33e0
cmpq $0x0, -0xb0(%rbp)
jne 0xd799
movl $0x98, %edi
callq 0x33b0
movq %rax, -0x5f8(%rbp)
jmp 0xd622
movb $0x1, -0x371(%rbp)
leaq -0x330(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0x3190
jmp 0xd63e
movq -0x540(%rbp), %rsi
leaq -0x370(%rbp), %rdi
leaq -0xa0(%rbp), %rdx
callq 0x7210
jmp 0xd65a
leaq 0xbda6(%rip), %rdx      # 0x19407
leaq -0x350(%rbp), %rdi
leaq -0x370(%rbp), %rsi
callq 0x6730
jmp 0xd676
movq -0x5f8(%rbp), %rdi
leaq -0x330(%rbp), %rsi
leaq -0x350(%rbp), %rdx
callq 0x16aa0
jmp 0xd692
movq -0x5f8(%rbp), %rax
movb $0x0, -0x371(%rbp)
movq %rax, -0xb0(%rbp)
leaq -0x350(%rbp), %rdi
callq 0x3280
leaq -0x370(%rbp), %rdi
callq 0x3280
leaq -0x330(%rbp), %rdi
callq 0x3280
movq -0x540(%rbp), %rdi
addq $0x958, %rdi            # imm = 0x958
leaq -0xb0(%rbp), %rsi
callq 0x12360
jmp 0xd6e7
jmp 0xd799
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd712
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x308(%rbp), %rdi
callq 0x3280
leaq -0x309(%rbp), %rdi
callq 0x33e0
jmp 0xdb36
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd77d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd771
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd765
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x350(%rbp), %rdi
callq 0x3280
leaq -0x370(%rbp), %rdi
callq 0x3280
leaq -0x330(%rbp), %rdi
callq 0x3280
testb $0x1, -0x371(%rbp)
jne 0xd788
jmp 0xd794
movq -0x5f8(%rbp), %rdi
callq 0x3370
jmp 0xdb36
jmp 0xdb19
movq -0xb0(%rbp), %rsi
leaq -0x3b8(%rbp), %rdi
callq 0x17040
jmp 0xd7b3
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x608(%rbp)
leaq -0x3d9(%rbp), %rdi
movq %rdi, -0x600(%rbp)
callq 0x3620
movq -0x608(%rbp), %rsi
movq -0x600(%rbp), %rdx
leaq -0x3d8(%rbp), %rdi
callq 0x3480
jmp 0xd7f1
leaq -0x398(%rbp), %rdi
leaq -0x3b8(%rbp), %rsi
leaq -0x3d8(%rbp), %rdx
callq 0x6cb0
jmp 0xd80d
movq -0x540(%rbp), %rdi
leaq -0x398(%rbp), %rsi
callq 0xba10
jmp 0xd822
leaq -0x398(%rbp), %rdi
callq 0x3280
leaq -0x3d8(%rbp), %rdi
callq 0x3280
leaq -0x3d9(%rbp), %rdi
callq 0x33e0
leaq -0x3b8(%rbp), %rdi
callq 0x3280
movq -0xb0(%rbp), %rax
movq %rax, -0x620(%rbp)
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x618(%rbp)
leaq -0x401(%rbp), %rdi
movq %rdi, -0x610(%rbp)
callq 0x3620
movq -0x618(%rbp), %rsi
movq -0x610(%rbp), %rdx
leaq -0x400(%rbp), %rdi
callq 0x3480
jmp 0xd89e
movq -0x620(%rbp), %rdi
leaq -0x400(%rbp), %rsi
callq 0x16d00
jmp 0xd8b3
leaq -0x400(%rbp), %rdi
callq 0x3280
leaq -0x401(%rbp), %rdi
callq 0x33e0
jmp 0xdb19
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd910
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd904
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x398(%rbp), %rdi
callq 0x3280
leaq -0x3d8(%rbp), %rdi
callq 0x3280
leaq -0x3d9(%rbp), %rdi
callq 0x33e0
leaq -0x3b8(%rbp), %rdi
callq 0x3280
jmp 0xdb36
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xd953
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x400(%rbp), %rdi
callq 0x3280
leaq -0x401(%rbp), %rdi
callq 0x33e0
jmp 0xdb36
movq -0x40(%rbp), %rsi
addq $0x14, %rsi
leaq -0x1d8(%rbp), %rdi
movl $0xe8, %edx
callq 0x3300
movq -0x540(%rbp), %rax
addq $0x130, %rax            # imm = 0x130
movq %rax, -0x638(%rbp)
movq -0x40(%rbp), %rax
addq $0x14, %rax
movq %rax, -0x630(%rbp)
leaq -0x429(%rbp), %rdi
movq %rdi, -0x628(%rbp)
callq 0x3620
movq -0x630(%rbp), %rsi
movq -0x628(%rbp), %rdx
leaq -0x428(%rbp), %rdi
callq 0x3480
jmp 0xd9cf
movq -0xb0(%rbp), %rsi
leaq -0x450(%rbp), %rdi
callq 0x17040
jmp 0xd9e4
movq -0x638(%rbp), %rsi
movq -0x540(%rbp), %rdi
leaq -0x428(%rbp), %rdx
leaq -0x450(%rbp), %rcx
callq 0x9c30
jmp 0xda07
leaq -0x450(%rbp), %rdi
callq 0x3280
leaq -0x428(%rbp), %rdi
callq 0x3280
leaq -0x429(%rbp), %rdi
callq 0x33e0
movq -0xb0(%rbp), %rax
movq %rax, -0x640(%rbp)
leaq -0x538(%rbp), %rdi
movq %rdi, -0x648(%rbp)
leaq -0x1d8(%rbp), %rsi
movl $0xe8, %edx
callq 0x3300
movq -0x648(%rbp), %rsi
movq %rsp, %rdi
movl $0x1d, %ecx
rep  movsq (%rsi), %es:(%rdi)
movq -0x640(%rbp), %rdi
callq 0x16e50
jmp 0xda78
jmp 0xdb19
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xdabd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
jmp 0xdab1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x48(%rbp)
movl %eax, -0x4c(%rbp)
leaq -0x450(%rbp), %rdi
callq 0x3280
leaq -0x428(%rbp), %rdi
callq 0x3280
leaq -0x429(%rbp), %rdi
callq 0x33e0
jmp 0xdb36
movq 0x154f6(%rip), %rdi     # 0x22fc8
leaq 0xb930(%rip), %rsi      # 0x19409
callq 0x33a0
movq %rax, -0x650(%rbp)
jmp 0xdae7
movq -0x650(%rbp), %rdi
movq -0x40(%rbp), %rax
movl (%rax), %esi
callq 0x35d0
movq %rax, -0x658(%rbp)
jmp 0xdb02
movq -0x658(%rbp), %rdi
movq 0x154a0(%rip), %rsi     # 0x22fb0
callq 0x33d0
jmp 0xdb17
jmp 0xdb19
leaq -0xf0(%rbp), %rdi
callq 0x3280
leaq -0xa0(%rbp), %rdi
callq 0x3280
jmp 0xcdbf
leaq -0xf0(%rbp), %rdi
callq 0x3280
leaq -0xa0(%rbp), %rdi
callq 0x3280
leaq -0x30(%rbp), %rdi
callq 0x3280
movq -0x48(%rbp), %rdi
callq 0x3610