Jan 12, 2006 #1 Vovin Programmer Aug 24, 2003 63 GB Hi, does anyone have a small elegant piece of code (in C) that recursively remove files from directories. Thanks.
Hi, does anyone have a small elegant piece of code (in C) that recursively remove files from directories. Thanks.
Jan 12, 2006 #2 ArkM IS-IT--Management Oct 21, 2002 1,819 RU Alas, (recursive) directory scanning (to remove files or what else) is OS-dependent operation. No such functions in C Standard Library... Upvote 0 Downvote
Alas, (recursive) directory scanning (to remove files or what else) is OS-dependent operation. No such functions in C Standard Library...
Jan 12, 2006 Thread starter #3 Vovin Programmer Aug 24, 2003 63 GB Thanks ArkM, I managed to cobble something together that did the job. Upvote 0 Downvote
Jan 13, 2006 #4 PaulCaswell Programmer Feb 2, 2005 1 GB Be warned. Deletion of files DURING your directory scan CAN make the directory scan skip a file. You may find some files being left behind. Paul Upvote 0 Downvote
Be warned. Deletion of files DURING your directory scan CAN make the directory scan skip a file. You may find some files being left behind. Paul