Lines Matching refs:shell_current_path
18 char *shell_current_path = NULL; variable
45 int cwd_len = strlen(shell_current_path); in get_target_filepath()
54 strncpy(file_path, shell_current_path, cwd_len); in get_target_filepath()
124 int current_dir_len = strlen(shell_current_path); in shell_cmd_cd()
139 if (!strcmp("/", shell_current_path)) in shell_cmd_cd()
146 if (shell_current_path[index] == '/') in shell_cmd_cd()
149 shell_current_path[index] = '\0'; in shell_cmd_cd()
177 free(shell_current_path); in shell_cmd_cd()
179 shell_current_path = new_path; in shell_cmd_cd()
181 shell_current_path[dest_len] = '\0'; in shell_cmd_cd()
208 strncpy(new_path, shell_current_path, current_dir_len); in shell_cmd_cd()
216 free(shell_current_path); in shell_cmd_cd()
219 shell_current_path = new_path; in shell_cmd_cd()
246 struct DIR *dir = opendir(shell_current_path); in shell_cmd_ls()
291 if (shell_current_path) in shell_cmd_pwd()
292 printf("%s\n", shell_current_path); in shell_cmd_pwd()