Opened 15 years ago

Closed 15 years ago

#342 closed defect (fixed)

Error deleting directory:

Reported by: Peter Johansson Owned by: Peter Johansson
Priority: minor Milestone: svndigest 0.6.6
Component: core Version: 0.6.5
Keywords: Cc:


Using the --force option I get an error when the directory to be removed is a symbolic link.

svndigest gives a warning message

Error deleting directory: /home/peter/svndigest_output/pandai

after which it goes on and writes the output (in the directory that wasn't deleted).

If it wasn't for the error message I would probably not have noticed this because the output looks fine, so the bug is not very severe.

Change History (4)

comment:1 Changed 15 years ago by Peter Johansson

(In [680]) refs #342 and #343. I think this fixes the issue but need to test it (and perhaps add tests) to be sure. I changed rmdirhier to also work on non-dirs. The name, rmdirhier, is perhaps not so descriptive anymore but I prefered changing that function rather than duplicating imilar code elsewhere. I also changed the behavior of rmdirhier in that links are no longer followed but only removed, i.e., a symlink pointing to a dir is only deleted (without deleting the daughter nodes).

comment:2 Changed 15 years ago by Peter Johansson

(In [682]) refs #342 and #343 - commit in right branch

comment:3 Changed 15 years ago by Peter Johansson

Owner: changed from Jari Häkkinen to Peter Johansson
Status: newassigned

comment:4 Changed 15 years ago by Peter Johansson

Resolution: fixed
Status: assignedclosed

Tested that svndigest deletes the symlink both if the referenced node is file and dir. Including this in the tests is tricky, so is better performed in trunk. Perhaps it would be useful to have some machinery to create tests that call binary, but in this case it is the evaluation that is tricky.

Note: See TracTickets for help on using tickets.