changeset 8703:e07901202df1 HEAD

nfs+maildir: lseek() may also return ESTALE failure, handle it.
author Timo Sirainen <tss@iki.fi>
date Mon, 02 Feb 2009 14:57:33 -0500
parents 8fb251e401e6
children ffcb2fb59c1d
files src/lib-storage/index/maildir/maildir-uidlist.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-storage/index/maildir/maildir-uidlist.c	Mon Feb 02 12:50:27 2009 -0500
+++ b/src/lib-storage/index/maildir/maildir-uidlist.c	Mon Feb 02 14:57:33 2009 -0500
@@ -603,6 +603,10 @@
 		/* the file was updated */
 		fd = uidlist->fd;
 		if (lseek(fd, 0, SEEK_SET) < 0) {
+			if (errno == ESTALE && try_retry) {
+				*retry_r = TRUE;
+				return -1;
+			}
 			mail_storage_set_critical(storage,
 				"lseek(%s) failed: %m", uidlist->path);
 			return -1;