]> git.ipfire.org Git - thirdparty/sarg.git/commit
Don't delete anything from the temporary directory if unsure
authorFrederic Marchal <fmarchal@users.sourceforge.net>
Sun, 12 Jul 2015 17:43:27 +0000 (19:43 +0200)
committerFrederic Marchal <fmarchal@users.sourceforge.net>
Sun, 12 Jul 2015 17:43:27 +0000 (19:43 +0200)
commite9390734d9ba81d9c0ed5a3cb992f684b26a022e
tree8b4a7b3c9c445665b24815c92141e1fa8dba858e
parent22774edd6523d566f539f4f633a6f276bfbd6224
Don't delete anything from the temporary directory if unsure

Sarg must delete any previous stray temporary directory before filling it
with the current log data. But sarg must not just delete any directory and
its content if it isn't ours. Therefore, sarg check the directory content
to make sure that it only contains files that may belong to us.

There was an error in that routine. It would recursively delete directories
found in the candidate temporary directory before making sure the whole
directory content can be safely deleted.

This problem is fixed here.
util.c