user: What is the c source code of the assembly code below?

```asm
<main>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x88,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x78(%rsp)
  xor    %eax,%eax
  lea    D185(%rip),%rsi
  lea    D41(%rip),%rdi
  call   <fopen@plt>
  mov    %rax,%rbp
  lea    D108(%rip),%rbx
  lea    D4(%rip),%r14
  lea    D137(%rip),%r15
  test   %rax,%rax
  jne    L169
  lea    D55(%rip),%rdi
  call   <perror@plt>
L43:
  mov    0x78(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L122
  mov    $0x0,%eax
  add    $0x88,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L58:
  mov    $0xa,%edx
  mov    %r12,%rsi
  mov    %r15,%rdi
  call   <strncmp@plt>
  test   %rax,%rax
  jne    L88
  mov    %rbx,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,%rdi
  mov    %rsp,%rdx
  lea    D122(%rip),%rsi
  mov    $0x0,%eax
  call   <sscanf@plt>
  mov    (%rsp),%esi
  lea    D181(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L169:
  lea    0x10(%rsp),%rdi
  mov    %rbp,%rdx
  mov    $0x64,%esi
  call   <fgets@plt>
  test   %rax,%rax
  je     L43
  lea    0x10(%rsp),%rdi
  mov    %rbx,%rsi
  call   <strtok@plt>
  mov    %rax,%r12
  mov    $0xa,%edx
  mov    %rax,%rsi
  mov    %r14,%rdi
  call   <strncmp@plt>
  test   %rax,%rax
  jne    L58
  mov    %r14,%rdi
  call   <puts@plt>
  jmp    L169
L88:
  mov    $0xa,%edx
  mov    %r12,%rsi
  lea    D82(%rip),%rdi
  call   <strncmp@plt>
  test   %rax,%rax
  je     L78
  mov    $0xa,%edx
  mov    %r12,%rsi
  lea    D197(%rip),%rdi
  call   <strncmp@plt>
  test   %rax,%rax
  jne    L84
  mov    %rbx,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,%rdi
  mov    %rsp,%rdx
  lea    D145(%rip),%rsi
  mov    $0x0,%eax
  call   <sscanf@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd (%rsp),%xmm0
  lea    D73(%rip),%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  jmp    L169
L78:
  mov    %rbx,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,%rdi
  test   %rax,%rax
  je     L97
  lea    0x4(%rsp),%r13
  mov    $0x0,%r12d
L32:
  mov    %r13,%rdx
  lea    D145(%rip),%rsi
  mov    $0x0,%eax
  call   <sscanf@plt>
  mov    %rbx,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,%rdi
  add    $0x1,%r12d
  add    $0x4,%r13
  cmp    $0x2,%r12d
  jg     L97
  test   %rax,%rax
  jne    L32
L97:
  pxor   %xmm0,%xmm0
  cvtss2sd 0x4(%rsp),%xmm0
  pxor   %xmm2,%xmm2
  cvtss2sd 0xc(%rsp),%xmm2
  pxor   %xmm1,%xmm1
  cvtss2sd 0x8(%rsp),%xmm1
  lea    D54(%rip),%rdi
  mov    $0x3,%eax
  call   <printf@plt>
  jmp    L169
L84:
  mov    $0xa,%edx
  mov    %r12,%rsi
  lea    D6(%rip),%rdi
  call   <strncmp@plt>
  test   %rax,%rax
  jne    L17
  mov    %rbx,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,%rdi
  mov    %rsp,%rdx
  lea    D145(%rip),%rsi
  mov    $0x0,%eax
  call   <sscanf@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd (%rsp),%xmm0
  lea    D162(%rip),%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  jmp    L169
L17:
  mov    $0xa,%edx
  mov    %r12,%rsi
  lea    D48(%rip),%rdi
  call   <strncmp@plt>
  test   %rax,%rax
  jne    L11
  mov    %rbx,%rsi
  mov    $0x0,%edi
  call   <strtok@plt>
  mov    %rax,%rdi
  mov    %rsp,%rdx
  lea    D145(%rip),%rsi
  mov    $0x0,%eax
  call   <sscanf@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd (%rsp),%xmm0
  lea    D148(%rip),%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  jmp    L169
L11:
  mov    %r12,%rsi
  lea    D36(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L169
L122:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: tag: D185
data_type: string
name: extract_symbolic_data
arguments: tag: D41
data_type: string
name: extract_symbolic_data
arguments: tag: D108
data_type: string
name: extract_symbolic_data
arguments: tag: D4
data_type: string
name: extract_symbolic_data
arguments: tag: D137
data_type: string
name: extract_symbolic_data
arguments: tag: D55
data_type: string
name: extract_symbolic_data
arguments: tag: D122
data_type: string
name: extract_symbolic_data
arguments: tag: D181
data_type: string
name: extract_symbolic_data
arguments: tag: D82
data_type: string
name: extract_symbolic_data
arguments: tag: D197
data_type: string
name: extract_symbolic_data
arguments: tag: D145
data_type: string
name: extract_symbolic_data
arguments: tag: D73
data_type: string
name: extract_symbolic_data
arguments: tag: D54
data_type: string
name: extract_symbolic_data
arguments: tag: D6
data_type: string
name: extract_symbolic_data
arguments: tag: D162
data_type: string
name: extract_symbolic_data
arguments: tag: D48
data_type: string
name: extract_symbolic_data
arguments: tag: D148
data_type: string
name: extract_symbolic_data
arguments: tag: D36
data_type: string

tool: D185: r

tool: D41: nurbs/1509077_Samsonite.nurbs

tool: D108:  :


tool: D4: SPLINE

tool: D137: n_ctrlp

tool: D55: Error opening file.

tool: D122: %d

tool: D181: n_ctrlp: %d


tool: D82: ctrlp

tool: D197: knot

tool: D145: %f

tool: D73: knot: %f


tool: D54: ctrlp: %f %f %f


tool: D6: u_min

tool: D162: u_min: %f


tool: D48: u_max

tool: D148: u_max: %f


tool: D36: Parsing error: %s


assistant: ```c
int main() {
  FILE *fp;
  char *pch;
  char buff[100];
  unsigned long i = 0;
  fp = fopen("nurbs/1509077_Samsonite.nurbs", "r");
  if (fp == NULL)
    perror("Error opening file.");
  else {
    while (fgets(buff, 100, fp) != NULL) {
      pch = strtok(buff, " :\n");
      if (strncmp("SPLINE", pch, 10) == 0) {
        printf("SPLINE\n");
      } else if (strncmp("n_ctrlp", pch, 10) == 0) {
        pch = strtok(NULL, " :\n");
        int n_ctrlp;
        sscanf(pch, "%d", &n_ctrlp);
        printf("n_ctrlp: %d\n", n_ctrlp);
      } else if (strncmp("ctrlp", pch, 10) == 0) {
        pch = strtok(NULL, " :\n");
        int i;
        float ctrlp[3];
        for (i = 0; i < 3 && pch != NULL; i++) {
          sscanf(pch, "%f", ctrlp + i);
          pch = strtok(NULL, " :\n");
        }
        printf("ctrlp: %f %f %f\n", ctrlp[0], ctrlp[1], ctrlp[2]);
      } else if (strncmp("knot", pch, 10) == 0) {
        pch = strtok(NULL, " :\n");
        float knot;
        sscanf(pch, "%f", &knot);
        printf("knot: %f\n", knot);
      } else if (strncmp("u_min", pch, 10) == 0) {
        pch = strtok(NULL, " :\n");
        float u_min;
        sscanf(pch, "%f", &u_min);
        printf("u_min: %f\n", u_min);
      } else if (strncmp("u_max", pch, 10) == 0) {
        pch = strtok(NULL, " :\n");
        float u_max;
        sscanf(pch, "%f", &u_max);
        printf("u_max: %f\n", u_max);
      } else {
        printf("Parsing error: %s\n", pch);
      }
    }
  }
  return 0;
}
```