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

```asm
<_utctime_to_ulong>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x70,%rsp
  mov    %rdi,-0x58(%rbp)
  mov    %rsi,-0x60(%rbp)
  mov    %edx,-0x64(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    -0x60(%rbp),%rax
  mov    %rax,-0x40(%rbp)
  mov    -0x64(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  mov    %rax,-0x38(%rbp)
  jmp    L57
L0:
  addq   $0x1,-0x40(%rbp)
L57:
  mov    -0x40(%rbp),%rax
  cmp    -0x38(%rbp),%rax
  jae    L122
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2f,%al
  jle    L122
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x39,%al
  jle    L0
L122:
  cmpl   $0x11,-0x64(%rbp)
  jg     L64
  mov    -0x40(%rbp),%rax
  cmp    -0x38(%rbp),%rax
  jae    L116
  mov    -0x60(%rbp),%rax
  add    $0xa,%rax
  cmp    %rax,-0x40(%rbp)
  jb     L64
L116:
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5a,%al
  je     L143
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2b,%al
  je     L143
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2d,%al
  jne    L64
L143:
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5a,%al
  jne    L236
  mov    -0x40(%rbp),%rax
  add    $0x1,%rax
  cmp    %rax,-0x38(%rbp)
  jne    L64
L236:
  mov    -0x40(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x2f,%al
  jg     L31
  mov    -0x40(%rbp),%rax
  add    $0x5,%rax
  cmp    %rax,-0x38(%rbp)
  je     L31
L64:
  mov    $0xffffffff,%eax
  jmp    L206
L31:
  lea    -0x30(%rbp),%rax
  mov    $0x20,%edx
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <memset@plt>
  mov    -0x64(%rbp),%eax
  cltq
  add    $0x2,%rax
  cmp    $0x20,%rax
  jbe    L238
  mov    $0xffffffff,%eax
  jmp    L206
L238:
  mov    -0x60(%rbp),%rax
  mov    $0x2,%esi
  mov    %rax,%rdi
  call   <get_num@plt>
  mov    %eax,-0x48(%rbp)
  cmpl   $0x0,-0x48(%rbp)
  jns    L222
  mov    $0xffffffff,%eax
  jmp    L206
L222:
  cmpl   $0x31,-0x48(%rbp)
  jg     L163
  lea    -0x30(%rbp),%rax
  lea    D13(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L203
L163:
  lea    -0x30(%rbp),%rax
  lea    D19(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
L203:
  mov    -0x64(%rbp),%edx
  mov    -0x60(%rbp),%rax
  lea    -0x30(%rbp),%rcx
  add    $0x2,%rcx
  mov    %rax,%rsi
  mov    %rcx,%rdi
  call   <memcpy@plt>
  mov    -0x64(%rbp),%eax
  lea    0x2(%rax),%edx
  lea    -0x30(%rbp),%rcx
  mov    -0x58(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <_gentime_to_ulong@plt>
  mov    %eax,-0x44(%rbp)
  cmpl   $0x0,-0x44(%rbp)
  jg     L189
  mov    -0x44(%rbp),%eax
  jmp    L206
L189:
  mov    -0x44(%rbp),%eax
  sub    $0x2,%eax
L206:
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L16
  call   <__stack_chk_fail@plt>
L16:
  leave
  ret
```

tool_calls: name: read_data
arguments: label: D13
data_type: string
name: read_data
arguments: label: D19
data_type: string

tool: D13: 20

tool: D19: 19

assistant: ```c
int _utctime_to_ulong(int64_t *valp, char *fromp, int lth) {
  int yr;
  char *b, *ep;
  for (b = fromp, ep = &fromp[lth]; b < ep && *b >= '0' && *b <= '9'; b++)
    ;
  if (lth > 17 || (b < ep && b < &fromp[(((((0 + 2) + 2) + 2) + 2) + 2)]) || (*b != 'Z' && *b != '+' && *b != '-') || (*b == 'Z' && ep != &b[1]) || (*b < '0' && ep != &b[(1 + 2) + 2]))
    return -1;
  char genfrom[32];
  memset(genfrom, 0, 32);
  if ((size_t)lth + 2 > sizeof(genfrom))
    return -1;
  yr = (int)get_num(&fromp[0], 2);
  if (yr < 0)
    return -1;
  if (yr < 50)
    strcpy(genfrom, "20");
  else
    strcpy(genfrom, "19");
  memcpy(&genfrom[2], fromp, lth);
  int ansr = _gentime_to_ulong(valp, genfrom, lth + 2);
  if (ansr <= 0)
    return ansr;
  return ansr - 2;
}
```