diff --git a/wrapper.c b/wrapper.c
index 0bbff56e2c38651b10551d17caeed84e0cc250c8..10a6750795b287beabd50561402ffa8867f3e283 100644 (file)
--- a/wrapper.c
+++ b/wrapper.c
{
return warn_if_unremovable("unlink", file, unlink(file));
}
+
+int rmdir_or_warn(const char *file)
+{
+ return warn_if_unremovable("rmdir", file, rmdir(file));
+}
+
+int remove_or_warn(unsigned int mode, const char *file)
+{
+ return S_ISGITLINK(mode) ? rmdir_or_warn(file) : unlink_or_warn(file);
+}