// File: mh0fm4[P]SCDC/src/components/dataprov/dataprov_register.cc
// Function: scdc_dataprov_register::reg_update(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
bool scdc_dataprov_register::reg_update(const std::string &url)
{
  SCDC_TRACE("reg_update: url: '" << url << "'");

  register_t::iterator i = reg.find(url);

  if (i == reg.end()) return false;

  i->second.type = "";
  i->second.state = "";

  string cmd = url + "/CONFIG info";

  bool ret = scdc_dataset_cmd(SCDC_DATASET_NULL, cmd.c_str(), 0, 0);
  string result = scdc_last_result();

  if (ret)
  {
    string::size_type p = result.find('|');

    i->second.type = result.substr(0, p);
    if (p != string::npos) i->second.state = result.substr(p + 1, string::npos);
  }

  SCDC_TRACE("reg_update: type: '" << i->second.type << "', state: '" << i->second.state << "'");

  return ret;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x120, %rsp            # imm = 0x120
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0xd8(%rbp)
jmp 0x30cb0
movq -0xd8(%rbp), %rdi
addq $0x68, %rdi
movq -0x18(%rbp), %rsi
callq 0x31580
movq -0xd8(%rbp), %rdi
movq %rax, -0x20(%rbp)
addq $0x68, %rdi
callq 0x315b0
movq %rax, -0x28(%rbp)
leaq -0x20(%rbp), %rdi
leaq -0x28(%rbp), %rsi
callq 0x31600
testb $0x1, %al
jne 0x30cef
jmp 0x30cf8
movb $0x0, -0x1(%rbp)
jmp 0x30f20
leaq -0x20(%rbp), %rdi
movq %rdi, -0xf8(%rbp)
callq 0x31630
movq %rax, %rdi
addq $0x20, %rdi
leaq 0x7588e(%rip), %rsi     # 0xa65a4
movq %rsi, -0xf0(%rbp)
callq 0xc920
movq -0xf8(%rbp), %rdi
callq 0x31630
movq -0xf0(%rbp), %rsi
movq %rax, %rdi
addq $0x40, %rdi
callq 0xc920
movq -0x18(%rbp), %rsi
leaq 0x75b1f(%rip), %rdx     # 0xa686b
leaq -0x48(%rbp), %rdi
movq %rdi, -0xe8(%rbp)
callq 0x31740
movq -0xe8(%rbp), %rdi
callq 0xc260
movq %rax, %rsi
xorl %eax, %eax
movl %eax, %ecx
movq %rcx, %rdi
movq %rcx, %rdx
callq 0x23d80
movq %rax, -0xe0(%rbp)
jmp 0x30d83
movq -0xe0(%rbp), %rax
testq %rax, %rax
setne -0x49(%rbp)
callq 0x21ec0
movq %rax, -0x100(%rbp)
jmp 0x30d9f
leaq -0x81(%rbp), %rdi
movq %rdi, -0x108(%rbp)
callq 0xcbc0
movq -0x100(%rbp), %rsi
movq -0x108(%rbp), %rdx
leaq -0x80(%rbp), %rdi
callq 0x27820
jmp 0x30dcb
leaq -0x81(%rbp), %rdi
callq 0xc730
testb $0x1, -0x49(%rbp)
je 0x30ef3
xorl %eax, %eax
movl %eax, %edx
movq %rdx, -0x110(%rbp)
leaq -0x80(%rbp), %rdi
movq %rdi, -0x118(%rbp)
movl $0x7c, %esi
callq 0xc8e0
movq -0x118(%rbp), %rsi
movq -0x110(%rbp), %rdx
movq %rax, -0x90(%rbp)
movq -0x90(%rbp), %rcx
leaq -0xb0(%rbp), %rdi
callq 0xc6b0
jmp 0x30e2b
leaq -0x20(%rbp), %rdi
callq 0x31630
movq %rax, %rdi
addq $0x20, %rdi
leaq -0xb0(%rbp), %rsi
callq 0xc850
leaq -0xb0(%rbp), %rdi
callq 0xc3e0
cmpq $-0x1, -0x90(%rbp)
je 0x30ef1
movq -0x90(%rbp), %rdx
incq %rdx
leaq -0xd0(%rbp), %rdi
leaq -0x80(%rbp), %rsi
movq $-0x1, %rcx
callq 0xc6b0
jmp 0x30e84
leaq -0x20(%rbp), %rdi
callq 0x31630
movq %rax, %rdi
addq $0x20, %rdi
addq $0x20, %rdi
leaq -0xd0(%rbp), %rsi
callq 0xc850
leaq -0xd0(%rbp), %rdi
callq 0xc3e0
jmp 0x30ef1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x30f15
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x81(%rbp), %rdi
callq 0xc730
jmp 0x30f15
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x80(%rbp), %rdi
callq 0xc3e0
jmp 0x30f15
jmp 0x30ef3
jmp 0x30ef5
jmp 0x30ef7
jmp 0x30ef9
movb -0x49(%rbp), %al
andb $0x1, %al
movb %al, -0x1(%rbp)
leaq -0x80(%rbp), %rdi
callq 0xc3e0
leaq -0x48(%rbp), %rdi
callq 0xc3e0
jmp 0x30f20
leaq -0x48(%rbp), %rdi
callq 0xc3e0
jmp 0x30f2e
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x120, %rsp            # imm = 0x120
popq %rbp
retq
movq -0x58(%rbp), %rdi
callq 0xcba0
nopw (%rax,%rax)