// File: solaldunckel[P]webserv/srcs/HTTP/Response.cpp
// Function: Response::response_log[abi:cxx11](LogLevel)
std::string Response::response_log(LogLevel level) {
  std::string ret;

  if (level == INFO) {
    ret = "[status: " + ft::to_string(status_code_) + " " + g_status[status_code_] + "]";
    if (headers_.count("Content-Length"))
      ret = ret + " [length: " + headers_["Content-Length"] + "]";
  } else if (level > INFO) {
    ret = "\n\n" + response_.substr(0, header_size_ - 4) + "\n";
    if (body_size_) {
      if (body_size_ < 200)
        ret = ret + "\n" + response_.substr(header_size_);
      else
        ret = ret + "\n" + response_.substr(header_size_, 200) + "...";
    }
  }
  return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x310, %rsp            # imm = 0x310
movq %rdi, -0x2d0(%rbp)
movq %rdi, %rax
movq %rax, -0x2c8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x2c0(%rbp)
movb $0x0, -0x15(%rbp)
callq 0x57b0
cmpl $0x1, -0x14(%rbp)
jne 0x29a7a
movq -0x2c0(%rbp), %rax
movl 0xb8(%rax), %esi
leaq -0xb8(%rbp), %rdi
callq 0x9070
jmp 0x296d0
leaq 0x1a2b5(%rip), %rsi     # 0x4398c
leaq -0x98(%rbp), %rdi
leaq -0xb8(%rbp), %rdx
callq 0x107f0
jmp 0x296ec
leaq 0x1a170(%rip), %rdx     # 0x43863
leaq -0x78(%rbp), %rdi
leaq -0x98(%rbp), %rsi
callq 0x6a80
jmp 0x29705
movq -0x2c0(%rbp), %rax
movl 0xb8(%rax), %esi
leaq 0x32f2f(%rip), %rdi     # 0x5c648
callq 0x40e10
movq %rax, -0x2d8(%rbp)
jmp 0x29727
movq -0x2d8(%rbp), %rdx
leaq -0x58(%rbp), %rdi
leaq -0x78(%rbp), %rsi
callq 0x6a30
jmp 0x2973d
leaq 0x19c0f(%rip), %rdx     # 0x43353
leaq -0x38(%rbp), %rdi
leaq -0x58(%rbp), %rsi
callq 0x6a80
jmp 0x29753
movq -0x2d0(%rbp), %rdi
leaq -0x38(%rbp), %rsi
movq %rsi, -0x2f0(%rbp)
callq 0x56d0
movq -0x2f0(%rbp), %rdi
callq 0x5aa8
leaq -0x58(%rbp), %rdi
callq 0x5aa8
leaq -0x78(%rbp), %rdi
callq 0x5aa8
leaq -0x98(%rbp), %rdi
callq 0x5aa8
leaq -0xb8(%rbp), %rdi
callq 0x5aa8
movq -0x2c0(%rbp), %rax
addq $0x190, %rax            # imm = 0x190
movq %rax, -0x2e8(%rbp)
leaq -0xe9(%rbp), %rdi
movq %rdi, -0x2e0(%rbp)
callq 0x5960
movq -0x2e0(%rbp), %rdx
leaq 0x19e0b(%rip), %rsi     # 0x435e0
leaq -0xe8(%rbp), %rdi
callq 0x6be0
jmp 0x297e3
movq -0x2e8(%rbp), %rdi
leaq -0xe8(%rbp), %rsi
callq 0x20dd0
movq %rax, -0x2f8(%rbp)
jmp 0x297ff
leaq -0xe8(%rbp), %rdi
callq 0x5aa8
leaq -0xe9(%rbp), %rdi
callq 0x55e0
movq -0x2f8(%rbp), %rax
cmpq $0x0, %rax
je 0x29a75
movq -0x2d0(%rbp), %rsi
leaq 0x1a160(%rip), %rdx     # 0x43996
leaq -0x150(%rbp), %rdi
callq 0x8f70
jmp 0x29844
movq -0x2c0(%rbp), %rax
addq $0x190, %rax            # imm = 0x190
movq %rax, -0x308(%rbp)
leaq -0x171(%rbp), %rdi
movq %rdi, -0x300(%rbp)
callq 0x5960
movq -0x300(%rbp), %rdx
leaq 0x19d67(%rip), %rsi     # 0x435e0
leaq -0x170(%rbp), %rdi
callq 0x6be0
jmp 0x29887
movq -0x308(%rbp), %rdi
leaq -0x170(%rbp), %rsi
callq 0x20e30
movq %rax, -0x310(%rbp)
jmp 0x298a3
movq -0x310(%rbp), %rdx
leaq -0x130(%rbp), %rdi
leaq -0x150(%rbp), %rsi
callq 0x6a30
jmp 0x298bf
leaq 0x19a8d(%rip), %rdx     # 0x43353
leaq -0x110(%rbp), %rdi
leaq -0x130(%rbp), %rsi
callq 0x6a80
jmp 0x298db
movq -0x2d0(%rbp), %rdi
leaq -0x110(%rbp), %rsi
callq 0x56d0
leaq -0x110(%rbp), %rdi
callq 0x5aa8
leaq -0x130(%rbp), %rdi
callq 0x5aa8
leaq -0x170(%rbp), %rdi
callq 0x5aa8
leaq -0x171(%rbp), %rdi
callq 0x55e0
leaq -0x150(%rbp), %rdi
callq 0x5aa8
jmp 0x29a75
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29dc5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x299b2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x299a6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x2999d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x5aa8
leaq -0x78(%rbp), %rdi
callq 0x5aa8
leaq -0x98(%rbp), %rdi
callq 0x5aa8
leaq -0xb8(%rbp), %rdi
callq 0x5aa8
jmp 0x29dc5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x299f5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
leaq -0xe8(%rbp), %rdi
callq 0x5aa8
leaq -0xe9(%rbp), %rdi
callq 0x55e0
jmp 0x29dc5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29a58
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29a4c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
leaq -0x130(%rbp), %rdi
callq 0x5aa8
leaq -0x170(%rbp), %rdi
callq 0x5aa8
leaq -0x171(%rbp), %rdi
callq 0x55e0
leaq -0x150(%rbp), %rdi
callq 0x5aa8
jmp 0x29dc5
jmp 0x29d9f
cmpl $0x1, -0x14(%rbp)
jle 0x29d9d
movq -0x2c0(%rbp), %rax
movq %rax, %rsi
addq $0xc0, %rsi
movq 0x130(%rax), %rcx
addq $-0x4, %rcx
xorl %eax, %eax
movl %eax, %edx
leaq -0x1d8(%rbp), %rdi
callq 0x55a0
jmp 0x29ab2
leaq 0x1973d(%rip), %rsi     # 0x431f6
leaq -0x1b8(%rbp), %rdi
leaq -0x1d8(%rbp), %rdx
callq 0x107f0
jmp 0x29ace
leaq 0x19722(%rip), %rdx     # 0x431f7
leaq -0x198(%rbp), %rdi
leaq -0x1b8(%rbp), %rsi
callq 0x6a80
jmp 0x29aea
movq -0x2d0(%rbp), %rdi
leaq -0x198(%rbp), %rsi
callq 0x56d0
leaq -0x198(%rbp), %rdi
callq 0x5aa8
leaq -0x1b8(%rbp), %rdi
callq 0x5aa8
leaq -0x1d8(%rbp), %rdi
callq 0x5aa8
movq -0x2c0(%rbp), %rax
cmpq $0x0, 0x138(%rax)
je 0x29d9b
movq -0x2c0(%rbp), %rax
cmpq $0xc8, 0x138(%rax)
jae 0x29c75
movq -0x2d0(%rbp), %rsi
leaq 0x1969b(%rip), %rdx     # 0x431f7
leaq -0x218(%rbp), %rdi
callq 0x8f70
jmp 0x29b6a
movq -0x2c0(%rbp), %rax
movq %rax, %rsi
addq $0xc0, %rsi
movq 0x130(%rax), %rdx
leaq -0x238(%rbp), %rdi
movq $-0x1, %rcx
callq 0x55a0
jmp 0x29b97
leaq -0x1f8(%rbp), %rdi
leaq -0x218(%rbp), %rsi
leaq -0x238(%rbp), %rdx
callq 0x9550
jmp 0x29bb3
movq -0x2d0(%rbp), %rdi
leaq -0x1f8(%rbp), %rsi
callq 0x56d0
leaq -0x1f8(%rbp), %rdi
callq 0x5aa8
leaq -0x238(%rbp), %rdi
callq 0x5aa8
leaq -0x218(%rbp), %rdi
callq 0x5aa8
jmp 0x29d99
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29c21
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
leaq -0x1b8(%rbp), %rdi
callq 0x5aa8
leaq -0x1d8(%rbp), %rdi
callq 0x5aa8
jmp 0x29dc5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29c64
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
leaq -0x238(%rbp), %rdi
callq 0x5aa8
leaq -0x218(%rbp), %rdi
callq 0x5aa8
jmp 0x29dc5
movq -0x2d0(%rbp), %rsi
leaq 0x19574(%rip), %rdx     # 0x431f7
leaq -0x298(%rbp), %rdi
callq 0x8f70
jmp 0x29c91
movq -0x2c0(%rbp), %rax
movq %rax, %rsi
addq $0xc0, %rsi
movq 0x130(%rax), %rdx
leaq -0x2b8(%rbp), %rdi
movl $0xc8, %ecx
callq 0x55a0
jmp 0x29cbc
leaq -0x278(%rbp), %rdi
leaq -0x298(%rbp), %rsi
leaq -0x2b8(%rbp), %rdx
callq 0x9550
jmp 0x29cd8
leaq 0x19cc2(%rip), %rdx     # 0x439a1
leaq -0x258(%rbp), %rdi
leaq -0x278(%rbp), %rsi
callq 0x6a80
jmp 0x29cf4
movq -0x2d0(%rbp), %rdi
leaq -0x258(%rbp), %rsi
callq 0x56d0
leaq -0x258(%rbp), %rdi
callq 0x5aa8
leaq -0x278(%rbp), %rdi
callq 0x5aa8
leaq -0x2b8(%rbp), %rdi
callq 0x5aa8
leaq -0x298(%rbp), %rdi
callq 0x5aa8
jmp 0x29d99
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29d8b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
jmp 0x29d7f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc0(%rbp)
movl %eax, -0xc4(%rbp)
leaq -0x278(%rbp), %rdi
callq 0x5aa8
leaq -0x2b8(%rbp), %rdi
callq 0x5aa8
leaq -0x298(%rbp), %rdi
callq 0x5aa8
jmp 0x29dc5
jmp 0x29d9b
jmp 0x29d9d
jmp 0x29d9f
movb $0x1, -0x15(%rbp)
testb $0x1, -0x15(%rbp)
jne 0x29db5
movq -0x2d0(%rbp), %rdi
callq 0x5aa8
movq -0x2c8(%rbp), %rax
addq $0x310, %rsp            # imm = 0x310
popq %rbp
retq
movq -0x2d0(%rbp), %rdi
callq 0x5aa8
movq -0xc0(%rbp), %rdi
callq 0x5950
nopl (%rax)