Lines Matching refs:fullpath

80     char *fullpath = NULL;
98 ret = vfs_normalize_path(shell_working_directory, path, &fullpath);
101 fullpath_bak = fullpath;
102 ret = chdir(fullpath);
112 ret = strncpy_s(shell_working_directory, PATH_MAX, fullpath, strlen(fullpath));
128 char *fullpath = NULL;
144 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
147 ls(fullpath);
148 free(fullpath);
176 char *fullpath = (char *)arg;
180 ini = fopen(fullpath, "r");
216 free(fullpath);
223 char *fullpath = NULL;
235 ret = vfs_normalize_path(shell_working_directory, argv[0], &fullpath);
239 ret = VnodeLookup(fullpath, &vnode, O_RDONLY);
244 free(fullpath);
251 free(fullpath);
258 init_param.auwArgs[0] = (UINTPTR)fullpath;
265 free(fullpath);
302 char *fullpath = NULL;
323 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
332 ret = nfs_mount_ref(argv[1], fullpath, uid, gid);
339 free(fullpath);
349 ret = mount((const char *)NULL, fullpath, filessystemtype, mountfalgs, data);
351 ret = mount(argv[1], fullpath, filessystemtype, mountfalgs, data); /* 3: fs type */
360 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
369 ret = nfs_mount_ref(argv[0], fullpath, uid, gid);
376 free(fullpath);
381 free(fullpath);
389 ret = mount((const char *)NULL, fullpath, argv[2], mountfalgs, data);
391 ret = mount(argv[0], fullpath, argv[2], mountfalgs, data); /* 2: fs type */
400 free(fullpath);
408 char *fullpath = NULL;
421 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
424 target_path = fullpath;
425 cmp_num = strlen(fullpath);
432 free(fullpath);
437 ret = umount(fullpath);
438 free(fullpath);
451 char *fullpath = NULL;
461 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
464 ret = mkdir(fullpath, S_IRWXU | S_IRWXG | S_IRWXO);
468 free(fullpath);
517 char *fullpath = NULL;
529 result = vfs_normalize_path(shell_working_directory, filename, &fullpath);
532 result = statfs(fullpath, &sfs);
533 free(fullpath);
556 char *fullpath = NULL;
566 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
569 fd = open(fullpath, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
570 free(fullpath);
608 /* Get source fullpath. */
633 /* Get dest fullpath. */
732 /* The separator and EOF for a directory fullpath: '/'and '\0' */
741 char *fullpath = NULL;
763 fullpath = (char *)malloc(fullpath_buf_size);
764 if (fullpath == NULL) {
769 ret = snprintf_s(fullpath, fullpath_buf_size, fullpath_buf_size - 1, "%s/%s", pathname, dirent->d_name);
772 free(fullpath);
776 (void)os_shell_cmd_do_rmdir(fullpath);
777 free(fullpath);
848 static int os_wildcard_delete_file_or_dir(const char *fullpath, wildcard_type mark)
854 ret = os_shell_cmd_do_rmdir(fullpath);
857 ret = unlink(fullpath);
860 ret = rmdir(fullpath);
866 PRINTK("%s ", fullpath);
871 PRINTK("%s match successful!delete!\n", fullpath);
877 static char* os_wildcard_split_path(char *fullpath, char **handle, char **wait)
882 int len = strlen(fullpath);
885 if (fullpath[n] == '/') {
887 fullpath[n] = '\0';
888 *wait = fullpath + n + 1;
892 } else if (fullpath[n] == '*' || fullpath[n] == '?') {
894 fullpath[a] = '\0';
896 *handle = fullpath + a + 1;
899 *handle = fullpath + a + 1;
902 return fullpath;
907 static int os_wildcard_extract_directory(char *fullpath, void *dst, wildcard_type mark)
920 f = os_wildcard_split_path(fullpath, &s, &t);
924 ret = os_shell_cmd_do_cp(fullpath, dst);
926 ret = stat(fullpath, &stat_buf);
931 ret = os_wildcard_delete_file_or_dir(fullpath, mark);
1025 /* Get source fullpath. */
1039 /* Get dest fullpath. */
1102 char *fullpath = NULL;
1115 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
1118 if (os_is_containers_wildcard(fullpath)) {
1119 ret = os_wildcard_extract_directory(fullpath, NULL, RM_RECURSIVER);
1121 ret = os_shell_cmd_do_rmdir(fullpath);
1125 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
1128 if (os_is_containers_wildcard(fullpath)) {
1129 ret = os_wildcard_extract_directory(fullpath, NULL, RM_FILE);
1131 ret = unlink(fullpath);
1137 free(fullpath);
1144 char *fullpath = NULL;
1154 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
1157 if (os_is_containers_wildcard(fullpath)) {
1158 ret = os_wildcard_extract_directory(fullpath, NULL, RM_DIR);
1160 ret = rmdir(fullpath);
1163 PRINTK("rmdir %s failed. Error: %s.\n", fullpath, strerror(errno));
1165 free(fullpath);
1240 char *fullpath = NULL;
1265 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
1270 ret = chattr(fullpath, &attr);
1272 free(fullpath);
1277 free(fullpath);
1284 char *fullpath = NULL;
1318 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
1321 ret = chattr(fullpath, &attr);
1323 free(fullpath);
1328 free(fullpath);
1335 char *fullpath = NULL;
1354 ret = vfs_normalize_path(shell_working_directory, filename, &fullpath);
1357 ret = chattr(fullpath, &attr);
1359 free(fullpath);
1364 free(fullpath);