// File: /workspace/github_cpp_makefile_star2_O3/supragya[P]DirectorySync/DirectorySync.cpp
// Function: closeallsystems()
void closeallsystems(){
    std::cout<<"NOTICE: You can shutdown the system by typing <shut>"<<std::endl;
    char input[10];
    while(1) {
        std::cin >> input;
        if(strcmp(input, "shut") == 0){
            std::cout<<"****Shutting down DirectorySync*****"<<std::endl;
            message* closerequest = (message*)malloc(sizeof(message));
            closerequest->valid = 0;
            int sent = send(FCsock, closerequest, sizeof(message), 0);
            free(closerequest);
            std::cout<<        "                                 +---------------------+\n";
            std::cout<<        "                                 | I am in sync. Yes   |\n";
            std::cout<<        "                                 +------------------+--+\n";
            std::cout<<        "                                                    |\n";
            std::cout<<        "                                                    |\n";
            std::cout<<        "  _                                                 |\n";
            std::cout<<        "  \\\\                                                |\n";
            std::cout<<        "   \\\\_          _.-._                               |\n";
            std::cout<<        "    X:\\        (_/ \\_)     <------------------------+\n";
            std::cout<<        "    \\::\\       ( ==  )\n";
            std::cout<<        "     \\::\\       \\== /\n";
            std::cout<<        "    /X:::\\   .-./`-'\\.--.\n";
            std::cout<<        "    \\\\/\\::\\ / /     (    l\n";
            std::cout<<        "     ~\\ \\::\\ /      `.   L.\n";
            std::cout<<        "       \\/:::|         `.'  `\n";
            std::cout<<        "       /:/\\:|          (    `.\n";
            std::cout<<        "       \\/`-'`.          >    )\n";
            std::cout<<        "              \\       //  .-'\n";
            std::cout<<        "               |     /(  .'\n";
            std::cout<<        "               `-..-'_ \\  \\\n";
            std::cout<<        "               __||/_ \\ `-'\n";
            std::cout<<        "              / _ \\ #  |\n";
            std::cout<<        "             |  #  |#  |   B-SD3 Security Droid\n";
            std::cout<<        "          LS |  #  |#  |      - Front View -\n";
            exit(0);
        }
        else{
            std::cout<<"(To close, type \"shut\")"<<std::endl;
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq 0x4521(%rip), %rbx      # 0x7fd0
leaq 0x1f96(%rip), %rsi      # 0x5a4c
movl $0x34, %edx
movq %rbx, %rdi
callq 0x21e0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21a0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2130
movq 0x44ef(%rip), %r14      # 0x7fe0
movl $0x74756873, %r13d      # imm = 0x74756873
leaq 0x1fad(%rip), %r12      # 0x5aab
movq (%r14), %rax
movq -0x18(%rax), %rax
movq 0x10(%r14,%rax), %r15
movl $0xa, %edx
movq %r14, %rdi
leaq -0x32(%rbp), %rsi
callq 0x22c0
movq (%r14), %rax
movq -0x18(%rax), %rax
cmpl $0x0, 0x20(%r14,%rax)
jne 0x3b46
addq $-0xb, %r15
cmpq $-0xb, %r15
ja 0x3b46
movq 0xe8(%r14,%rax), %rdi
movq 0x10(%rdi), %rax
cmpq 0x18(%rdi), %rax
jae 0x3b90
movl -0x32(%rbp), %eax
xorl %r13d, %eax
movzbl -0x2e(%rbp), %ecx
orl %eax, %ecx
je 0x3bb5
movl $0x17, %edx
movq %rbx, %rdi
movq %r12, %rsi
callq 0x21e0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21a0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x2130
jmp 0x3afe
movq (%rdi), %rax
callq *0x48(%rax)
cmpl $-0x1, %eax
jne 0x3b46
movq (%r14), %rax
movq -0x18(%rax), %rax
leaq (%r14,%rax), %rdi
movl 0x20(%r14,%rax), %esi
orl $0x2, %esi
callq 0x22a0
jmp 0x3b46
movq 0x4414(%rip), %rbx      # 0x7fd0
leaq 0x1ec3(%rip), %rsi      # 0x5a86
movq %rbx, %rdi
callq 0x21b0
movq %rax, %rdi
callq 0x20d0
movl $0x400, %edi            # imm = 0x400
callq 0x2230
movq %rax, %r14
movl $0x0, (%rax)
movl 0x1d69c(%rip), %edi     # 0x21288
movl $0x400, %edx            # imm = 0x400
movq %rax, %rsi
xorl %ecx, %ecx
callq 0x20e0
movq %r14, %rdi
callq 0x21f0
leaq 0x17c7(%rip), %rsi      # 0x53d1
movq %rbx, %rdi
callq 0x21b0
leaq 0x17f2(%rip), %rsi      # 0x540b
movq %rbx, %rdi
callq 0x21b0
leaq 0x181d(%rip), %rsi      # 0x5445
movq %rbx, %rdi
callq 0x21b0
leaq 0x1848(%rip), %r14      # 0x547f
movq %rbx, %rdi
movq %r14, %rsi
callq 0x21b0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x21b0
leaq 0x1862(%rip), %rsi      # 0x54b6
movq %rbx, %rdi
callq 0x21b0
leaq 0x188a(%rip), %rsi      # 0x54ed
movq %rbx, %rdi
callq 0x21b0
leaq 0x18b2(%rip), %rsi      # 0x5524
movq %rbx, %rdi
callq 0x21b0
leaq 0x18da(%rip), %rsi      # 0x555b
movq %rbx, %rdi
callq 0x21b0
leaq 0x1902(%rip), %rsi      # 0x5592
movq %rbx, %rdi
callq 0x21b0
leaq 0x190b(%rip), %rsi      # 0x55aa
movq %rbx, %rdi
callq 0x21b0
leaq 0x1913(%rip), %rsi      # 0x55c1
movq %rbx, %rdi
callq 0x21b0
leaq 0x191f(%rip), %rsi      # 0x55dc
movq %rbx, %rdi
callq 0x21b0
leaq 0x192c(%rip), %rsi      # 0x55f8
movq %rbx, %rdi
callq 0x21b0
leaq 0x193a(%rip), %rsi      # 0x5615
movq %rbx, %rdi
callq 0x21b0
leaq 0x1949(%rip), %rsi      # 0x5633
movq %rbx, %rdi
callq 0x21b0
leaq 0x195a(%rip), %rsi      # 0x5653
movq %rbx, %rdi
callq 0x21b0
leaq 0x196b(%rip), %rsi      # 0x5673
movq %rbx, %rdi
callq 0x21b0
leaq 0x197b(%rip), %rsi      # 0x5692
movq %rbx, %rdi
callq 0x21b0
leaq 0x1989(%rip), %rsi      # 0x56af
movq %rbx, %rdi
callq 0x21b0
leaq 0x1997(%rip), %rsi      # 0x56cc
movq %rbx, %rdi
callq 0x21b0
leaq 0x19a5(%rip), %rsi      # 0x56e9
movq %rbx, %rdi
callq 0x21b0
leaq 0x19b0(%rip), %rsi      # 0x5703
movq %rbx, %rdi
callq 0x21b0
leaq 0x19d2(%rip), %rsi      # 0x5734
movq %rbx, %rdi
callq 0x21b0
xorl %edi, %edi
callq 0x2200