user: Demonstrate the C code that generates the assembly output below:

```asm
<UI_dup_input_boolean>:
  endbr64
  push   %r15
  mov    %rcx,%r15
  push   %r14
  mov    %rdi,%r14
  push   %r13
  mov    %rdx,%r13
  push   %r12
  mov    %rsi,%r12
  push   %rbp
  mov    %r8,%rbp
  push   %rbx
  mov    %r9d,%ebx
  sub    $0x8,%rsp
  test   %rsi,%rsi
  je     L75
  mov    %rsi,%rdi
  call   <OPENSSL_strdup@plt>
  mov    %rax,%r12
  test   %rax,%rax
  je     L0
L75:
  test   %r13,%r13
  je     L39
  mov    %r13,%rdi
  call   <OPENSSL_strdup@plt>
  mov    %rax,%r13
  test   %rax,%rax
  je     L4
L39:
  test   %r15,%r15
  je     L28
  mov    %r15,%rdi
  call   <OPENSSL_strdup@plt>
  mov    %rax,%r15
  test   %rax,%rax
  je     L13
L28:
  test   %rbp,%rbp
  je     L36
  mov    %rbp,%rdi
  call   <OPENSSL_strdup@plt>
  mov    %rax,%rbp
  test   %rax,%rax
  je     L13
L36:
  mov    D39(%rip),%rax
  mov    %rbp,%r8
  mov    %r15,%rcx
  mov    %r13,%rdx
  sub    $0x8,%rsp
  mov    $0x1,%r9d
  mov    %r12,%rsi
  mov    %r14,%rdi
  push   0x48(%rsp)
  push   %rbx
  mov    (%rax),%eax
  push   %rax
  call   <general_allocate_boolean@plt>
  add    $0x20,%rsp
L77:
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L13:
  mov    D38(%rip),%rax
  mov    (%rax),%esi
  mov    D7(%rip),%rax
  mov    (%rax),%edi
  call   <UIerr@plt>
L16:
  mov    %r12,%rdi
  call   <OPENSSL_free@plt>
  mov    %r13,%rdi
  call   <OPENSSL_free@plt>
  mov    %r15,%rdi
  call   <OPENSSL_free@plt>
  xor    %edi,%edi
  call   <OPENSSL_free@plt>
  mov    $0xffffffff,%eax
  jmp    L77
L4:
  mov    D38(%rip),%rax
  xor    %r15d,%r15d
  mov    (%rax),%esi
  mov    D7(%rip),%rax
  mov    (%rax),%edi
  call   <UIerr@plt>
  jmp    L16
L0:
  mov    D38(%rip),%rax
  xor    %r15d,%r15d
  xor    %r13d,%r13d
  mov    (%rax),%esi
  mov    D7(%rip),%rax
  mov    (%rax),%edi
  call   <UIerr@plt>
  jmp    L16
```

assistant: ```c
int UI_dup_input_boolean(UI *ui, const char *prompt, const char *action_desc, const char *ok_chars, const char *cancel_chars, int flags, char *result_buf) {
  char *prompt_copy = NULL;
  char *action_desc_copy = NULL;
  char *ok_chars_copy = NULL;
  char *cancel_chars_copy = NULL;
  if (prompt) {
    prompt_copy = OPENSSL_strdup(prompt);
    if (prompt_copy == NULL) {
      UIerr(UI_F_UI_DUP_INPUT_BOOLEAN, ERR_R_MALLOC_FAILURE);
      goto err;
    }
  }
  if (action_desc) {
    action_desc_copy = OPENSSL_strdup(action_desc);
    if (action_desc_copy == NULL) {
      UIerr(UI_F_UI_DUP_INPUT_BOOLEAN, ERR_R_MALLOC_FAILURE);
      goto err;
    }
  }
  if (ok_chars) {
    ok_chars_copy = OPENSSL_strdup(ok_chars);
    if (ok_chars_copy == NULL) {
      UIerr(UI_F_UI_DUP_INPUT_BOOLEAN, ERR_R_MALLOC_FAILURE);
      goto err;
    }
  }
  if (cancel_chars) {
    cancel_chars_copy = OPENSSL_strdup(cancel_chars);
    if (cancel_chars_copy == NULL) {
      UIerr(UI_F_UI_DUP_INPUT_BOOLEAN, ERR_R_MALLOC_FAILURE);
      goto err;
    }
  }
  return general_allocate_boolean(ui, prompt_copy, action_desc_copy, ok_chars_copy, cancel_chars_copy, 1, UIT_BOOLEAN, flags, result_buf);
err:
  OPENSSL_free(prompt_copy);
  OPENSSL_free(action_desc_copy);
  OPENSSL_free(ok_chars_copy);
  OPENSSL_free(cancel_chars_copy);
  return -1;
}
```