user: What is the c source code of the assembly code below:

```asm
<morse2text>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %rdi,%r15
  mov    %rsi,%r13
  mov    %rsi,%rdi
  call   <strlen@plt>
  mov    %rax,%rbx
  lea    0x1(%rax),%r14d
  mov    %r14d,%edi
  call   <malloc@plt>
  mov    %rax,%rbp
  mov    $0x6,%edi
  call   <malloc@plt>
  mov    %rax,%r12
  mov    %r14d,%edi
  call   <malloc@plt>
  mov    %rax,%rdi
  mov    %rax,(%r15)
  lea    D19(%rip),%rsi
  call   <strcpy@plt>
  test   %ebx,%ebx
  jle    L79
  mov    %r13,%rax
  lea    -0x1(%rbx),%edx
  lea    0x1(%r13,%rdx,1),%rdi
  mov    $0x0,%ecx
  jmp    L39
L162:
  movslq %ecx,%rsi
  mov    %dl,0x0(%rbp,%rsi,1)
  lea    0x1(%rcx),%ecx
L130:
  add    $0x1,%rax
  cmp    %rdi,%rax
  je     L45
L39:
  movzbl (%rax),%edx
  lea    -0x2d(%rdx),%esi
  cmp    $0x2,%sil
  jbe    L162
  cmp    $0x20,%dl
  je     L162
  jmp    L130
L79:
  mov    $0x0,%ecx
L45:
  movslq %ecx,%rcx
  movb   $0x0,0x0(%rbp,%rcx,1)
  mov    %rbp,%rdi
  call   <strlen@plt>
  test   %eax,%eax
  jle    L37
  lea    -0x1(%rax),%r14d
  add    $0x2,%r14
  mov    $0x1,%ebx
  mov    $0x0,%ecx
  jmp    L128
L22:
  add    $0x1,%rax
  cmp    %rsi,%rax
  je     L15
L115:
  movzbl (%rax),%edx
  test   $0xdf,%dl
  je     L22
  movslq %ecx,%rdi
  mov    %dl,(%r12,%rdi,1)
  lea    0x1(%rcx),%ecx
  jmp    L22
L167:
  mov    $0x0,%ecx
L15:
  movslq %ecx,%rcx
  movb   $0x0,(%r12,%rcx,1)
  lea    D25(%rip),%rsi
  mov    %r12,%rdi
  call   <strcmp@plt>
  movb   $0x20,0xf(%rsp)
  test   %rax,%rax
  jne    L158
L55:
  mov    (%r15),%r13
  mov    %r13,%rdi
  call   <strlen@plt>
  movsbl 0xf(%rsp),%edx
  lea    0x0(%r13,%rax,1),%rdi
  lea    D9(%rip),%rsi
  call   <sprintf@plt>
  mov    %ebx,%ecx
L97:
  add    $0x1,%rbx
  cmp    %r14,%rbx
  je     L37
L128:
  testb  $0xdf,0x0(%rbp,%rbx,1)
  jne    L97
  lea    -0x1(%rbx),%edx
  cmp    %ecx,%edx
  jl     L167
  movslq %ecx,%rsi
  lea    0x0(%rbp,%rsi,1),%rax
  lea    0x1(%rbp,%rsi,1),%rsi
  sub    %ecx,%edx
  add    %rdx,%rsi
  mov    $0x0,%ecx
  jmp    L115
L158:
  mov    %r12,%rdi
  call   <word2ascii@plt>
  mov    %al,0xf(%rsp)
  jmp    L55
L37:
  mov    %rbp,%rdi
  call   <free@plt>
  test   %r12,%r12
  je     L6
  mov    %r12,%rdi
  call   <free@plt>
L6:
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: read_data
arguments: label: D19
data_type: string
name: read_data
arguments: label: D25
data_type: string
name: read_data
arguments: label: D9
data_type: string

tool: 

tool: D25: /

tool: D9: %c

assistant: ```c
void morse2text(char **text, char *morse) {
  int rc = 0, counter = 0, start = 0, finish = 0, i = 0, j = 0, k = 0, l = 0;
  size_t length = 0, total = 0;
  char chr, ascii;
  char *clean_morse = NULL, *word = NULL;
  length = strlen(morse);
  clean_morse = malloc(sizeof(char) * length + 1);
  word = malloc(sizeof(char) * 5 + 1);
  *text = malloc(sizeof(char) * length + 1);
  strcpy(*text, "");
  for (i = 0, l = (int)length; i < l; i++) {
    chr = morse[i];
    if (chr == '.' || chr == '-' || chr == ' ' || chr == '/') {
      clean_morse[counter++] = chr;
    }
  }
  clean_morse[counter] = '\0';
  length = strlen(clean_morse);
  counter = 0;
  start = 0;
  finish = 0;
  for (i = 0, j = (int)length; i < j; i++) {
    if (clean_morse[i + 1] != ' ' && clean_morse[i + 1] != '\0') {
      finish++;
    } else {
      counter = 0;
      for (k = start, l = finish + 1; k < l; k++) {
        if (clean_morse[k] != ' ' && clean_morse[k] != '\0') {
          word[counter++] = clean_morse[k];
        }
      }
      word[counter] = '\0';
      if (strcmp(word, "/") == 0) {
        ascii = ' ';
      } else {
        ascii = word2ascii(word);
      }
      total = strlen(*text);
      sprintf(*text + total, "%c", ascii);
      start = finish + 1;
      finish = start;
    }
  }
  if (clean_morse) {
    free(clean_morse);
  }
  if (word) {
    free(word);
  }
  if (rc) {
    exit(EXIT_FAILURE);
  }
}
```