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

```asm
<print_bin>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0xa8,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x98(%rsp)
  xor    %eax,%eax
  test   %rdx,%rdx
  je     L45
  mov    %rdi,%rbp
  mov    %rsi,%r14
  mov    %rdx,%r13
  mov    %rcx,%rbx
  test   %r8d,%r8d
  jle    L19
  mov    $0x80,%eax
  lea    0x10(%rsp),%r15
  mov    $0x20,%esi
  cmp    %eax,%r8d
  mov    %r15,%rdi
  cmovle %r8d,%eax
  mov    %eax,%r12d
  mov    %eax,%edx
  call   <memset@plt>
  mov    %r12d,%edx
  mov    %r15,%rsi
  mov    %rbp,%rdi
  call   <BIO_write@plt>
  test   %rax,%rax
  jle    L41
L64:
  xor    %eax,%eax
  mov    %r14,%rdx
  lea    D48(%rip),%rsi
  mov    %rbp,%rdi
  call   <BIO_printf@plt>
  test   %rax,%rax
  jle    L41
  movabs $0xeeeeeeeeeeeeeeef,%r15
  xor    %r14d,%r14d
  jmp    L94
  nopl   0x0(%rax)
L32:
  add    $0x1,%r14
  lea    D11(%rip),%rax
  mov    %rbp,%rdi
  cmp    %rbx,%r14
  lea    D5(%rip),%rcx
  movzbl -0x1(%r13,%r14,1),%edx
  lea    D4(%rip),%rsi
  cmove  %rax,%rcx
  xor    %eax,%eax
  call   <BIO_printf@plt>
  test   %rax,%rax
  jle    L41
L94:
  cmp    %rbx,%r14
  je     L66
  movabs $0x1111111111111111,%rdi
  mov    %r14,%rax
  imul   %r15,%rax
  cmp    %rdi,%rax
  ja     L32
  lea    0x4(%r12),%edx
  lea    0x10(%rsp),%r9
  mov    $0x20,%esi
  movb   $0xa,0x10(%rsp)
  lea    0x11(%rsp),%rdi
  mov    %r9,0x8(%rsp)
  call   <memset@plt>
  mov    0x8(%rsp),%rsi
  lea    0x5(%r12),%edx
  mov    %rbp,%rdi
  call   <BIO_write@plt>
  test   %rax,%rax
  jg     L32
  nopw   0x0(%rax,%rax,1)
L41:
  xor    %eax,%eax
L53:
  mov    0x98(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L54
  add    $0xa8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nop
L19:
  xor    %r12d,%r12d
  jmp    L64
  nopl   0x0(%rax,%rax,1)
L66:
  mov    $0x1,%edx
  lea    D32(%rip),%rsi
  mov    %rbp,%rdi
  call   <BIO_write@plt>
  test   %rax,%rax
  setg   %al
  movzbl %al,%eax
  jmp    L53
  nop
L45:
  mov    $0x1,%eax
  jmp    L53
L54:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: tag: D48
datatype: string
name: parse_data
arguments: tag: D11
datatype: string
name: parse_data
arguments: tag: D5
datatype: string
name: parse_data
arguments: tag: D4
datatype: string
name: parse_data
arguments: tag: D32
datatype: string

tool: D48: %s

tool: 

tool: D5: :

tool: D4: %02x%s

tool: D32: 


assistant: ```c
int print_bin(BIO *fp, const char *name, const unsigned char *buf, size_t len, int off) {
  size_t i;
  char str[128];
  if (buf == NULL)
    return 1;
  if (off > 0) {
    if (off > 128)
      off = 128;
    memset(str, ' ', off);
    if (BIO_write(fp, str, off) <= 0)
      return 0;
  } else {
    off = 0;
  }
  if (BIO_printf(fp, "%s", name) <= 0)
    return 0;
  for (i = 0; i < len; i++) {
    if ((i % 15) == 0) {
      str[0] = '\n';
      memset(&(str[1]), ' ', off + 4);
      if (BIO_write(fp, str, off + 1 + 4) <= 0)
        return 0;
    }
    if (BIO_printf(fp, "%02x%s", buf[i], ((i + 1) == len) ? "" : ":") <= 0)
      return 0;
  }
  if (BIO_write(fp, "\n", 1) <= 0)
    return 0;
  return 1;
}
```