user: 请显示与下面列出的汇编代码相匹配的C语言实现:

```asm
<seek_config_path>:
  endbr64
  push   %r15
  mov    $0x800,%edx
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  sub    $0xc38,%rsp
  mov    %rsi,0x8(%rsp)
  lea    0x420(%rsp),%r12
  mov    %r12,%rdi
  mov    %fs:0x28,%rax
  mov    %rax,0xc28(%rsp)
  xor    %eax,%eax
  call   <strncpy@plt>
  mov    $0x800,%esi
  mov    %r12,%rdi
  call   <trim_leading@plt>
  xor    %eax,%eax
  jmp    L14
  cs nopw 0x0(%rax,%rax,1)
L115:
  cmp    $0x3e,%dl
  je     L282
  add    $0x1,%rax
  cmp    $0x1ff,%rax
  je     L266
L14:
  movzbl (%r12,%rax,1),%edx
  movslq %eax,%rbx
  test   $0xdf,%dl
  jne    L115
L282:
  lea    0x20(%rsp),%r15
  mov    %ebx,%edx
  mov    %r12,%rsi
  mov    %r15,%rdi
  call   <strncpy@plt>
  movb   $0x0,0x20(%rsp,%rbx,1)
  nopl   0x0(%rax)
L85:
  mov    %rbp,%rdi
  call   <fgetc@plt>
  test   %eax,%eax
  jne    L85
  mov    %rbp,%rdi
  call   <read_compressed_int@plt>
  mov    %eax,(%rsp)
  test   %eax,%eax
  jle    L173
  xor    %ebx,%ebx
  lea    0x220(%rsp),%r13
  nopl   (%rax)
L251:
  mov    %rbp,%rdi
  call   <ftell@plt>
  mov    %rbp,%rdi
  mov    %eax,0x1c(%rsp)
  call   <fgetc@plt>
  mov    %eax,%r14d
  test   %eax,%eax
  je     L299
  cmp    $0x1,%eax
  je     L134
  cmp    $0x2,%eax
  je     L129
  nopl   (%rax)
L272:
  mov    %rbp,%rdi
  call   <fgetc@plt>
  test   %eax,%eax
  jne    L272
L117:
  add    $0x1,%ebx
  cmp    %ebx,(%rsp)
  jne    L251
L173:
  mov    $0xffffffff,%r14d
  nopw   0x0(%rax,%rax,1)
L93:
  mov    0xc28(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L235
  add    $0xc38,%rsp
  mov    %r14d,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L299:
  mov    %rbp,%rdx
  mov    $0x200,%esi
  mov    %r13,%rdi
  call   <fgets@plt>
  test   %rax,%rax
  je     L205
  mov    D41(%rip),%rax
  mov    %r13,%rdi
  mov    (%rax),%edx
  mov    %edx,0x4(%rsp)
  call   <strlen@plt>
  mov    0x4(%rsp),%edx
  add    0x1c(%rsp),%eax
  mov    %rbp,%rdi
  lea    0x2(%rax),%esi
  call   <fseek@plt>
  lea    0x1c(%rsp),%rdi
  mov    $0x4,%esi
  mov    %rbp,%rcx
  mov    $0x1,%edx
  call   <fread@plt>
  mov    %r15,%rsi
  mov    %r13,%rdi
  call   <stricmp@plt>
  test   %rax,%rax
  jne    L117
  mov    D41(%rip),%rax
  mov    0x1c(%rsp),%esi
  mov    %rbp,%rdi
  mov    (%rax),%edx
  call   <fseek@plt>
  mov    $0x3e,%esi
  mov    %r12,%rdi
  call   <strchr@plt>
  test   %rax,%rax
  je     L93
  mov    0x8(%rsp),%rdi
  mov    $0x3e,%esi
  call   <strchr@plt>
  mov    %r12,%rdi
  lea    0x8(%rax),%rsi
  call   <strcpy@plt>
  mov    %r12,%rsi
  mov    %rbp,%rdi
  call   <seek_config_path>
  mov    %eax,%r14d
  jmp    L93
  nopl   (%rax)
L129:
  mov    %rbp,%rdx
  mov    $0x200,%esi
  mov    %r13,%rdi
  call   <fgets@plt>
  test   %rax,%rax
  je     L205
  mov    %r15,%rsi
  mov    %r13,%rdi
  call   <stricmp@plt>
  test   %rax,%rax
  mov    D41(%rip),%rax
  je     L245
  mov    (%rax),%r14d
  mov    %r13,%rdi
  add    $0x1,%ebx
  call   <strlen@plt>
  add    0x1c(%rsp),%eax
  mov    %rbp,%rdi
  lea    0x2(%rax),%esi
  mov    %r14d,%edx
  call   <fseek@plt>
  mov    %rbp,%rdi
  call   <skip_array@plt>
  cmp    %ebx,(%rsp)
  jne    L251
  jmp    L173
  nopw   0x0(%rax,%rax,1)
L134:
  mov    %rbp,%rdi
  call   <fgetc@plt>
  mov    %rbp,%rdx
  mov    $0x200,%esi
  mov    %r13,%rdi
  mov    %eax,%r14d
  call   <fgets@plt>
  test   %rax,%rax
  je     L205
  mov    %r15,%rsi
  mov    %r13,%rdi
  call   <stricmp@plt>
  test   %rax,%rax
  mov    D41(%rip),%rax
  mov    (%rax),%edx
  je     L112
  mov    %r13,%rdi
  mov    %edx,0x4(%rsp)
  call   <strlen@plt>
  mov    0x4(%rsp),%edx
  add    0x1c(%rsp),%eax
  mov    %rbp,%rdi
  lea    0x3(%rax),%esi
  call   <fseek@plt>
  test   %r14d,%r14d
  je     L105
  mov    D19(%rip),%rax
  mov    $0x4,%esi
  mov    %rbp,%rdi
  add    $0x1,%ebx
  mov    (%rax),%edx
  call   <fseek@plt>
  cmp    %ebx,(%rsp)
  jne    L251
  jmp    L173
  nopl   0x0(%rax)
L105:
  mov    %rbp,%rdi
  call   <fgetc@plt>
  test   %eax,%eax
  je     L117
  mov    %rbp,%rdi
  call   <fgetc@plt>
  test   %eax,%eax
  jne    L105
  jmp    L117
L266:
  mov    $0x1ff,%ebx
  jmp    L282
L205:
  mov    $0x1,%r14d
  jmp    L93
L245:
  mov    (%rax),%edx
L112:
  mov    0x1c(%rsp),%esi
  mov    %rbp,%rdi
  xor    %r14d,%r14d
  call   <fseek@plt>
  jmp    L93
L235:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
int seek_config_path(FILE *f, char *config_path) {
  int i;
  uint8_t type;
  uint32_t num_entries;
  uint32_t fp;
  char path[2048];
  char target[512];
  char buffer[512];
  strncpy(path, config_path, sizeof(path));
  trim_leading(path, sizeof(path));
  for (i = 0; i < sizeof(target) - 1; i++) {
    if (path[i] == 0 || path[i] == '>' || path[i] == ' ')
      break;
  }
  strncpy(target, path, i);
  target[i] = 0;
  while (fgetc(f) != 0)
    ;
  num_entries = read_compressed_int(f);
  for (i = 0; i < num_entries; i++) {
    fp = ftell(f);
    type = fgetc(f);
    if (type == 0) {
      if (fgets(buffer, sizeof(buffer), f) == NULL)
        return 1;
      fseek(f, fp + strlen(buffer) + 2, SEEK_SET);
      fread(&fp, 4, 1, f);
      if (stricmp(buffer, target))
        continue;
      fseek(f, fp, SEEK_SET);
      if (strchr(path, '>') == NULL)
        return 0;
      strcpy(path, strchr(config_path, '>') + 2);
      return seek_config_path(f, path);
    } else if (type == 1) {
      type = fgetc(f);
      if (fgets(buffer, sizeof(buffer), f) == NULL)
        return 1;
      if (stricmp(buffer, target) == 0) {
        fseek(f, fp, SEEK_SET);
        return 0;
      }
      fseek(f, fp + strlen(buffer) + 3, SEEK_SET);
      if (type == 0)
        while (fgetc(f) != 0)
          ;
      else
        fseek(f, 4, SEEK_CUR);
    } else if (type == 2) {
      if (fgets(buffer, sizeof(buffer), f) == NULL)
        return 1;
      if (stricmp(buffer, target) == 0) {
        fseek(f, fp, SEEK_SET);
        return 0;
      }
      fseek(f, fp + strlen(buffer) + 2, SEEK_SET);
      skip_array(f);
    } else {
      while (fgetc(f) != 0)
        ;
    }
  }
  return -1;
}
```