user: 这段汇编代码用C语言表示是什么样的:

```asm
<ether_line>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  mov    %rsi,%r13
  push   %r12
  xor    %r12d,%r12d
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %rdx,0x8(%rsp)
L101:
  movsbl 0x0(%rbp),%edi
  call   <_tolower@plt>
  lea    -0x30(%rax),%edx
  cmp    $0x9,%dl
  jbe    L90
  lea    -0x61(%rax),%edx
  cmp    $0x5,%dl
  ja     L116
L90:
  movsbl %al,%ebx
  mov    %ebx,%edi
  call   <isdigit@plt>
  movsbl 0x1(%rbp),%edi
  mov    %rax,%r8
  lea    -0x30(%rbx),%eax
  sub    $0x57,%ebx
  test   %r8,%r8
  cmove  %ebx,%eax
  mov    %eax,%r15d
  call   <_tolower@plt>
  cmp    $0x4,%r12
  movsbl %al,%ebx
  setbe  %cl
  cmp    $0x3a,%bl
  je     L195
  test   %cl,%cl
  je     L195
L79:
  lea    -0x30(%rbx),%eax
  lea    0x2(%rbp),%r14
  cmp    $0x9,%al
  jbe    L63
  lea    -0x61(%rbx),%eax
  cmp    $0x5,%al
  ja     L116
L63:
  mov    %ebx,%edi
  mov    %cl,0x7(%rsp)
  shl    $0x4,%r15d
  call   <isdigit@plt>
  mov    %rax,%r8
  lea    -0x30(%rbx),%eax
  sub    $0x57,%ebx
  test   %r8,%r8
  cmovne %eax,%ebx
  add    %ebx,%r15d
  movzbl 0x2(%rbp),%ebx
  cmp    $0x3a,%bl
  je     L196
  movzbl 0x7(%rsp),%ecx
  test   %cl,%cl
  jne    L116
L196:
  mov    0x0(%r13),%rax
  mov    %r14,%rbp
  mov    %r15b,(%rax,%r12,1)
  test   %bl,%bl
  jne    L18
L22:
  add    $0x1,%r12
  cmp    $0x6,%r12
  jne    L101
  mov    $0x23,%esi
  mov    %rbp,%rdi
  call   <strchr@plt>
  mov    %rax,%rbx
  test   %rax,%rax
  je     L32
L35:
  cmp    %rbx,%rbp
  jb     L52
  jmp    L12
  nopl   0x0(%rax,%rax,1)
L92:
  sub    $0x1,%rbx
  cmp    %rbx,%rbp
  je     L116
L52:
  movsbl -0x1(%rbx),%edi
  call   <isspace@plt>
  test   %rax,%rax
  jne    L92
L12:
  cmp    %rbp,%rbx
  je     L116
  mov    0x8(%rsp),%r14
  sub    %rbp,%rbx
  mov    %rbp,%rsi
  mov    %ebx,%edx
  mov    %r14,%rdi
  call   <memcpy@plt>
  movb   $0x0,(%r14,%rbx,1)
  add    $0x18,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nop
L195:
  mov    %cl,0x7(%rsp)
  lea    0x1(%rbp),%r14
  cmp    $0x5,%r12
  jne    L196
  test   %bl,%bl
  je     L196
  movsbl %bl,%edi
  call   <isspace@plt>
  movzbl 0x7(%rsp),%ecx
  test   %rax,%rax
  je     L79
  mov    0x0(%r13),%rax
  mov    %r15b,0x5(%rax)
  nopl   0x0(%rax,%rax,1)
L18:
  lea    0x1(%r14),%rbp
  jmp    L22
  nopl   0x0(%rax)
L116:
  add    $0x18,%rsp
  mov    $0xffffffff,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L32:
  mov    %rbp,%rdi
  call   <strlen@plt>
  movslq %eax,%rbx
  add    %rbp,%rbx
  jmp    L35
```

assistant: ```c
int ether_line(const char *line, struct ether_addr *addr, char *hostname) {
  size_t cnt;
  char *cp;
  for (cnt = 0; cnt < 6; ++cnt) {
    unsigned int number;
    char ch;
    ch = _tolower(*line++);
    if ((ch < '0' || ch > '9') && (ch < 'a' || ch > 'f'))
      return -1;
    number = isdigit(ch) ? (ch - '0') : (ch - 'a' + 10);
    ch = _tolower(*line);
    if ((cnt < 5 && ch != ':') || (cnt == 5 && ch != '\0' && !isspace(ch))) {
      ++line;
      if ((ch < '0' || ch > '9') && (ch < 'a' || ch > 'f'))
        return -1;
      number <<= 4;
      number += isdigit(ch) ? (ch - '0') : (ch - 'a' + 10);
      ch = *line;
      if (cnt < 5 && ch != ':')
        return -1;
    }
    addr->ether_addr_octet[cnt] = (unsigned char)number;
    if (ch != '\0')
      ++line;
  }
  cp = strchr(line, '#');
  if (cp == NULL)
    cp = line + strlen(line);
  while (cp > line && isspace(cp[-1]))
    --cp;
  if (cp == line)
    return -1;
  memcpy(hostname, line, cp - line);
  hostname[cp - line] = '\0';
  return 0;
}
```