// File: /workspace/github_cpp_makefile_star2_O1/Linkerist[P]xs/src/io.cc
// Function: edit_list_file()
void
edit_list_file(void)
{
 string editor = getenv("EDITOR");
 if (editor.empty()) {
  // FIXME: how to detect debian and the /usr/bin/editor rule?
  struct stat buf;
  if (stat("/usr/bin/editor", &buf) == 0)
   editor = "/usr/bin/editor";
  else
   editor = "vi";
 }

 endwin();
 list_to_file();
 if(system((editor + " \"" + get_listfile() + "\"").c_str())){};
 list_from_file();
 refresh();
 init_curses();
 display_list();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x110, %rsp            # imm = 0x110
leaq 0x459c(%rip), %rdi      # 0xab2d
callq 0x3420
leaq 0x60(%rsp), %rbx
leaq 0x80(%rsp), %rdx
movq %rbx, %rdi
movq %rax, %rsi
callq 0x4900
cmpq $0x0, 0x8(%rbx)
jne 0x65f8
leaq 0x3c6a(%rip), %rbx      # 0xa226
leaq 0x80(%rsp), %rsi
movq %rbx, %rdi
callq 0x3310
testl %eax, %eax
leaq 0x60(%rsp), %rdi
movq 0x8(%rdi), %rdx
leaq 0x3c58(%rip), %rcx      # 0xa236
cmoveq %rbx, %rcx
movl $0xf, %eax
movl $0x2, %r8d
cmoveq %rax, %r8
xorl %esi, %esi
callq 0x3580
callq 0x33e0
callq 0x5cd5
leaq 0x10(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x60(%rsp), %rsi
movq 0x68(%rsp), %rdx
addq %rsi, %rdx
movq %rsp, %rdi
callq 0x4a20
leaq 0x3c12(%rip), %rsi      # 0xa239
movq %rsp, %rdi
callq 0x3680
leaq 0x40(%rsp), %rdi
callq 0x3beb
movq (%rsp), %rcx
movq 0x8(%rsp), %r8
movq 0x48(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %esi
cmpq %r14, %rcx
je 0x665a
movq 0x10(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x6679
leaq 0x50(%rsp), %rdi
movl $0xf, %esi
cmpq %rdi, -0x10(%rdi)
je 0x6674
movq 0x50(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x6688
movq 0x40(%rsp), %rsi
movq %rsp, %rdi
callq 0x3110
jmp 0x6696
leaq 0x40(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x33b0
leaq 0x30(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x66ba
movq %rsi, 0x20(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x30(%rsp)
jmp 0x66c0
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x28(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x3b56(%rip), %rsi      # 0xa23a
leaq 0x20(%rsp), %rdi
callq 0x3680
leaq 0x90(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x671e
movq %rdx, 0x80(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x90(%rsp)
jmp 0x6725
movups (%rcx), %xmm0
movups %xmm0, (%r15)
movq 0x8(%rax), %rdx
movq %rdx, 0x88(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x80(%rsp), %rdi
callq 0x32d0
movq 0x80(%rsp), %rdi
cmpq %r15, %rdi
je 0x676a
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x3350
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6785
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x3350
leaq 0x50(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x67a0
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x3350
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x67b6
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x3350
callq 0x4b98
callq 0x35f0
callq 0x7eb3
callq 0x92c0
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x67e5
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x3350
addq $0x110, %rsp            # imm = 0x110
popq %rbx
popq %r14
popq %r15
retq
jmp 0x6878
movq %rax, %rbx
movq 0x80(%rsp), %rdi
cmpq %r15, %rdi
je 0x681c
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x3350
jmp 0x681c
movq %rax, %rbx
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x683c
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x3350
jmp 0x683c
movq %rax, %rbx
leaq 0x50(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x685e
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x3350
jmp 0x685e
jmp 0x685b
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x687b
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x3350
jmp 0x687b
jmp 0x6878
movq %rax, %rbx
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6896
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x3350
movq %rbx, %rdi
callq 0x3620