summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib-src/movemail.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib-src/movemail.c b/lib-src/movemail.c
index 7f9026d89c7..eeb253a585e 100644
--- a/lib-src/movemail.c
+++ b/lib-src/movemail.c
@@ -341,6 +341,13 @@ main (argc, argv)
close (desc);
tem = link (tempname, lockname);
+
+#ifdef EPERM
+ if (tem < 0 && errno == EPERM)
+ fatal ("Unable to create hard link between %s and %s",
+ tempname, lockname);
+#endif
+
unlink (tempname);
if (tem >= 0)
break;