// File: /workspace/github_c_makefile_star2_O0/justy989[P]ce/ce_commands.c
// Function: open_file_in_dir_recursively
static void open_file_in_dir_recursively(char* path, char* match, CeApp_t* app, CeView_t* view){
     CeListDirResult_t list_dir_result = ce_list_dir(path);

#if defined(PLATFORM_WINDOWS)
     int64_t path_len = strnlen(path, MAX_PATH_LEN);
     if(path_len > 0 && path_len < MAX_PATH_LEN){
         if(path[path_len - 1] == CE_CURRENT_DIR_SEARCH){
             path[path_len - 1] = '.';
         }
     }
#endif

     for(int64_t i = 0; i < list_dir_result.count; i++){
          if(list_dir_result.is_directories[i] &&
             strcmp(list_dir_result.filenames[i], ".") != 0 &&
             strcmp(list_dir_result.filenames[i], "..") != 0){
               char next_dir[MAX_PATH_LEN];
               snprintf(next_dir, MAX_PATH_LEN, "%s%c%s%c%c", path, CE_PATH_SEPARATOR, list_dir_result.filenames[i],
                        CE_PATH_SEPARATOR, CE_CURRENT_DIR_SEARCH);
               open_file_in_dir_recursively(next_dir, match, app, view);
          }else if(strcmp(list_dir_result.filenames[i], match) == 0){
               char full_path[MAX_PATH_LEN];
               snprintf(full_path, MAX_PATH_LEN, "%s%c%s", path, CE_PATH_SEPARATOR, list_dir_result.filenames[i]);
               if(load_file_into_view(&app->buffer_node_head, view, &app->config_options, &app->vim,
                                   true, full_path)){
                    ce_clangd_file_open(&app->clangd, app->buffer_node_head->buffer);
               }
          }
     }
     ce_free_list_dir_result(&list_dir_result);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x850, %rsp            # imm = 0x850
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rsi
leaq -0x38(%rbp), %rdi
callq 0x12a50
movq $0x0, -0x40(%rbp)
movq -0x40(%rbp), %rax
cmpq -0x38(%rbp), %rax
jge 0x22013
movq -0x28(%rbp), %rax
movq -0x40(%rbp), %rcx
testb $0x1, (%rax,%rcx)
je 0x21f56
movq -0x30(%rbp), %rax
movq -0x40(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x22434(%rip), %rsi     # 0x44307
callq 0xd370
cmpl $0x0, %eax
je 0x21f56
movq -0x30(%rbp), %rax
movq -0x40(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x22416(%rip), %rsi     # 0x44306
callq 0xd370
cmpl $0x0, %eax
je 0x21f56
leaq -0x440(%rbp), %rdi
movq -0x8(%rbp), %rcx
movq -0x30(%rbp), %rax
movq -0x40(%rbp), %rdx
movq (%rax,%rdx,8), %r9
movl $0x400, %esi            # imm = 0x400
leaq 0x22644(%rip), %rdx     # 0x44561
movl $0x2f, %r8d
movl $0x2f, (%rsp)
movl $0x2e, 0x8(%rsp)
movb $0x0, %al
callq 0xd250
leaq -0x440(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
callq 0x21e70
jmp 0x22000
movq -0x30(%rbp), %rax
movq -0x40(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
movq -0x10(%rbp), %rsi
callq 0xd370
cmpl $0x0, %eax
jne 0x21ffe
leaq -0x840(%rbp), %rdi
movq -0x8(%rbp), %rcx
movq -0x30(%rbp), %rax
movq -0x40(%rbp), %rdx
movq (%rax,%rdx,8), %r9
movl $0x400, %esi            # imm = 0x400
leaq 0x208c9(%rip), %rdx     # 0x42860
movl $0x2f, %r8d
movb $0x0, %al
callq 0xd250
movq -0x18(%rbp), %rdi
addq $0x2828, %rdi           # imm = 0x2828
movq -0x20(%rbp), %rsi
movq -0x18(%rbp), %rdx
addq $0x1a50, %rdx           # imm = 0x1A50
movq -0x18(%rbp), %rcx
addq $0x20, %rcx
leaq -0x840(%rbp), %r9
movl $0x1, %r8d
callq 0x14420
cmpq $0x0, %rax
je 0x21ffc
movq -0x18(%rbp), %rdi
addq $0x2cd0, %rdi           # imm = 0x2CD0
movq -0x18(%rbp), %rax
movq 0x2828(%rax), %rax
movq (%rax), %rsi
callq 0x1a760
jmp 0x21ffe
jmp 0x22000
jmp 0x22002
movq -0x40(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x21ea0
leaq -0x38(%rbp), %rdi
callq 0x12b90
addq $0x850, %rsp            # imm = 0x850
popq %rbp
retq
nopw %cs:(%rax,%rax)