// File: /workspace/github_cpp_makefile_star2_O2/vianna274[P]dropbox/src/Server.cpp
// Function: Dropbox::Server::initializeUsers()
void Server::initializeUsers()
{
    DIR *dir;
    struct dirent *ent;
    if ((dir = opendir (rootDir.c_str())) != NULL) {
        while ((ent = readdir (dir)) != NULL) {
            if(ent->d_type == 0x4 && string(ent->d_name) != string("..") && string(ent->d_name) != string(".")) {
                User *user = new User(ent->d_name, rootDir+ent->d_name+"/");
                users.push_back(user);
            }
        }
        closedir(dir);
    } 
    else if(mkdir(rootDir.c_str(), 0777) == 0) 
        cout << "CREATED ROOT DIR" << endl;
    else
        cout << "COULDN'T OPEN OR CREATE ROOT DIR" << endl;

    cout << "System Users :" << endl;
    for(User *user : users)
    {
        cout << user->getUsername().c_str() << endl;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rdi, %r12
movq (%rdi), %rdi
callq 0x3450
movq %rax, -0x40(%rbp)
testq %rax, %rax
je 0x7038
movq %r12, -0x38(%rbp)
leaq 0x958(%r12), %rax
movq %rax, -0x48(%rbp)
leaq -0x68(%rbp), %r12
leaq -0xc8(%rbp), %r13
movq -0x40(%rbp), %rdi
callq 0x3470
testq %rax, %rax
je 0x7029
movq %rax, %rbx
cmpb $0x4, 0x12(%rax)
jne 0x6eb3
addq $0x13, %rbx
movq %r12, %rdi
movq %rbx, %rsi
leaq -0x2c(%rbp), %rdx
callq 0x3130
movq %r13, %rdi
leaq 0x54e5(%rip), %rsi      # 0xc3d0
leaq -0x2b(%rbp), %rdx
callq 0x3130
movq %r12, %rdi
movq %r13, %rsi
callq 0xa398
testb %al, %al
je 0x7014
leaq -0x88(%rbp), %rdi
movq %rbx, %rsi
leaq -0x2a(%rbp), %rdx
callq 0x3130
movq %r12, %r14
movq %r13, %r12
leaq -0x108(%rbp), %r15
movq %r15, %rdi
leaq 0x54a0(%rip), %rsi      # 0xc3d1
leaq -0x29(%rbp), %rdx
callq 0x3130
leaq -0x88(%rbp), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0xa398
movq %r15, %rdi
movl %eax, %r15d
callq 0x3170
movq %r13, %rdi
callq 0x3170
movq %r12, %r13
movq %r12, %rdi
callq 0x3170
movq %r14, %r12
movq %r14, %rdi
callq 0x3170
testb %r15b, %r15b
je 0x6eb3
movl $0x98, %edi
callq 0x3320
movq %rax, %r15
leaq -0xa8(%rbp), %rdi
movq %rbx, %rsi
leaq -0x88(%rbp), %rdx
callq 0x3130
movq %r14, %r12
movq %r14, %rdi
movq -0x38(%rbp), %rsi
movq %rbx, %rdx
callq 0x6c5b
leaq -0xe8(%rbp), %rbx
movq %rbx, %rdi
movq %r12, %rsi
leaq 0x53f4(%rip), %rdx      # 0xc3bb
callq 0x4f8a
movq %r15, %rdi
leaq -0xa8(%rbp), %r12
movq %r12, %rsi
movq %rbx, %rdx
callq 0xb084
movq %rbx, %rdi
callq 0x3170
movq %r14, %rdi
callq 0x3170
movq %r12, %rdi
callq 0x3170
movq %r15, -0xc8(%rbp)
movq %r14, %r12
movq -0x48(%rbp), %rdi
movq %r13, %rsi
callq 0xa374
jmp 0x6eb3
movq %r13, %rdi
callq 0x3170
movq %r12, %rdi
callq 0x3170
jmp 0x6eb3
movq -0x40(%rbp), %rdi
callq 0x34c0
movq -0x38(%rbp), %r12
jmp 0x706e
movq (%r12), %rdi
movl $0x1ff, %esi            # imm = 0x1FF
callq 0x3190
movq 0x9f7b(%rip), %rdi      # 0x10fc8
testl %eax, %eax
je 0x705a
leaq 0x538c(%rip), %rsi      # 0xc3e4
jmp 0x7061
leaq 0x5372(%rip), %rsi      # 0xc3d3
callq 0x3310
movq %rax, %rdi
callq 0x31c0
movq 0x9f53(%rip), %rbx      # 0x10fc8
leaq 0x5389(%rip), %rsi      # 0xc405
movq %rbx, %rdi
callq 0x3310
movq %rax, %rdi
callq 0x31c0
movq 0x958(%r12), %r15
movq 0x960(%r12), %r12
leaq -0x68(%rbp), %r14
cmpq %r12, %r15
je 0x70d2
movq (%r15), %rsi
movq %r14, %rdi
callq 0xb34a
movq -0x68(%rbp), %rsi
movq %rbx, %rdi
callq 0x3310
movq %rax, %rdi
callq 0x31c0
movq %r14, %rdi
callq 0x3170
addq $0x8, %r15
jmp 0x70a0
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0xe8(%rbp), %rdi
callq 0x3170
jmp 0x70f8
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x3170
jmp 0x7106
movq %rax, %rbx
leaq -0xa8(%rbp), %rdi
callq 0x3170
jmp 0x7117
movq %rax, %rbx
movq %r15, %rdi
callq 0x32f0
jmp 0x7156
movq %rax, %rbx
leaq -0x88(%rbp), %rdi
callq 0x3170
jmp 0x7135
movq %rax, %rbx
leaq -0xc8(%rbp), %rdi
callq 0x3170
jmp 0x714d
movq %rax, %rbx
jmp 0x7156
jmp 0x714a
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x3170
movq %rbx, %rdi
callq 0x3540