user: What would the C source look like for the assembly code provided here:

```asm
<brkcom>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %rdx,-0x28(%rbp)
  mov    %rcx,-0x30(%rbp)
  cmpq   $0x0,-0x18(%rbp)
  jne    L107
  mov    $0x1,%eax
  jmp    L33
L107:
  mov    -0x18(%rbp),%rax
  mov    %rax,-0x8(%rbp)
  mov    -0x30(%rbp),%rax
  movq   $0x0,(%rax)
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x28(%rbp),%rax
  mov    %rdx,(%rax)
  mov    -0x28(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x20(%rbp),%rax
  mov    %rdx,(%rax)
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x28,%al
  jne    L148
  movl   $0x0,-0xc(%rbp)
  jmp    L115
L72:
  addl   $0x1,-0xc(%rbp)
L115:
  mov    -0xc(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  cmp    $0x29,%al
  jne    L72
  mov    -0xc(%rbp),%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    -0x20(%rbp),%rdx
  mov    %rax,(%rdx)
  mov    -0xc(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncpy@plt>
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0xc(%rbp),%eax
  cltq
  sub    $0x1,%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  mov    -0xc(%rbp),%eax
  cltq
  add    $0x1,%rax
  add    %rax,-0x8(%rbp)
L148:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x5b,%al
  jne    L114
  movl   $0x0,-0xc(%rbp)
  jmp    L19
L62:
  addl   $0x1,-0xc(%rbp)
L19:
  mov    -0xc(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  cmp    $0x5d,%al
  jne    L62
  mov    -0xc(%rbp),%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    -0x28(%rbp),%rdx
  mov    %rax,(%rdx)
  mov    -0xc(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    -0x28(%rbp),%rax
  mov    (%rax),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncpy@plt>
  mov    -0x28(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0xc(%rbp),%eax
  cltq
  sub    $0x1,%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  mov    -0xc(%rbp),%eax
  cltq
  add    $0x1,%rax
  add    %rax,-0x8(%rbp)
L114:
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x7b,%al
  jne    L31
  movl   $0x0,-0xc(%rbp)
  jmp    L89
L120:
  addl   $0x1,-0xc(%rbp)
L89:
  mov    -0xc(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x8(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  cmp    $0x7d,%al
  jne    L120
  mov    -0xc(%rbp),%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    -0x30(%rbp),%rdx
  mov    %rax,(%rdx)
  mov    -0xc(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <strncpy@plt>
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0xc(%rbp),%eax
  cltq
  sub    $0x1,%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  mov    -0xc(%rbp),%eax
  cltq
  add    $0x1,%rax
  add    %rax,-0x8(%rbp)
L31:
  mov    -0x20(%rbp),%rax
  mov    (%rax),%rax
  test   %rax,%rax
  jne    L23
  mov    -0x28(%rbp),%rax
  mov    (%rax),%rax
  test   %rax,%rax
  jne    L23
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  test   %rax,%rax
  jne    L23
  mov    $0x2,%eax
  jmp    L33
L23:
  mov    $0x0,%eax
L33:
  leave
  ret
```

assistant: ```c
int brkcom(char *com, char **sin, char **mb, char **me) {
  if (com == NULL)
    return 1;
  char *comp = com;
  int cc;
  *sin = *mb = *me = NULL;
  if (*comp == '(') {
    cc = 0;
    while (*(comp + cc) != ')')
      cc++;
    *sin = malloc(cc);
    strncpy(*sin, comp + 1, cc - 1);
    *(*sin + cc - 1) = '\0';
    comp += cc + 1;
  }
  if (*comp == '[') {
    cc = 0;
    while (*(comp + cc) != ']')
      cc++;
    *mb = malloc(cc);
    strncpy(*mb, comp + 1, cc - 1);
    *(*mb + cc - 1) = '\0';
    comp += cc + 1;
  }
  if (*comp == '{') {
    cc = 0;
    while (*(comp + cc) != '}')
      cc++;
    *me = malloc(cc);
    strncpy(*me, comp + 1, cc - 1);
    *(*me + cc - 1) = '\0';
    comp += cc + 1;
  }
  if (*sin == NULL && *mb == NULL && *me == NULL)
    return 2;
  else
    return 0;
}
```