user: 请将以下的汇编代码转换成C语言代码：

```asm
<accept_loop>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  sub    $0x28,%rsp
  mov    %edi,%r12d
  mov    %fs:0x28,%rax
  mov    %rax,0x2018(%rsp)
  xor    %eax,%eax
  movq   $0x0,0x10(%rsp)
  movq   $0x0,0x18(%rsp)
  lea    0x20(%rsp),%rdi
  mov    $0x1fe,%ecx
  rep stos %rax,%es:(%rdi)
  movq   $0x0,0x1010(%rsp)
  movq   $0x0,0x1018(%rsp)
  lea    0x1020(%rsp),%rdi
  mov    $0x1fe,%ecx
  rep stos %rax,%es:(%rdi)
  lea    D1(%rip),%r15
  lea    D11(%rip),%r14
  lea    D48(%rip),%r13
  jmp    L22
L29:
  mov    0xc(%rsp),%edi
  call   <inet_ntoa@plt>
  mov    %rax,%rbp
  mov    0x8(%rsp),%edi
  call   <ntohs@plt>
  mov    %eax,%edx
  mov    %rbp,%rsi
  mov    %r15,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  lea    0x10(%rsp),%rbp
  mov    $0x1000,%edx
  mov    $0x0,%esi
  mov    %rbp,%rdi
  call   <memset@plt>
  mov    $0x0,%ecx
  mov    $0x1000,%edx
  mov    %rbp,%rsi
  mov    %ebx,%edi
  call   <recv@plt>
  mov    %r14,%rdi
  call   <puts@plt>
  mov    %rbp,%rdi
  call   <puts@plt>
  mov    %r13,%rdi
  call   <puts@plt>
  lea    0x1010(%rsp),%rbp
  lea    D4(%rip),%rsi
  mov    %rbp,%rdi
  call   <strcpy@plt>
  mov    %rbp,%rdi
  call   <strlen@plt>
  mov    %eax,%edx
  mov    $0x0,%ecx
  mov    %rbp,%rsi
  mov    %ebx,%edi
  call   <send@plt>
  mov    %ebx,%edi
  call   <close@plt>
L22:
  movl   $0x8,0x4(%rsp)
  lea    0x4(%rsp),%rdx
  lea    0x8(%rsp),%rsi
  mov    %r12d,%edi
  call   <accept@plt>
  mov    %eax,%ebx
  test   %eax,%eax
  jns    L29
  lea    D45(%rip),%rdi
  call   <perror@plt>
  mov    0x2018(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L10
  mov    $0xffffffff,%eax
  add    $0x2028,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L10:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: label: D1
type_infered: string
name: parse_data
arguments: label: D11
type_infered: string
name: parse_data
arguments: label: D48
type_infered: string
name: parse_data
arguments: label: D4
type_infered: string
name: parse_data
arguments: label: D45
type_infered: string

tool: D1: accept!(IPAddress = %s, Port = %hu)


tool: D11: ----- recv begin -----

tool: D48: ----- recv end -----

tool: D4: HTTP/1.0 200 OK


tool: D45: accept

assistant: ```c
int accept_loop(int soc) {
  struct sockaddr_in client_addr;
  int client_addr_len;
  int acc;
  char *client_ip_addr_str;
  u_short client_port;
  int ret = 0;
  char recv_buf[4096] = {0};
  char send_buf[4096] = {0};
  while (1) {
    client_addr_len = sizeof(client_addr);
    acc = accept(soc, (struct sockaddr *)&client_addr, &client_addr_len);
    if (acc < 0) {
      perror("accept");
      ret = -1;
      break;
    }
    client_ip_addr_str = inet_ntoa(client_addr.sin_addr);
    client_port = ntohs(client_addr.sin_port);
    printf("accept!(IPAddress = %s, Port = %hu)\n", client_ip_addr_str, client_port);
    memset(recv_buf, 0, sizeof(char) * 4096);
    recv(acc, recv_buf, sizeof(recv_buf), 0);
    printf("----- recv begin -----\n");
    printf("%s\n", recv_buf);
    printf("----- recv end -----\n");
    strcpy(send_buf, "HTTP/1.0 200 OK\r\n");
    send(acc, send_buf, strlen(send_buf), 0);
    close(acc);
  }
  return ret;
}
```