// File: /workspace/github_cpp_makefile_star2_O1/tylerkaraszewski[P]Argyle/ErrorReader.cpp
// Function: ErrorReader::ErrorReader(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
ErrorReader::ErrorReader(int httpErrorCode, const std::string& extraMsg, const std::string& extraHeaders)
{
  m_lengthKnown = true;
  m_done = false;
  m_httpCode = httpErrorCode;
  m_bytesRead = 0;
  
  string num = Utils::llToString(httpErrorCode);
  string msg = getErrorMessage(httpErrorCode);
  string extMsg = msg;
  if (!extraMsg.empty())
  {
    extMsg += "\n" + extraMsg;
  }
  extMsg += "\n";
  m_contentLength = extMsg.size();
  m_dataBuffer += "Content-Length: " + Utils::llToString(m_contentLength) + "\r\n";
  m_dataBuffer += "Content-Type: text/plain\r\n";
  m_dataBuffer += extraHeaders;
  m_dataBuffer += "\r\n";
  m_dataBuffer += extMsg;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rcx, %r15
movq %rdx, %r12
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x5ca1(%rip), %rax      # 0xfd78
movq %rax, (%rdi)
leaq 0x20(%rdi), %r14
leaq 0x30(%rdi), %r13
movq %r13, 0x20(%rdi)
xorl %eax, %eax
movq %rax, 0x28(%rdi)
movb $0x0, 0x30(%rdi)
movw $0x1, 0x10(%rdi)
movl %esi, 0x14(%rdi)
movq %rax, 0x18(%rdi)
movslq %esi, %rsi
leaq 0xa8(%rsp), %rdi
callq 0xac34
leaq 0x68(%rsp), %rdi
movl %ebp, %esi
callq 0xa47a
leaq 0x38(%rsp), %rax
movq %rax, -0x10(%rax)
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
addq %rsi, %rdx
leaq 0x28(%rsp), %rdi
callq 0x773e
cmpq $0x0, 0x8(%r12)
je 0xa184
leaq 0x20ed(%rip), %rsi      # 0xc235
leaq 0x8(%rsp), %rdi
movq %r12, %rdx
callq 0x89eb
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
leaq 0x28(%rsp), %rdi
callq 0x30f0
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa184
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0x20aa(%rip), %rsi      # 0xc235
leaq 0x28(%rsp), %rdi
callq 0x3560
movq 0x30(%rsp), %rsi
movq %rsi, 0x8(%rbx)
leaq 0x88(%rsp), %rdi
callq 0xac34
leaq 0x221e(%rip), %rcx      # 0xc3d0
leaq 0x88(%rsp), %rdi
movl $0x10, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x32e0
leaq 0x58(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0xa1f1
movq %rdx, 0x48(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x58(%rsp)
jmp 0xa1f9
movups (%rcx), %xmm0
movups %xmm0, (%r12)
movq 0x8(%rax), %rdx
leaq 0x48(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x2018(%rip), %rsi      # 0xc234
callq 0x3560
leaq 0x18(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0xa248
movq %rdx, 0x8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x18(%rsp)
jmp 0xa24f
movups (%rcx), %xmm0
movups %xmm0, (%rbp)
movq 0x8(%rax), %rdx
movq %rdx, 0x10(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
movq %r14, %rdi
callq 0x30f0
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0xa290
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3290
movq 0x48(%rsp), %rdi
cmpq %r12, %rdi
je 0xa2a7
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0x98(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa2c8
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0x2207(%rip), %rsi      # 0xc4d6
movq %r14, %rdi
callq 0x3560
movq (%r15), %rsi
movq 0x8(%r15), %rdx
movq %r14, %rdi
callq 0x30f0
leaq 0x1f47(%rip), %rsi      # 0xc234
movq %r14, %rdi
callq 0x3560
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rdx
movq %r14, %rdi
callq 0x30f0
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0xa323
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0x78(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa33e
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa35f
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x3290
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa3fd
movq 0x18(%rsp), %rsi
jmp 0xa3df
jmp 0xa3fa
movq %rax, %r15
movq 0x8(%rsp), %rdi
cmpq %rbp, %rdi
je 0xa3aa
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x3290
jmp 0xa3aa
movq %rax, %r15
movq 0x48(%rsp), %rdi
cmpq %r12, %rdi
je 0xa3c6
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x3290
jmp 0xa3c6
movq %rax, %r15
leaq 0x98(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa3fd
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x3290
jmp 0xa3fd
jmp 0xa3fa
movq %rax, %r15
jmp 0xa419
movq %rax, %r15
jmp 0xa434
movq %rax, %r15
jmp 0xa455
movq %rax, %r15
movq 0x28(%rsp), %rdi
leaq 0x38(%rsp), %rax
cmpq %rax, %rdi
je 0xa419
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0x78(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa434
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x3290
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xa455
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x3290
movq (%r14), %rdi
cmpq %r13, %rdi
je 0xa469
movq (%r13), %rsi
incq %rsi
callq 0x3290
movq %rbx, %rdi
callq 0x8a86
movq %r15, %rdi
callq 0x3520
nop