user: Translate the below assembly code into C programming language:

```asm
<parse_prefs_line>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %rdi,%r12
  mov    %rsi,%rbp
  mov    %rdx,%r13
  mov    %rcx,%r15
  mov    %r8,%r14
  mov    %r9,0x8(%rsp)
  mov    (%rdi),%rbx
  movzbl (%rbx),%edi
  cmp    $0xa,%dil
  je     L323
L340:
  movsbl %dil,%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L323
  add    $0x1,%rbx
  movzbl (%rbx),%edi
  cmp    $0xa,%dil
  jne    L340
L323:
  mov    %rbx,0x0(%rbp)
L204:
  movsbl (%rbx),%edi
  call   <isspace@plt>
  test   %rax,%rax
  jne    L350
  add    $0x1,%rbx
  jmp    L204
L350:
  cmpb   $0xa,(%rbx)
  je     L424
  lea    0x1(%rbx),%rbp
  movb   $0x0,(%rbx)
  movzbl 0x1(%rbx),%edi
  cmp    $0xa,%dil
  je     L257
L228:
  movsbl %dil,%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L257
  add    $0x1,%rbp
  movzbl 0x0(%rbp),%edi
  cmp    $0xa,%dil
  jne    L228
L257:
  mov    %rbp,0x0(%r13)
  jmp    L88
L115:
  add    $0x1,%rbp
L88:
  movsbl 0x0(%rbp),%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L115
  cmpb   $0xa,0x0(%rbp)
  je     L78
  lea    0x1(%rbp),%rbx
  movb   $0x0,0x0(%rbp)
  movzbl 0x1(%rbp),%edi
  cmp    $0xa,%dil
  je     L322
L180:
  movsbl %dil,%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L322
  add    $0x1,%rbx
  movzbl (%rbx),%edi
  cmp    $0xa,%dil
  jne    L180
L322:
  mov    %rbx,(%r15)
  jmp    L315
L404:
  add    $0x1,%rbx
L315:
  movsbl (%rbx),%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L404
  cmpb   $0xa,(%rbx)
  je     L232
  lea    0x1(%rbx),%rbp
  movb   $0x0,(%rbx)
  movzbl 0x1(%rbx),%edi
  cmp    $0xa,%dil
  je     L101
L125:
  movsbl %dil,%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L101
  add    $0x1,%rbp
  movzbl 0x0(%rbp),%edi
  cmp    $0xa,%dil
  jne    L125
L101:
  mov    %rbp,(%r14)
L221:
  movsbl 0x0(%rbp),%edi
  call   <isspace@plt>
  test   %rax,%rax
  jne    L187
  add    $0x1,%rbp
  jmp    L221
L187:
  cmpb   $0xa,0x0(%rbp)
  je     L408
  lea    0x1(%rbp),%rbx
  movb   $0x0,0x0(%rbp)
  movzbl 0x1(%rbp),%edi
  cmp    $0xa,%dil
  je     L211
L230:
  movsbl %dil,%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L303
  add    $0x1,%rbx
  movzbl (%rbx),%edi
  cmp    $0xa,%dil
  jne    L230
L211:
  mov    $0xffffffff,%eax
  jmp    L267
L303:
  cmpb   $0xa,(%rbx)
  je     L116
  mov    0x8(%rsp),%rax
  mov    %rbx,(%rax)
  jmp    L362
L359:
  add    $0x1,%rbx
L362:
  movsbl (%rbx),%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L359
  cmpb   $0xa,(%rbx)
  je     L292
  lea    0x1(%rbx),%rbp
  movb   $0x0,(%rbx)
  movzbl 0x1(%rbx),%edi
  cmp    $0xa,%dil
  je     L87
L119:
  movsbl %dil,%edi
  call   <isspace@plt>
  test   %rax,%rax
  je     L135
  add    $0x1,%rbp
  movzbl 0x0(%rbp),%edi
  cmp    $0xa,%dil
  jne    L119
L87:
  mov    %rbp,%rbx
L292:
  movb   $0x0,(%rbx)
  add    $0x1,%rbx
  mov    %rbx,(%r12)
  mov    $0x0,%eax
L267:
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L135:
  cmpb   $0xa,0x0(%rbp)
  jne    L45
  mov    %rbp,%rbx
  jmp    L292
L424:
  mov    $0xffffffff,%eax
  jmp    L267
L78:
  mov    $0xffffffff,%eax
  jmp    L267
L232:
  mov    $0xffffffff,%eax
  jmp    L267
L408:
  mov    $0xffffffff,%eax
  jmp    L267
L116:
  mov    $0xffffffff,%eax
  jmp    L267
L45:
  mov    $0xffffffff,%eax
  jmp    L267
```

assistant: ```c
int parse_prefs_line(char **start_ptr, char **qid_ptr, char **jg_ptr, char **jsg_ptr, char **docno_ptr, char **rel_ptr) {
  char *ptr = *start_ptr;
  while (*ptr != '\n' && isspace(*ptr))
    ptr++;
  *qid_ptr = ptr;
  while (!isspace(*ptr))
    ptr++;
  if (*ptr == '\n')
    return (-1);
  *ptr++ = '\0';
  while (*ptr != '\n' && isspace(*ptr))
    ptr++;
  *jg_ptr = ptr;
  while (!isspace(*ptr))
    ptr++;
  if (*ptr == '\n')
    return (-1);
  *ptr++ = '\0';
  while (*ptr != '\n' && isspace(*ptr))
    ptr++;
  *jsg_ptr = ptr;
  while (!isspace(*ptr))
    ptr++;
  if (*ptr == '\n')
    return (-1);
  *ptr++ = '\0';
  while (*ptr != '\n' && isspace(*ptr))
    ptr++;
  *docno_ptr = ptr;
  while (!isspace(*ptr))
    ptr++;
  if (*ptr == '\n')
    return (-1);
  *ptr++ = '\0';
  while (*ptr != '\n' && isspace(*ptr))
    ptr++;
  if (*ptr == '\n')
    return (-1);
  *rel_ptr = ptr;
  while (!isspace(*ptr))
    ptr++;
  if (*ptr != '\n') {
    *ptr++ = '\0';
    while (*ptr != '\n' && isspace(*ptr))
      ptr++;
    if (*ptr != '\n')
      return (-1);
  }
  *ptr++ = '\0';
  *start_ptr = ptr;
  return (0);
}
```