// File: jliesch[P]ofxget/ofxget.cc
// Function: ofxget::OfxGetContext::AddApp(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
OfxGetContext& OfxGetContext::AddApp(const string& name) {
  if (is_error()) return *this;
  auto apps = OfxApps();
  for (std::size_t i = 0; i < apps.size(); i++) {
    if (apps[i].name == name) {
      vars_map_["APPID"] = apps[i].appid;
      vars_map_["APPVER"] = apps[i].appver;
      return *this;
    }
  }
  error_string_ = "Unknown app " + name;
  return *this;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x110, %rsp            # imm = 0x110
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq %rdi, -0xc0(%rbp)
callq 0xad00
testb $0x1, %al
jne 0x8ba9
jmp 0x8bb9
movq -0xc0(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x8e4f
leaq -0x30(%rbp), %rdi
callq 0x7e00
movq $0x0, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0xc8(%rbp)
leaq -0x30(%rbp), %rdi
callq 0xad30
movq %rax, %rcx
movq -0xc8(%rbp), %rax
cmpq %rcx, %rax
jae 0x8dd8
movq -0x38(%rbp), %rsi
leaq -0x30(%rbp), %rdi
callq 0xadf0
movq %rax, %rdi
movq -0x18(%rbp), %rsi
callq 0xad60
testb $0x1, %al
jne 0x8c13
jmp 0x8dc5
movq -0x38(%rbp), %rsi
leaq -0x30(%rbp), %rdi
callq 0xadf0
movq %rax, %rcx
movq -0xc0(%rbp), %rax
addq $0x20, %rcx
movq %rcx, -0xe0(%rbp)
movq %rax, -0xd8(%rbp)
leaq -0x59(%rbp), %rdi
movq %rdi, -0xd0(%rbp)
callq 0x78f0
movq -0xd0(%rbp), %rdx
leaq 0x60421(%rip), %rsi     # 0x6907b
leaq -0x58(%rbp), %rdi
callq 0x77b0
jmp 0x8c65
movq -0xd8(%rbp), %rdi
leaq -0x58(%rbp), %rsi
callq 0xae10
movq %rax, -0xe8(%rbp)
jmp 0x8c7e
movq -0xe0(%rbp), %rsi
movq -0xe8(%rbp), %rdi
callq 0x7ae0
jmp 0x8c93
leaq -0x58(%rbp), %rdi
callq 0x7b88
leaq -0x59(%rbp), %rdi
callq 0x7b70
movq -0x38(%rbp), %rsi
leaq -0x30(%rbp), %rdi
callq 0xadf0
movq %rax, %rcx
movq -0xc0(%rbp), %rax
addq $0x40, %rcx
movq %rcx, -0x100(%rbp)
movq %rax, -0xf8(%rbp)
leaq -0x91(%rbp), %rdi
movq %rdi, -0xf0(%rbp)
callq 0x78f0
movq -0xf0(%rbp), %rdx
leaq 0x60392(%rip), %rsi     # 0x69081
leaq -0x90(%rbp), %rdi
callq 0x77b0
jmp 0x8cfd
movq -0xf8(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0xae10
movq %rax, -0x108(%rbp)
jmp 0x8d19
movq -0x100(%rbp), %rsi
movq -0x108(%rbp), %rdi
callq 0x7ae0
jmp 0x8d2e
leaq -0x90(%rbp), %rdi
callq 0x7b88
leaq -0x91(%rbp), %rdi
callq 0x7b70
movq -0xc0(%rbp), %rax
movq %rax, -0x8(%rbp)
movl $0x1, -0x98(%rbp)
jmp 0x8e39
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x8d83
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x7b88
leaq -0x59(%rbp), %rdi
callq 0x7b70
jmp 0x8e44
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x8db7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0x90(%rbp), %rdi
callq 0x7b88
leaq -0x91(%rbp), %rdi
callq 0x7b70
jmp 0x8e44
jmp 0x8dc7
movq -0x38(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x38(%rbp)
jmp 0x8bca
movq -0x18(%rbp), %rdx
leaq 0x602a5(%rip), %rsi     # 0x69088
leaq -0xb8(%rbp), %rdi
callq 0xaef0
jmp 0x8df1
movq -0xc0(%rbp), %rdi
addq $0x30, %rdi
leaq -0xb8(%rbp), %rsi
callq 0x74e0
leaq -0xb8(%rbp), %rdi
callq 0x7b88
movq -0xc0(%rbp), %rax
movq %rax, -0x8(%rbp)
movl $0x1, -0x98(%rbp)
jmp 0x8e39
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x8e44
leaq -0x30(%rbp), %rdi
callq 0xac60
jmp 0x8e4f
leaq -0x30(%rbp), %rdi
callq 0xac60
jmp 0x8e5c
movq -0x8(%rbp), %rax
addq $0x110, %rsp            # imm = 0x110
popq %rbp
retq
movq -0x68(%rbp), %rdi
callq 0x7600
nopw %cs:(%rax,%rax)