user: Converte this assembly snippet into its equivalent C code:

```asm
<get_mime_type>:
  endbr64
  push   %r12
  mov    $0x2e,%esi
  call   <strrchr@plt>
  mov    %rax,%r12
  test   %rax,%rax
  je     L74
  lea    D161(%rip),%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L125
L153:
  lea    D3(%rip),%r12
L74:
  mov    %r12,%rax
  pop    %r12
  ret
  nopl   0x0(%rax)
L125:
  lea    D73(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L153
  lea    D91(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  jne    L181
L68:
  lea    D101(%rip),%r12
  mov    %r12,%rax
  pop    %r12
  ret
  nopl   (%rax)
L181:
  lea    D171(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L68
  lea    D59(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L157
  lea    D4(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L67
  lea    D39(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L100
  lea    D126(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L82
  lea    D5(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L119
  lea    D29(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L22
  lea    D45(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L174
  lea    D28(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  test   %rax,%rax
  je     L174
  mov    %r12,%rdi
  lea    D226(%rip),%rsi
  lea    D66(%rip),%r12
  call   <strcmp@plt>
  test   %rax,%rax
  mov    $0x0,%eax
  cmovne %rax,%r12
  jmp    L74
  nop
L157:
  lea    D34(%rip),%r12
  jmp    L74
  nopl   0x0(%rax)
L67:
  lea    D98(%rip),%r12
  jmp    L74
L100:
  lea    D110(%rip),%r12
  jmp    L74
L82:
  lea    D92(%rip),%r12
  jmp    L74
L119:
  lea    D21(%rip),%r12
  jmp    L74
L22:
  lea    D76(%rip),%r12
  jmp    L74
L174:
  lea    D135(%rip),%r12
  jmp    L74
```

tool_calls: name: parse_data
arguments: data_label: D161
type_guessed: string
name: parse_data
arguments: data_label: D3
type_guessed: string
name: parse_data
arguments: data_label: D73
type_guessed: string
name: parse_data
arguments: data_label: D91
type_guessed: string
name: parse_data
arguments: data_label: D101
type_guessed: string
name: parse_data
arguments: data_label: D171
type_guessed: string
name: parse_data
arguments: data_label: D59
type_guessed: string
name: parse_data
arguments: data_label: D4
type_guessed: string
name: parse_data
arguments: data_label: D39
type_guessed: string
name: parse_data
arguments: data_label: D126
type_guessed: string
name: parse_data
arguments: data_label: D5
type_guessed: string
name: parse_data
arguments: data_label: D29
type_guessed: string
name: parse_data
arguments: data_label: D45
type_guessed: string
name: parse_data
arguments: data_label: D28
type_guessed: string
name: parse_data
arguments: data_label: D226
type_guessed: string
name: parse_data
arguments: data_label: D66
type_guessed: string
name: parse_data
arguments: data_label: D34
type_guessed: string
name: parse_data
arguments: data_label: D98
type_guessed: string
name: parse_data
arguments: data_label: D110
type_guessed: string
name: parse_data
arguments: data_label: D92
type_guessed: string
name: parse_data
arguments: data_label: D21
type_guessed: string
name: parse_data
arguments: data_label: D76
type_guessed: string
name: parse_data
arguments: data_label: D135
type_guessed: string

tool: D161: .html

tool: D3: text/html

tool: D73: .htm

tool: D91: .jpg

tool: D101: image/jpeg

tool: D171: .jpeg

tool: D59: .gif

tool: D4: .png

tool: D39: .css

tool: D126: .au

tool: D5: .wav

tool: D29: .avi

tool: D45: .mpeg

tool: D28: .mpg

tool: D226: .mp3

tool: D66: audio/mpeg

tool: D34: image/gif

tool: D98: image/png

tool: D110: text/css

tool: D92: audio/basic

tool: D21: audio/wav

tool: D76: video/x-msvideo

tool: D135: video/mpeg

assistant: ```c
char *get_mime_type(char *name) {
  char *ext = strrchr(name, '.');
  if (!ext)
    return NULL;
  if (strcmp(ext, ".html") == 0 || strcmp(ext, ".htm") == 0)
    return "text/html";
  if (strcmp(ext, ".jpg") == 0 || strcmp(ext, ".jpeg") == 0)
    return "image/jpeg";
  if (strcmp(ext, ".gif") == 0)
    return "image/gif";
  if (strcmp(ext, ".png") == 0)
    return "image/png";
  if (strcmp(ext, ".css") == 0)
    return "text/css";
  if (strcmp(ext, ".au") == 0)
    return "audio/basic";
  if (strcmp(ext, ".wav") == 0)
    return "audio/wav";
  if (strcmp(ext, ".avi") == 0)
    return "video/x-msvideo";
  if (strcmp(ext, ".mpeg") == 0 || strcmp(ext, ".mpg") == 0)
    return "video/mpeg";
  if (strcmp(ext, ".mp3") == 0)
    return "audio/mpeg";
  return NULL;
}
```