// File: /workspace/github_cpp_makefile_star2_O3/solaldunckel[P]webserv/srcs/Utils/File.cpp
// Function: File::parse_match()
void File::parse_match() {
  DIR *dir;
  struct dirent *ent;

  std::string path = path_.substr(0, path_.find_last_of("/"));
  if (!matches_.empty())
    matches_.clear();
  if ((dir = opendir(path.c_str()))) {
    while ((ent = readdir(dir))) {
      std::string name(ent->d_name);
      if (file_name_full_ != name && !name.find(file_name_)
        && name.find(mime_ext_) != std::string::npos) {
        matches_.push_back(ent->d_name);
      }
    }
    closedir(dir);
  } else {
    Log.print(DEBUG, "opendir : " + std::string(strerror(errno)) + " of " + path_, RED, true);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rdi, %rbx
leaq 0x80(%rdi), %r14
leaq 0x65cc(%rip), %rsi      # 0x25594
movl $0x1, %ecx
movq %r14, %rdi
movq $-0x1, %rdx
callq 0x4870
leaq 0xb8(%rsp), %rdi
movq %r14, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0x4490
leaq 0x68(%rbx), %r14
movq 0x68(%rbx), %rsi
cmpq 0x70(%rbx), %rsi
je 0x1f007
movq %r14, %rdi
callq 0x6cfe
movq 0xb8(%rsp), %rdi
callq 0x4640
testq %rax, %rax
je 0x1f141
movq %rax, %r15
movq %r14, 0x70(%rsp)
leaq 0x10(%rsp), %r12
leaq 0x30(%rsp), %r14
movq %r15, %rdi
callq 0x4670
movq %rax, %r13
testq %rax, %rax
je 0x1f134
leaq 0x13(%r13), %rbp
leaq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
movq %rbp, %rdi
callq 0x4190
leaq (%rax,%r13), %rdx
addq $0x13, %rdx
movq %r12, %rdi
movq %rbp, %rsi
callq 0x579e
movq 0x30(%rbx), %rdx
cmpq 0x18(%rsp), %rdx
jne 0x1f08e
testq %rdx, %rdx
je 0x1f0a5
movq 0x10(%rsp), %rsi
movq 0x28(%rbx), %rdi
callq 0x4480
testl %eax, %eax
je 0x1f0a5
movq 0x8(%rbx), %rsi
movq 0x10(%rbx), %rcx
movq %r12, %rdi
xorl %edx, %edx
callq 0x4780
testq %rax, %rax
je 0x1f0ca
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x1f02f
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f02f
movq 0x48(%rbx), %rsi
movq 0x50(%rbx), %rcx
movq %r12, %rdi
xorl %edx, %edx
callq 0x4780
cmpq $-0x1, %rax
je 0x1f0a5
leaq 0x40(%rsp), %rax
movq %rax, 0x30(%rsp)
movq %rbp, %rdi
callq 0x4190
leaq (%rax,%rbp), %rdx
movq %r14, %r13
movq %r14, %rdi
movq %rbp, %rsi
callq 0x579e
movq 0x70(%rsp), %rdi
movq %r13, %rsi
callq 0x7322
movq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0x1f0a5
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f0a5
movq %r15, %rdi
callq 0x46c0
jmp 0x1f340
callq 0x4050
movl (%rax), %edi
callq 0x4140
leaq 0x98(%rsp), %rdi
leaq 0xf(%rsp), %rdx
movq %rax, %rsi
callq 0x5712
leaq 0x6db8(%rip), %rcx      # 0x25f21
leaq 0x98(%rsp), %rdi
movl $0xa, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x44d0
leaq 0x40(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x1f1a7
movq %rdx, 0x30(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x40(%rsp)
jmp 0x1f1ae
movups (%rcx), %xmm0
movups %xmm0, (%r14)
movq 0x8(%rax), %rdx
leaq 0x30(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x6ced(%rip), %rsi      # 0x25ebe
callq 0x4840
leaq 0x20(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x1f1fd
movq %rdx, 0x10(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x20(%rsp)
jmp 0x1f204
movups (%rcx), %xmm0
movups %xmm0, (%r15)
movq 0x8(%rax), %rdx
leaq 0x10(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x80(%rbx), %rsi
movq 0x88(%rbx), %rdx
callq 0x4100
leaq 0x60(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x1f25b
movq %rdx, 0x50(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x60(%rsp)
jmp 0x1f263
movups (%rcx), %xmm0
movups %xmm0, (%r12)
movq 0x8(%rax), %rdx
movq %rdx, 0x58(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x88(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x5d92(%rip), %rsi      # 0x25020
leaq 0x5d90(%rip), %rdx      # 0x25025
leaq 0x78(%rsp), %rdi
callq 0x579e
leaq 0x13242(%rip), %rdi     # 0x324e8
leaq 0x50(%rsp), %rdx
leaq 0x78(%rsp), %rcx
movl $0x2, %esi
movl $0x1, %r8d
callq 0x20f32
movq 0x78(%rsp), %rdi
cmpq %r13, %rdi
je 0x1f2da
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x4470
movq 0x50(%rsp), %rdi
cmpq %r12, %rdi
je 0x1f2f1
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x4470
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0x1f308
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4470
movq 0x30(%rsp), %rdi
cmpq %r14, %rdi
je 0x1f31f
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4470
leaq 0xa8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1f340
movq 0xa8(%rsp), %rsi
incq %rsi
callq 0x4470
leaq 0xc8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1f361
movq 0xc8(%rsp), %rsi
incq %rsi
callq 0x4470
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x78(%rsp), %rdi
cmpq %r13, %rdi
je 0x1f395
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f395
movq %rax, %rbx
movq 0x50(%rsp), %rdi
cmpq %r12, %rdi
je 0x1f3b1
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f3b1
movq %rax, %rbx
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0x1f3cd
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f3cd
movq %rax, %rbx
movq 0x30(%rsp), %rdi
cmpq %r14, %rdi
je 0x1f3e9
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f3e9
movq %rax, %rbx
leaq 0xa8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1f44d
movq 0xa8(%rsp), %rsi
jmp 0x1f43e
jmp 0x1f44a
movq %rax, %rbx
movq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0x1f42a
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f42a
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x1f44d
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4470
jmp 0x1f44d
jmp 0x1f44a
movq %rax, %rbx
leaq 0xc8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1f46e
movq 0xc8(%rsp), %rsi
incq %rsi
callq 0x4470
movq %rbx, %rdi
callq 0x4790