user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<decode_array>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  mov    %rdi,%r12
  mov    %rsi,%rdi
  push   %rbp
  mov    %rsi,%rbp
  push   %rbx
  mov    %rcx,%rbx
  sub    $0x38,%rsp
  mov    %rdx,0x8(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x28(%rsp)
  xor    %eax,%eax
  call   <decoded_dest_size@plt>
  mov    %rax,%r9
  mov    $0xffffffffffffffff,%rax
  cmp    %rbx,%r9
  ja     L1
  lea    0x28(%rsp),%rax
  xor    %r13d,%r13d
  xor    %r14d,%r14d
  mov    %rax,(%rsp)
  xor    %eax,%eax
  test   %rbp,%rbp
  je     L1
L107:
  movslq %r13d,%r9
  movzbl (%r12,%r9,1),%esi
  cmp    $0xa,%sil
  sete   %al
  cmp    $0xd,%sil
  sete   %sil
  or     %sil,%al
  je     L52
  cmp    %r9,%rbp
  lea    0x1(%r13),%eax
  seta   %sil
  cltq
  test   %sil,%sil
  je     L52
  nopl   0x0(%rax,%rax,1)
L64:
  movzbl (%r12,%rax,1),%edi
  mov    %eax,%r13d
  mov    %rax,%r9
  cmp    $0xd,%dil
  sete   %sil
  cmp    $0xa,%dil
  sete   %dil
  or     %edi,%esi
  cmp    %rax,%rbp
  seta   %dil
  add    $0x1,%rax
  test   %dil,%sil
  jne    L64
L52:
  cmp    %rbp,%r9
  je     L137
  lea    0x24(%rsp),%rsi
L9:
  lea    0x1(%r13),%ecx
  movslq %ecx,%rbx
  jmp    L0
  nopl   0x0(%rax)
L44:
  lea    0x1(%rbx),%rax
  cmp    %rbx,%rbp
  jbe    L102
  mov    %rax,%rbx
L0:
  movzbl -0x1(%r12,%rbx,1),%eax
  mov    %ebx,%r13d
  cmp    $0xd,%al
  je     L44
  cmp    $0xa,%al
  je     L44
  mov    %al,(%rsi)
  add    $0x1,%rsi
  cmp    %rsi,(%rsp)
  jne    L9
  movsbl 0x25(%rsp),%r10d
  movsbl 0x24(%rsp),%edi
  lea    0x1(%r14),%eax
  movslq %r14d,%r15
  mov    %eax,0x10(%rsp)
  add    0x8(%rsp),%r15
  mov    %r10d,%esi
  mov    %r10d,0x1c(%rsp)
  call   <decode_base64_pair1@plt>
  mov    %al,(%r15)
  movzbl 0x26(%rsp),%r15d
  cmp    $0x3d,%r15b
  je     L91
  mov    0x1c(%rsp),%edi
  movslq 0x10(%rsp),%rax
  movsbl %r15b,%esi
  add    $0x2,%r14d
  add    0x8(%rsp),%rax
  mov    %rax,0x10(%rsp)
  call   <decode_base64_pair2@plt>
  mov    0x10(%rsp),%rdx
  mov    %al,(%rdx)
L76:
  movzbl 0x27(%rsp),%eax
  cmp    $0x3d,%al
  je     L106
  lea    0x1(%r14),%edx
  mov    0x8(%rsp),%rcx
  movsbl %al,%esi
  movsbl %r15b,%edi
  mov    %edx,0x10(%rsp)
  movslq %r14d,%rdx
  lea    (%rcx,%rdx,1),%r14
  call   <decode_base64_pair3@plt>
  mov    %al,(%r14)
  mov    0x10(%rsp),%r14d
L106:
  cmp    %rbx,%rbp
  ja     L107
L137:
  movslq %r14d,%rax
  jmp    L1
  xchg   %ax,%ax
L102:
  mov    $0xffffffffffffffff,%rax
L1:
  mov    0x28(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L20
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  cs nopw 0x0(%rax,%rax,1)
L91:
  mov    0x10(%rsp),%r14d
  jmp    L76
L20:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
size_t decode_array(const char *src_array, const size_t src_len, char *dest_array, const size_t dest_size) {
  int cnt = 0;
  char ch[4];
  int i = 0;
  int j = 0;
  if (dest_size < decoded_dest_size(src_len))
    return -1;
  while (i < src_len) {
    while ((src_array[i] == '\r' || src_array[i] == '\n') && i < src_len) {
      ++i;
    }
    if (i == src_len)
      break;
    for (j = 0; j < 4; ++j) {
      do {
        ch[j] = src_array[i++];
      } while ((ch[j] == '\r' || ch[j] == '\n') && i < src_len);
      if (ch[j] == '\r' || ch[j] == '\n')
        return -1;
    }
    dest_array[cnt++] = decode_base64_pair1(ch[0], ch[1]);
    if (ch[2] != '=')
      dest_array[cnt++] = decode_base64_pair2(ch[1], ch[2]);
    if (ch[3] != '=')
      dest_array[cnt++] = decode_base64_pair3(ch[2], ch[3]);
  }
  return cnt;
}
```