/*FUNCTION*/ int hook_rmdir(pExecuteObject pEo, char *pszDirectoryName ){ /*noverbatim CUT*/ return file_rmdir(pszDirectoryName); }
int delete_files(char *name) { char tmp_name[CCHMAXPATHCOMP]; struct flist_root root; FILE_COUNT curfile; flist_init(&root, FCLIM_DELETION, FL_STANDARD); if(flist_add_files(&root, NULL, name, 1, 0, FETCH_FILES, NULL)) return(1); for(curfile=0; curfile<root.files; curfile++) { flist_retrieve(tmp_name, NULL, &root, curfile); msg_cprintf(0, M_DELETING, tmp_name); if(is_directory(tmp_name)?file_rmdir(tmp_name):file_unlink(tmp_name)) msg_cprintf(H_ERR, M_CANT_DELETE, tmp_name); } flist_cleanup(&root); return(0); }
int sys_rmdir(char *path) { return file_rmdir(path); }