user: 下面的汇编指令对应的C源代码是什么:

```asm
<RecoverFile>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  sub    $0x28,%rsp
  mov    %rdx,(%rsp)
  mov    %rsi,%rbx
  lea    0x10(%rsp),%rbp
  mov    %edi,%r12d
  mov    %rsi,0x8(%rsp)
  mov    %rbx,%rdi
  mov    %rbp,%rsi
  mov    %rdx,%r15
  mov    %fs:0x28,%rax
  mov    %rax,0x1018(%rsp)
  xor    %eax,%eax
  call   <pathFromFile@plt>
  mov    %rbp,%rdi
  call   <ensurePath@plt>
  mov    $0x1b6,%esi
  mov    %rbx,%rdi
  mov    (%r15),%r14d
  call   <creat@plt>
  mov    %eax,%ebp
  cmp    $0xffffffff,%eax
  je     L1
L19:
  test   %r14d,%r14d
  jle    L96
  lea    0x810(%rsp),%rbx
  lea    D3(%rip),%r13
  jmp    L77
  nopl   0x0(%rax)
L0:
  mov    %r14d,%esi
  mov    %r15d,%edx
  mov    %r13,%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    %r15d,%edx
  mov    %rbx,%rsi
  mov    %ebp,%edi
  call   <write@plt>
  sub    $0x800,%r14d
  test   %r14d,%r14d
  jle    L96
L77:
  mov    $0x800,%edx
  mov    %rbx,%rsi
  mov    %r12d,%edi
  cmp    %edx,%r14d
  cmovle %r14d,%edx
  call   <read@plt>
  mov    %eax,%r15d
  test   %eax,%eax
  jg     L0
L96:
  mov    (%rsp),%rax
  mov    %ebp,%edi
  mov    0xc(%rax),%esi
  call   <fchmod@plt>
  cmp    $0xffffffff,%eax
  je     L109
L18:
  mov    (%rsp),%rax
  mov    %ebp,%edi
  mov    0x4(%rax),%edx
  mov    0x8(%rax),%esi
  call   <fchown@plt>
  cmp    $0xffffffff,%eax
  je     L83
L102:
  mov    %ebp,%edi
  call   <close@plt>
  mov    0x8(%rsp),%rsi
  xor    %eax,%eax
  lea    D21(%rip),%rdi
  call   <printf@plt>
  mov    0x1018(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L105
  add    $0x1028,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L1:
  lea    D17(%rip),%rdi
  call   <perror@plt>
  mov    $0x2,%edi
  call   <exit@plt>
  jmp    L19
  nopl   0x0(%rax,%rax,1)
L83:
  lea    D49(%rip),%rdi
  call   <perror@plt>
  jmp    L102
  cs nopw 0x0(%rax,%rax,1)
L109:
  lea    D32(%rip),%rdi
  call   <perror@plt>
  jmp    L18
L105:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: data_label: D3
type_infered: string
name: unpack_data
arguments: data_label: D21
type_infered: string
name: unpack_data
arguments: data_label: D17
type_infered: string
name: unpack_data
arguments: data_label: D49
type_infered: string
name: unpack_data
arguments: data_label: D32
type_infered: string

tool: D3: %i - %i


tool: D21: recovered file %s


tool: D17: Backuptarget: 

tool: D49: chown

tool: D32: fchmod

assistant: ```c
void RecoverFile(int bfd, const char *fname, struct stat *inode) {
  char path[2048];
  pathFromFile(fname, &path);
  ensurePath(path);
  int cnt;
  char buf[2048];
  int fileEnd = inode->st_size;
  int targetfd;
  if ((targetfd = creat(fname, 0666)) == -1) {
    perror("Backuptarget: ");
    exit(2);
  }
  while (fileEnd > 0 && (cnt = read(bfd, &buf, (((2048) < (fileEnd)) ? (2048) : (fileEnd)))) > 0) {
    printf("%i - %i\n", fileEnd, cnt);
    write(targetfd, buf, cnt);
    fileEnd -= 2048;
  }
  if (fchmod(targetfd, inode->st_mode) == -1) {
    perror("fchmod");
  }
  if (fchown(targetfd, inode->st_uid, inode->st_gid) == -1) {
    perror("chown");
  }
  close(targetfd);
  printf("recovered file %s\n", fname);
}
```