// File: mh0fm4[P]SCDC/src/components/node/node_uds.cc
// Function: scdc_nodeconn_uds::open(char const*)
bool scdc_nodeconn_uds::open(const char *authority)
{
  SCDC_TRACE("open: connect to '" << authority << "'");

  if (strlen(authority) <= 0) authority = NODE_UDS_SOCKETNAME_DEFAULT;

  stringlist sl(':', authority);

  string type = sl.front_pop();
  string val = sl.conflate();

  string socketfile;

  if (sl.size() <= 0)
  {
    socketfile = make_uds_socketfile(type.c_str());

  } else if (type == "socketname" || type == "")
  {
    socketfile = make_uds_socketfile(val.c_str());

  } else if (type == "socketfile")
  {
    socketfile = val;

  } else
  {
    SCDC_ERROR("unknown UDS nodeport type '" << type << "'");
    return false;
  }

  scdc_transport_uds *transport_uds = static_cast<scdc_transport_uds *>(transport);

  transport_connection = transport_uds->connect(socketfile.c_str());

  if (!transport_connection)
  {
    SCDC_FAIL("open: connect failed!");
    return false;
  }

  transport_connection->on_idle_handler = scdc_nodeconn_on_idle_close_handler;
  transport_connection->on_idle_data = this;

  return scdc_nodeconn::open(authority);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1a0, %rsp            # imm = 0x1A0
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x108(%rbp)
jmp 0x957c0
movq -0x18(%rbp), %rdi
callq 0xc280
cmpq $0x0, %rax
ja 0x957da
leaq 0x13a06(%rip), %rax     # 0xa91dc
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rdx
leaq -0x40(%rbp), %rdi
movq %rdi, -0x110(%rbp)
movl $0x3a, %esi
movq $-0x1, %rcx
callq 0x25a70
movq -0x110(%rbp), %rsi
leaq -0x60(%rbp), %rdi
callq 0x25b00
jmp 0x9580c
leaq -0x90(%rbp), %rdi
leaq -0x40(%rbp), %rsi
callq 0x2e970
jmp 0x9581e
leaq -0xb0(%rbp), %rdi
callq 0xc960
leaq -0x40(%rbp), %rdi
callq 0x25ae0
movq %rax, -0x118(%rbp)
jmp 0x9583c
movq -0x118(%rbp), %rax
cmpq $0x0, %rax
ja 0x958d6
leaq -0x60(%rbp), %rdi
callq 0xc260
movq %rax, %rsi
leaq -0xd0(%rbp), %rdi
callq 0x94b70
jmp 0x95867
leaq -0xb0(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0xc850
leaq -0xd0(%rbp), %rdi
callq 0xc3e0
jmp 0x95abd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x95c8e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x95c85
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x68(%rbp)
movl %eax, -0x6c(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0xc3e0
leaq -0x90(%rbp), %rdi
callq 0xc3e0
jmp 0x95c85
leaq 0x13fa2(%rip), %rsi     # 0xa987f
leaq -0x60(%rbp), %rdi
callq 0x25b80
movb %al, -0x119(%rbp)
jmp 0x958ee
movb -0x119(%rbp), %al
testb $0x1, %al
jne 0x9591e
jmp 0x958fa
leaq 0x10ca3(%rip), %rsi     # 0xa65a4
leaq -0x60(%rbp), %rdi
callq 0x25b80
movb %al, -0x11a(%rbp)
jmp 0x95912
movb -0x11a(%rbp), %al
testb $0x1, %al
jne 0x9591e
jmp 0x9595f
leaq -0x90(%rbp), %rdi
callq 0xc260
movq %rax, %rsi
leaq -0xf0(%rbp), %rdi
callq 0x94b70
jmp 0x9593b
leaq -0xb0(%rbp), %rdi
leaq -0xf0(%rbp), %rsi
callq 0xc850
leaq -0xf0(%rbp), %rdi
callq 0xc3e0
jmp 0x95abb
leaq 0x13f4a(%rip), %rsi     # 0xa98b0
leaq -0x60(%rbp), %rdi
callq 0x25b80
movb %al, -0x11b(%rbp)
jmp 0x95977
movb -0x11b(%rbp), %al
testb $0x1, %al
jne 0x95983
jmp 0x9599d
leaq -0xb0(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0xc070
jmp 0x95998
jmp 0x95ab9
jmp 0x9599f
leaq 0x3ed02(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x2e8e0
movq %rax, -0x128(%rbp)
jmp 0x959b7
movq -0x128(%rbp), %rax
cmpq $0x0, %rax
je 0x95aa2
leaq 0x3ecd9(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x2e900
jmp 0x959d9
leaq 0x3ecc8(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x2e8e0
movq %rax, -0x130(%rbp)
jmp 0x959f1
movq -0x130(%rbp), %rdi
leaq 0x10aa9(%rip), %rsi     # 0xa64a8
callq 0xc670
movq %rax, -0x138(%rbp)
jmp 0x95a0d
movq -0x138(%rbp), %rdi
leaq 0x13e1b(%rip), %rsi     # 0xa9836
callq 0xc670
movq %rax, -0x140(%rbp)
jmp 0x95a29
movq -0x140(%rbp), %rdi
leaq 0x13ec6(%rip), %rsi     # 0xa98fd
callq 0xc670
movq %rax, -0x148(%rbp)
jmp 0x95a45
movq -0x148(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0xc5b0
movq %rax, -0x150(%rbp)
jmp 0x95a5e
movq -0x150(%rbp), %rdi
leaq 0x12967(%rip), %rsi     # 0xa83d3
callq 0xc670
movq %rax, -0x158(%rbp)
jmp 0x95a7a
movq -0x158(%rbp), %rdi
movq 0x3e538(%rip), %rsi     # 0xd3fc0
callq 0xc6d0
jmp 0x95a8f
leaq 0x3ec12(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x2e920
jmp 0x95aa0
jmp 0x95aa2
jmp 0x95aa4
jmp 0x95aa6
movb $0x0, -0x1(%rbp)
movl $0x1, -0xf4(%rbp)
jmp 0x95c4d
jmp 0x95abb
jmp 0x95abd
movq -0x108(%rbp), %rax
movq 0x68(%rax), %rax
movq %rax, -0x100(%rbp)
movq -0x100(%rbp), %rax
movq %rax, -0x168(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0xc260
movq -0x168(%rbp), %rdi
movq %rax, %rsi
movq (%rdi), %rax
movq 0x100(%rax), %rax
callq *%rax
movq %rax, -0x160(%rbp)
jmp 0x95b08
movq -0x108(%rbp), %rax
movq -0x160(%rbp), %rcx
movq %rcx, 0x70(%rax)
cmpq $0x0, 0x70(%rax)
jne 0x95c09
jmp 0x95b27
leaq 0x3eb7a(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x257e0
movq %rax, -0x170(%rbp)
jmp 0x95b3f
movq -0x170(%rbp), %rax
cmpq $0x0, %rax
je 0x95bf5
leaq 0x3eb51(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x25800
jmp 0x95b61
leaq 0x3eb40(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x257e0
movq %rax, -0x178(%rbp)
jmp 0x95b79
movq -0x178(%rbp), %rdi
leaq 0x10629(%rip), %rsi     # 0xa61b0
callq 0xc670
movq %rax, -0x180(%rbp)
jmp 0x95b95
movq -0x180(%rbp), %rdi
leaq 0x13c93(%rip), %rsi     # 0xa9836
callq 0xc670
movq %rax, -0x188(%rbp)
jmp 0x95bb1
movq -0x188(%rbp), %rdi
leaq 0x13c28(%rip), %rsi     # 0xa97e7
callq 0xc670
movq %rax, -0x190(%rbp)
jmp 0x95bcd
movq -0x190(%rbp), %rdi
movq 0x3e3e5(%rip), %rsi     # 0xd3fc0
callq 0xc6d0
jmp 0x95be2
leaq 0x3eabf(%rip), %rax     # 0xd46a8
movq (%rax), %rdi
callq 0x25820
jmp 0x95bf3
jmp 0x95bf5
jmp 0x95bf7
jmp 0x95bf9
movb $0x0, -0x1(%rbp)
movl $0x1, -0xf4(%rbp)
jmp 0x95c4d
movq -0x108(%rbp), %rdi
movq 0x70(%rdi), %rax
leaq 0x2b5(%rip), %rcx       # 0x95ed0
movq %rcx, 0x10(%rax)
movq 0x70(%rdi), %rax
movq %rdi, 0x18(%rax)
movq -0x18(%rbp), %rsi
callq 0x95e60
movb %al, -0x191(%rbp)
jmp 0x95c38
movb -0x191(%rbp), %al
andb $0x1, %al
movb %al, -0x1(%rbp)
movl $0x1, -0xf4(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0xc3e0
leaq -0x90(%rbp), %rdi
callq 0xc3e0
leaq -0x60(%rbp), %rdi
callq 0xc3e0
leaq -0x40(%rbp), %rdi
callq 0x25c90
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x1a0, %rsp            # imm = 0x1A0
popq %rbp
retq
leaq -0x60(%rbp), %rdi
callq 0xc3e0
leaq -0x40(%rbp), %rdi
callq 0x25c90
movq -0x68(%rbp), %rdi
callq 0xcba0