// File: /workspace/github_cpp_makefile_star2_O1/nurseiit[P]cpp-server/server.cpp
// Function: Headers::get_response[abi:cxx11]()
std::string get_response() {
    std::stringstream response_stream;

    FILE *fp;
    std::string path = url;

    if (path == "/") {
      path = "/index.html";
    }
    if (path.find("../") != -1) {
      path = "/403.html";
    }
    path = "./web" + path;

    if ((fp = fopen(path.c_str(), "rb")) == nullptr) {
      std::string content = "<html><body><h1>404 Not Found</h1></body></html>";
      response_stream << "HTTP/1.1 404 Not Found" << std::endl;
      response_stream << "content-type: text/html" << std::endl;
      response_stream << "content-length: " << content.length() << std::endl;
      response_stream << std::endl;
      response_stream << content;
    } else {
      std::stringstream content_stream;
      char buffer[6969];
      long n;

      while ((n = fread(buffer, 1, 6969, fp)) > 0)
        content_stream << buffer;
      fclose(fp);

      std::string content = content_stream.str();
      response_stream << "HTTP/1.1 200 OK" << std::endl;
      response_stream << "content-type: text/html" << std::endl;
      response_stream << "content-length: " << content.length() << std::endl;
      response_stream << std::endl;
      response_stream << content;
    }
    return response_stream.str();
  }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1e90, %rsp           # imm = 0x1E90
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x40(%rsp), %rdi
callq 0x52a0
leaq 0x10(%rsp), %r13
movq %r13, -0x10(%r13)
movq 0x20(%r14), %rsi
movq 0x28(%r14), %rdx
addq %rsi, %rdx
movq %rsp, %rdi
callq 0xcba6
leaq 0x392f(%rip), %rsi      # 0x1176e
movq %rsp, %rdi
callq 0x5100
testl %eax, %eax
jne 0xde66
movq %rsp, %rdi
movq 0x8(%rdi), %rdx
leaq 0x3907(%rip), %rcx      # 0x11760
movl $0xb, %r8d
xorl %esi, %esi
callq 0x5520
leaq 0x38ff(%rip), %rsi      # 0x1176c
movq %rsp, %rdi
movl $0x3, %ecx
xorl %edx, %edx
callq 0x55c0
cmpq $-0x1, %rax
je 0xde9d
movq %rsp, %rdi
movq 0x8(%rdi), %rdx
leaq 0x38e0(%rip), %rcx      # 0x11770
movl $0x9, %r8d
xorl %esi, %esi
callq 0x5520
leaq 0x38d6(%rip), %rsi      # 0x1177a
leaq 0x350(%rsp), %rdi
movq %rsp, %rdx
callq 0xea56
movq %rsp, %rdi
leaq 0x350(%rsp), %r14
movq %r14, %rsi
callq 0x5410
movq (%r14), %rdi
leaq 0x360(%rsp), %r12
cmpq %r12, %rdi
je 0xdedc
callq 0x5340
movq (%rsp), %rdi
leaq 0x3899(%rip), %rsi      # 0x11780
callq 0x53f0
testq %rax, %rax
je 0xe09f
movq %rax, %r14
leaq 0x1c8(%rsp), %rdi
callq 0x52a0
leaq 0x1d8(%rsp), %r15
leaq 0x350(%rsp), %r12
movl $0x1, %esi
movl $0x1b39, %edx           # imm = 0x1B39
movq %r12, %rdi
movq %r14, %rcx
callq 0x54f0
testq %rax, %rax
jle 0xdf47
movq %r12, %rdi
callq 0x51b0
movq %r15, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x53b0
jmp 0xdf15
movq %r14, %rdi
callq 0x5360
leaq 0x1e0(%rsp), %rsi
leaq 0x20(%rsp), %rdi
callq 0x5550
leaq 0x50(%rsp), %r14
leaq 0x3887(%rip), %rsi      # 0x117f4
movl $0xf, %edx
movq %r14, %rdi
callq 0x53b0
movq 0x50(%rsp), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r14, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
leaq 0x3821(%rip), %rsi      # 0x117cb
movl $0x17, %edx
movq %r14, %rdi
callq 0x53b0
movq 0x50(%rsp), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r14, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
leaq 0x37fc(%rip), %rsi      # 0x117e3
movl $0x10, %edx
movq %r14, %rdi
callq 0x53b0
movq 0x28(%rsp), %rsi
movq %r14, %rdi
callq 0x5270
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r15, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
movq 0x50(%rsp), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r14, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
movq 0x20(%rsp), %rsi
movq 0x28(%rsp), %rdx
movq %r14, %rdi
callq 0x53b0
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xe079
callq 0x5340
movq 0xaee8(%rip), %rsi      # 0x18f68
leaq 0x1c8(%rsp), %rdi
callq 0x52d0
leaq 0x248(%rsp), %rdi
callq 0x5150
jmp 0xe1dd
leaq 0x350(%rsp), %rdi
movq %r12, (%rdi)
leaq 0x36d2(%rip), %rsi      # 0x11783
leaq 0x36fb(%rip), %rdx      # 0x117b3
callq 0x6df0
leaq 0x50(%rsp), %r14
leaq 0x36eb(%rip), %rsi      # 0x117b4
movl $0x16, %edx
movq %r14, %rdi
callq 0x53b0
movq 0x50(%rsp), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r14, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
leaq 0x36c5(%rip), %rsi      # 0x117cb
movl $0x17, %edx
movq %r14, %rdi
callq 0x53b0
movq 0x50(%rsp), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r14, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
leaq 0x36a0(%rip), %rsi      # 0x117e3
movl $0x10, %edx
movq %r14, %rdi
callq 0x53b0
movq 0x358(%rsp), %rsi
movq %r14, %rdi
callq 0x5270
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r15, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
movq 0x50(%rsp), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x5350
movsbl %al, %esi
movq %r14, %rdi
callq 0x5040
movq %rax, %rdi
callq 0x5280
movq 0x350(%rsp), %rsi
movq 0x358(%rsp), %rdx
movq %r14, %rdi
callq 0x53b0
movq 0x350(%rsp), %rdi
cmpq %r12, %rdi
je 0xe1dd
callq 0x5340
leaq 0x58(%rsp), %rsi
movq %rbx, %rdi
callq 0x5550
movq (%rsp), %rdi
cmpq %r13, %rdi
je 0xe1f8
callq 0x5340
movq 0xad69(%rip), %rsi      # 0x18f68
leaq 0x40(%rsp), %rdi
callq 0x52d0
leaq 0xc0(%rsp), %rdi
callq 0x5150
movq %rbx, %rax
addq $0x1e90, %rsp           # imm = 0x1E90
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0xe237
jmp 0xe26b
jmp 0xe237
jmp 0xe237
movq %rax, %rbx
jmp 0xe29d
movq %rax, %rbx
jmp 0xe28f
movq %rax, %rbx
movq 0x350(%rsp), %rdi
cmpq %r12, %rdi
je 0xe28f
callq 0x5340
jmp 0xe28f
movq %rax, %rbx
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xe26e
callq 0x5340
jmp 0xe26e
movq %rax, %rbx
movq 0xacf3(%rip), %rsi      # 0x18f68
leaq 0x1c8(%rsp), %rdi
callq 0x52d0
leaq 0x248(%rsp), %rdi
callq 0x5150
movq (%rsp), %rdi
cmpq %r13, %rdi
je 0xe29d
callq 0x5340
movq 0xacc4(%rip), %rsi      # 0x18f68
leaq 0x40(%rsp), %rdi
callq 0x52d0
leaq 0xc0(%rsp), %rdi
callq 0x5150
movq %rbx, %rdi
callq 0x55d0
nop