mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-21 23:09:40 +00:00
Soothe Georg's minor irritation.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@8588 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
12780bf2b6
commit
72b9c5c702
@ -1,3 +1,8 @@
|
||||
2004-04-01 Georg Baum <Georg.Baum@post.rwth-aachen.de>
|
||||
|
||||
* filetools.C (DeleteAllFilesInDir): delete directories with
|
||||
rmdir(), unlink() does not work
|
||||
|
||||
2004-03-27 Angus Leeming <leeming@lyx.org>
|
||||
|
||||
* forkedcontr.C (child_handler): squash warning about a
|
||||
|
@ -436,9 +436,11 @@ int DeleteAllFilesInDir(string const & path)
|
||||
|
||||
bool deleted = true;
|
||||
FileInfo fi(unlinkpath);
|
||||
if (fi.isOK() && fi.isDir())
|
||||
if (fi.isOK() && fi.isDir()) {
|
||||
deleted = (DeleteAllFilesInDir(unlinkpath) == 0);
|
||||
deleted &= (unlink(unlinkpath) == 0);
|
||||
deleted &= (rmdir(unlinkpath) == 0);
|
||||
} else
|
||||
deleted &= (unlink(unlinkpath) == 0);
|
||||
if (!deleted)
|
||||
return_value = -1;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user