user: 提供的汇编代码用C语言表示会是什么样子：

```asm
<change_adapter_status>:
  endbr64
  push   %r15
  lea    D45(%rip),%rsi
  mov    %rdx,%r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  sub    $0x28,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x18(%rsp)
  xor    %eax,%eax
  call   <mg_get_var@plt>
  lea    D50(%rip),%rsi
  mov    %rbp,%rdi
  mov    %rax,%r13
  call   <mg_get_var@plt>
  lea    D10(%rip),%rsi
  mov    %rbp,%rdi
  mov    %rax,%r12
  call   <mg_get_var@plt>
  movl   $0x0,0x14(%rsp)
  test   %r13,%r13
  je     L22
  test   %r12,%r12
  je     L169
  mov    %rax,%r14
  test   %rax,%rax
  je     L6
  lea    0x14(%rsp),%rdx
  mov    %rax,%rsi
  mov    %r15,%rdi
  call   <squirrel_get_interface_status@plt>
  lea    D72(%rip),%rsi
  mov    %r12,%rdi
  mov    %eax,%ebx
  call   <strcmp@plt>
  mov    $0xffffffff,%r8d
  test   %rax,%rax
  jne    L25
L160:
  mov    %r8d,0xc(%rsp)
  lea    D71(%rip),%rsi
  mov    %r13,%rdi
  test   %ebx,%ebx
  jne    L13
  call   <strcmp@plt>
  mov    0xc(%rsp),%r8d
  test   %rax,%rax
  je     L57
L21:
  lea    D52(%rip),%rsi
  mov    %rbp,%rdi
  xor    %eax,%eax
  call   <mg_printf@plt>
L6:
  mov    %r13,%rdi
  call   <free@plt>
L22:
  test   %r12,%r12
  je     L158
  mov    %r12,%rdi
  call   <free@plt>
L158:
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L65
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L169:
  test   %r13,%r13
  je     L22
  jmp    L6
  nopw   0x0(%rax,%rax,1)
L13:
  call   <strcmp@plt>
  mov    0xc(%rsp),%r8d
  test   %rax,%rax
  jne    L3
  cmp    %r8d,0x14(%rsp)
  je     L21
  mov    %r14,%rsi
  mov    %r15,%rdi
  mov    %r8d,%ecx
  mov    $0x1,%edx
  mov    %r8d,0xc(%rsp)
  call   <squirrel_set_interface_status@plt>
  mov    0xc(%rsp),%edx
  mov    %rbp,%rdi
  xor    %eax,%eax
  lea    D29(%rip),%rsi
  call   <mg_printf@plt>
  jmp    L6
  nopl   0x0(%rax,%rax,1)
L25:
  movsbl (%r12),%edi
  call   <isdigit@plt>
  xor    %r8d,%r8d
  test   %rax,%rax
  je     L160
  mov    %r12,%rdi
  call   <atoi@plt>
  mov    %eax,%r8d
  jmp    L160
  cs nopw 0x0(%rax,%rax,1)
L3:
  mov    %r14,%rsi
  mov    %r15,%rdi
  xor    %ecx,%ecx
  xor    %edx,%edx
  call   <squirrel_set_interface_status@plt>
  lea    D14(%rip),%rsi
  mov    %rbp,%rdi
  xor    %eax,%eax
  call   <mg_printf@plt>
  jmp    L6
  nopl   (%rax)
L57:
  mov    %r14,%rsi
  mov    %r15,%rdi
  mov    %r8d,0xc(%rsp)
  call   <launch_thread@plt>
  mov    0xc(%rsp),%ecx
  mov    %r14,%rsi
  mov    %r15,%rdi
  mov    $0x1,%edx
  call   <squirrel_set_interface_status@plt>
  mov    0xc(%rsp),%edx
  mov    %rbp,%rdi
  xor    %eax,%eax
  lea    D7(%rip),%rsi
  call   <mg_printf@plt>
  jmp    L6
L65:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: label: D45
data_type: string
name: extract_symbolic_data
arguments: label: D50
data_type: string
name: extract_symbolic_data
arguments: label: D10
data_type: string
name: extract_symbolic_data
arguments: label: D72
data_type: string
name: extract_symbolic_data
arguments: label: D71
data_type: string
name: extract_symbolic_data
arguments: label: D52
data_type: string
name: extract_symbolic_data
arguments: label: D29
data_type: string
name: extract_symbolic_data
arguments: label: D14
data_type: string
name: extract_symbolic_data
arguments: label: D7
data_type: string

tool: D45: status

tool: D50: channel

tool: D10: if

tool: D72: scan

tool: D71: monitor

tool: D52: <b>Nothing changed</b>


tool: D29: <b>Changed channel to %u</b>


tool: D14: <b>Turned off adapter</b>


tool: D7: <b>Turned on adapter, channel %u</b>


assistant: ```c
void change_adapter_status(struct mg_connection *c, const struct mg_request_info *ri, void *user_data) {
  struct Squirrel *squirrel = (struct Squirrel *)user_data;
  char *status = mg_get_var(c, "status");
  char *channel = mg_get_var(c, "channel");
  char *adapter_name = mg_get_var(c, "if");
  unsigned interface_channel = 0;
  if (status && channel && adapter_name) {
    unsigned is_running = squirrel_get_interface_status(squirrel, adapter_name, &interface_channel);
    unsigned new_channel;
    if (strcmp(channel, "scan") == 0)
      new_channel = (unsigned)-1;
    else if (isdigit(channel[0]))
      new_channel = atoi(channel);
    else
      new_channel = 0;
    if (is_running && strcmp(status, "monitor") != 0) {
      squirrel_set_interface_status(squirrel, adapter_name, 0, 0);
      mg_printf(c, "<b>Turned off adapter</b>\n");
    } else if (!is_running && strcmp(status, "monitor") == 0) {
      launch_thread(squirrel, adapter_name);
      squirrel_set_interface_status(squirrel, adapter_name, 1, new_channel);
      mg_printf(c, "<b>Turned on adapter, channel %u</b>\n", new_channel);
    } else if (is_running && interface_channel != new_channel) {
      squirrel_set_interface_status(squirrel, adapter_name, 1, new_channel);
      mg_printf(c, "<b>Changed channel to %u</b>\n", new_channel);
    } else
      mg_printf(c, "<b>Nothing changed</b>\n");
  }
  if (status)
    free(status);
  if (channel)
    free(channel);
}
```