// File: /workspace/github_cpp_makefile_star2_O1/jliesch[P]ofxget/ofxget.cc
// Function: ofxget::OfxGetContext::AddPasswordsForTest(int, char const*)
OfxGetContext& OfxGetContext::AddPasswordsForTest(
    int id, const char* filename) {
  if (is_error()) return *this;
  std::string id_str = std::to_string(id);
  pugi::xml_document doc;
  pugi::xml_parse_result result = doc.load_file(filename);
  if (!result) {
    return *this;
  }
  auto inst = doc.find_child_by_attribute("institution", "id", id_str.c_str());
  if (inst.empty()) {
    return *this;
  }
  for (auto node : inst) {
    vars_map_[node.name()] = node.child_value();
  }
  return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x168, %rsp            # imm = 0x168
movq %rdi, %r14
cmpq $0x0, 0x38(%rdi)
jne 0x8ea0
movq %rdx, %rbx
movl %esi, %r15d
movl %esi, %ebp
negl %ebp
cmovsl %esi, %ebp
movl $0x1, %r12d
cmpl $0xa, %ebp
jb 0x8ddc
movl $0x4, %r12d
movl $0xd1b71759, %eax       # imm = 0xD1B71759
movl %ebp, %ecx
cmpl $0x63, %ecx
jbe 0x8dd3
cmpl $0x3e7, %ecx            # imm = 0x3E7
jbe 0x8dd9
cmpl $0x2710, %ecx           # imm = 0x2710
jb 0x8ddc
movl %ecx, %edx
imulq %rax, %rdx
shrq $0x2d, %rdx
addl $0x4, %r12d
cmpl $0x1869f, %ecx          # imm = 0x1869F
movl %edx, %ecx
ja 0x8da0
addl $-0x3, %r12d
jmp 0x8ddc
addl $-0x2, %r12d
jmp 0x8ddc
decl %r12d
shrl $0x1f, %r15d
leal (%r12,%r15), %esi
leaq 0x40(%rsp), %rax
movq %rax, -0x10(%rax)
leaq 0x30(%rsp), %r13
movq %r13, %rdi
movl $0x2d, %edx
callq 0x6400
addq (%r13), %r15
movq %r15, %rdi
movl %r12d, %esi
movl %ebp, %edx
callq 0x9f6c
leaq 0x98(%rsp), %rdi
callq 0x226c0
leaq 0x80(%rsp), %rdi
leaq 0x98(%rsp), %rsi
movq %rbx, %rdx
movl $0x74, %ecx
xorl %r8d, %r8d
callq 0x2347c
leaq 0x80(%rsp), %rdi
callq 0x22698
testb %al, %al
je 0x8e7f
movq 0x30(%rsp), %rcx
leaq 0x2825d(%rip), %rsi     # 0x310b7
leaq 0x28283(%rip), %rdx     # 0x310e4
leaq 0x98(%rsp), %rdi
callq 0x21202
leaq 0x10(%rsp), %rdi
movq %rax, (%rdi)
callq 0x1d6bc
testb %al, %al
je 0x8eb5
leaq 0x98(%rsp), %rdi
callq 0x2274e
movq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0x8ea0
callq 0x63b0
movq %r14, %rax
addq $0x168, %rsp            # imm = 0x168
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x10(%rsp), %rdi
callq 0x1d57e
movq %rax, 0x18(%rsp)
movq %rdx, 0x20(%rsp)
leaq 0x10(%rsp), %rdi
callq 0x1d58e
leaq 0x70(%rsp), %rcx
movq %rax, (%rcx)
movq %rdx, 0x8(%rcx)
leaq 0x18(%rsp), %r12
leaq 0x28(%rsp), %r13
leaq 0x50(%rsp), %r15
movq %r12, %rdi
leaq 0x70(%rsp), %rsi
callq 0x22228
testb %al, %al
je 0x8e7f
leaq 0x18(%rsp), %rdi
callq 0x2223e
movq (%rax), %rax
movq %rax, 0x28(%rsp)
movq %r13, %rdi
callq 0x1d970
movq %rax, %rbp
movq %r13, %rdi
callq 0x1d6c4
movq %r15, %rdi
movq %rax, %rsi
leaq 0xf(%rsp), %rdx
callq 0x66c0
movq %r14, %rbx
movq %r14, %rdi
movq %r15, %r12
movq %r15, %rsi
callq 0x9c7a
movq %rax, %r14
movq 0x8(%rax), %r15
movq %rbp, %rdi
callq 0x6270
movq %r14, %rdi
xorl %esi, %esi
movq %r15, %rdx
movq %rbp, %rcx
movq %rax, %r8
callq 0x6350
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
movq %rbx, %r14
movq %r12, %r15
je 0x8f81
callq 0x63b0
leaq 0x18(%rsp), %r12
movq %r12, %rdi
callq 0x22292
jmp 0x8eee
jmp 0x8fbf
jmp 0x8fbf
jmp 0x8fbf
movq %rax, %rbx
jmp 0x8fcf
jmp 0x8fbf
jmp 0x8fbf
jmp 0x8fbf
movq %rax, %rbx
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0x8fc2
callq 0x63b0
jmp 0x8fc2
jmp 0x8fbf
movq %rax, %rbx
leaq 0x98(%rsp), %rdi
callq 0x2274e
movq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0x8fe3
callq 0x63b0
movq %rbx, %rdi
callq 0x6430
nop