// File: mh0fm4[P]SCDC/src/components/dataprov/dataprov_hook.cc
// Function: scdc_dataprov_hook::config_do_cmd_param(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&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, scdc_config_result&, bool&)
bool scdc_dataprov_hook::config_do_cmd_param(const std::string &cmd, const std::string &param, std::string val, scdc_config_result &result, bool &done)
{
  SCDC_TRACE("config_do_cmd_param: cmd: '" << cmd << "', param: '" << param << "', val: '" << val << "', result: '" << result << "'");

  done = true;
  bool ret = true;

  if (param == "")
  {
    ret = scdc_dataprov::config_do_cmd_param(cmd, param, val, result, done);
    if (!ret) goto do_quit;

    done = true;

    if (hook_arg.hook.config)
    {
      scdc_result_t res = SCDC_RESULT_INIT_EMPTY;

      ret = (hook_arg.hook.config(dataprov, cmd.c_str(), param.c_str(), val.c_str(), val.size(), &res) == SCDC_SUCCESS);
      if (!ret) goto do_quit;

      done = true;

      /* base class AND hook, concat results */
      if (cmd == "info")
      {
        ret = scdc_dataprov_config::info(result, SCDC_RESULT_STR(&res));

      } else if (cmd == "ls")
      {
        ret = scdc_dataprov_config::ls(result, SCDC_RESULT_STR(&res));

      } else
      {
        ret = true;
        result = SCDC_RESULT_STR(&res);
      }
    }

  } else
  {
    ret = scdc_dataprov::config_do_cmd_param(cmd, param, val, result, done);
    if (!ret) goto do_quit;

    if (done);
    else if (hook_arg.hook.config)
    {
      scdc_result_t res = SCDC_RESULT_INIT_EMPTY;

      ret = (hook_arg.hook.config(dataprov, cmd.c_str(), param.c_str(), val.c_str(), val.size(), &res) == SCDC_SUCCESS);
      if (!ret) goto do_quit;

      done = true;

      result = SCDC_RESULT_STR(&res);

    } else done = false;
  }

do_quit:
  if (done && !ret)
  {
    SCDC_FAIL("config_do_cmd_param: cmd '" << cmd << "' failed");
    return false;
  }

  return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x5b0, %rsp            # imm = 0x5B0
movq %rcx, -0x500(%rbp)
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq %r8, -0x30(%rbp)
movq %r9, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x4f8(%rbp)
jmp 0x79467
movq -0x38(%rbp), %rax
movb $0x1, (%rax)
movb $0x1, -0x39(%rbp)
movq -0x20(%rbp), %rdi
leaq 0x2d127(%rip), %rsi     # 0xa65a4
callq 0x25b80
testb $0x1, %al
jne 0x7948b
jmp 0x7971a
movq -0x500(%rbp), %rsi
movq -0x18(%rbp), %rax
movq %rax, -0x520(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x518(%rbp)
leaq -0x60(%rbp), %rdi
movq %rdi, -0x510(%rbp)
callq 0xc270
movq -0x4f8(%rbp), %rdi
movq -0x520(%rbp), %rsi
movq -0x518(%rbp), %rdx
movq -0x510(%rbp), %rcx
movq -0x30(%rbp), %r8
movq -0x38(%rbp), %r9
callq 0x5f860
movb %al, -0x501(%rbp)
jmp 0x794e9
movb -0x501(%rbp), %al
andb $0x1, %al
movb %al, -0x39(%rbp)
leaq -0x60(%rbp), %rdi
callq 0xc3e0
testb $0x1, -0x39(%rbp)
jne 0x79522
jmp 0x79951
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0x60(%rbp), %rdi
callq 0xc3e0
jmp 0x79a25
movq -0x4f8(%rbp), %rax
movq -0x38(%rbp), %rcx
movb $0x1, (%rcx)
cmpq $0x0, 0x78(%rax)
je 0x79715
leaq -0x278(%rbp), %rdi
xorl %esi, %esi
movl $0x208, %edx            # imm = 0x208
callq 0xc350
movq -0x4f8(%rbp), %rax
movq $0x200, -0x278(%rbp) # imm = 0x200
movq 0x78(%rax), %rcx
movq %rcx, -0x528(%rbp)
movq 0xb8(%rax), %rax
movq %rax, -0x548(%rbp)
movq -0x18(%rbp), %rdi
callq 0xc260
movq %rax, -0x540(%rbp)
movq -0x20(%rbp), %rdi
callq 0xc260
movq -0x500(%rbp), %rdi
movq %rax, -0x538(%rbp)
callq 0xc260
movq -0x500(%rbp), %rdi
movq %rax, -0x530(%rbp)
callq 0xc460
movq -0x548(%rbp), %rdi
movq -0x540(%rbp), %rsi
movq -0x538(%rbp), %rdx
movq -0x530(%rbp), %rcx
movq %rax, %r8
movq -0x528(%rbp), %rax
leaq -0x278(%rbp), %r9
callq *%rax
cmpq $0x1, %rax
sete %al
andb $0x1, %al
movb %al, -0x39(%rbp)
testb $0x1, -0x39(%rbp)
jne 0x795fe
jmp 0x79951
movq -0x38(%rbp), %rax
movb $0x1, (%rax)
movq -0x18(%rbp), %rdi
leaq 0x2d263(%rip), %rsi     # 0xa6873
callq 0x25b80
testb $0x1, %al
jne 0x7961b
jmp 0x79639
movq -0x30(%rbp), %rdi
leaq -0x278(%rbp), %rsi
addq $0x8, %rsi
callq 0x278f0
andb $0x1, %al
movb %al, -0x39(%rbp)
jmp 0x79713
movq -0x18(%rbp), %rdi
leaq 0x2d4ec(%rip), %rsi     # 0xa6b30
callq 0x25b80
testb $0x1, %al
jne 0x7964f
jmp 0x7966d
movq -0x30(%rbp), %rdi
leaq -0x278(%rbp), %rsi
addq $0x8, %rsi
callq 0x27920
andb $0x1, %al
movb %al, -0x39(%rbp)
jmp 0x79711
movb $0x1, -0x39(%rbp)
leaq -0x270(%rbp), %rax
movq %rax, -0x558(%rbp)
leaq -0x299(%rbp), %rdi
movq %rdi, -0x550(%rbp)
callq 0xcbc0
movq -0x558(%rbp), %rsi
movq -0x550(%rbp), %rdx
leaq -0x298(%rbp), %rdi
callq 0x27820
jmp 0x796ae
movq -0x30(%rbp), %rdi
leaq -0x298(%rbp), %rsi
callq 0x79ba0
jmp 0x796c0
leaq -0x298(%rbp), %rdi
callq 0xc3e0
leaq -0x299(%rbp), %rdi
callq 0xc730
jmp 0x79711
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x79700
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0x298(%rbp), %rdi
callq 0xc3e0
leaq -0x299(%rbp), %rdi
callq 0xc730
jmp 0x79a25
jmp 0x79713
jmp 0x79715
jmp 0x7994f
movq -0x500(%rbp), %rsi
movq -0x18(%rbp), %rax
movq %rax, -0x578(%rbp)
movq -0x20(%rbp), %rax
movq %rax, -0x570(%rbp)
leaq -0x2c0(%rbp), %rdi
movq %rdi, -0x568(%rbp)
callq 0xc270
movq -0x4f8(%rbp), %rdi
movq -0x578(%rbp), %rsi
movq -0x570(%rbp), %rdx
movq -0x568(%rbp), %rcx
movq -0x30(%rbp), %r8
movq -0x38(%rbp), %r9
callq 0x5f860
movb %al, -0x559(%rbp)
jmp 0x7977b
movb -0x559(%rbp), %al
andb $0x1, %al
movb %al, -0x39(%rbp)
leaq -0x2c0(%rbp), %rdi
callq 0xc3e0
testb $0x1, -0x39(%rbp)
jne 0x797ba
jmp 0x79951
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0x2c0(%rbp), %rdi
callq 0xc3e0
jmp 0x79a25
movq -0x38(%rbp), %rax
testb $0x1, (%rax)
je 0x797c8
jmp 0x7994d
movq -0x4f8(%rbp), %rax
cmpq $0x0, 0x78(%rax)
je 0x79944
leaq -0x4c8(%rbp), %rdi
xorl %esi, %esi
movl $0x208, %edx            # imm = 0x208
callq 0xc350
movq -0x4f8(%rbp), %rax
movq $0x200, -0x4c8(%rbp) # imm = 0x200
movq 0x78(%rax), %rcx
movq %rcx, -0x580(%rbp)
movq 0xb8(%rax), %rax
movq %rax, -0x5a0(%rbp)
movq -0x18(%rbp), %rdi
callq 0xc260
movq %rax, -0x598(%rbp)
movq -0x20(%rbp), %rdi
callq 0xc260
movq -0x500(%rbp), %rdi
movq %rax, -0x590(%rbp)
callq 0xc260
movq -0x500(%rbp), %rdi
movq %rax, -0x588(%rbp)
callq 0xc460
movq -0x5a0(%rbp), %rdi
movq -0x598(%rbp), %rsi
movq -0x590(%rbp), %rdx
movq -0x588(%rbp), %rcx
movq %rax, %r8
movq -0x580(%rbp), %rax
leaq -0x4c8(%rbp), %r9
callq *%rax
cmpq $0x1, %rax
sete %al
andb $0x1, %al
movb %al, -0x39(%rbp)
testb $0x1, -0x39(%rbp)
jne 0x7989d
jmp 0x79951
movq -0x38(%rbp), %rax
movb $0x1, (%rax)
leaq -0x4c0(%rbp), %rax
movq %rax, -0x5b0(%rbp)
leaq -0x4e9(%rbp), %rdi
movq %rdi, -0x5a8(%rbp)
callq 0xcbc0
movq -0x5b0(%rbp), %rsi
movq -0x5a8(%rbp), %rdx
leaq -0x4e8(%rbp), %rdi
callq 0x27820
jmp 0x798e1
movq -0x30(%rbp), %rdi
leaq -0x4e8(%rbp), %rsi
callq 0x79ba0
jmp 0x798f3
leaq -0x4e8(%rbp), %rdi
callq 0xc3e0
leaq -0x4e9(%rbp), %rdi
callq 0xc730
jmp 0x7994b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x79933
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0x4e8(%rbp), %rdi
callq 0xc3e0
leaq -0x4e9(%rbp), %rdi
callq 0xc730
jmp 0x79a25
movq -0x38(%rbp), %rax
movb $0x0, (%rax)
jmp 0x7994d
jmp 0x7994f
jmp 0x79951
movq -0x38(%rbp), %rax
testb $0x1, (%rax)
je 0x79a0f
testb $0x1, -0x39(%rbp)
jne 0x79a0f
jmp 0x7996a
leaq 0x5ad37(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x257e0
cmpq $0x0, %rax
je 0x79a07
leaq 0x5ad1e(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x25800
leaq 0x5ad0f(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x257e0
movq %rax, %rdi
leaq 0x2c805(%rip), %rsi     # 0xa61b0
callq 0xc670
movq %rax, %rdi
leaq 0x2eed8(%rip), %rsi     # 0xa8892
callq 0xc670
movq %rax, %rdi
leaq 0x2cf75(%rip), %rsi     # 0xa693e
callq 0xc670
movq %rax, %rdi
movq -0x18(%rbp), %rsi
callq 0xc5b0
movq %rax, %rdi
leaq 0x2e528(%rip), %rsi     # 0xa7f0c
callq 0xc670
movq %rax, %rdi
movq 0x5a5cd(%rip), %rsi     # 0xd3fc0
callq 0xc6d0
leaq 0x5aca9(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x25820
jmp 0x79a09
movb $0x0, -0x1(%rbp)
jmp 0x79a17
movb -0x39(%rbp), %al
andb $0x1, %al
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x5b0, %rsp            # imm = 0x5B0
popq %rbp
retq
movq -0x68(%rbp), %rdi
callq 0xcba0
nop