From ab1cdb5d379d6371d38afb8b8413c748fd76b8f7 Mon Sep 17 00:00:00 2001 From: Nalin Dahyabhai Date: Thu, 19 Feb 2009 23:11:41 +0000 Subject: [PATCH] - add a patch to catch out-of-space errors rcp'ing files to NFS destinations --- krb5-trunk-close-err.patch | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 krb5-trunk-close-err.patch diff --git a/krb5-trunk-close-err.patch b/krb5-trunk-close-err.patch new file mode 100644 index 0000000..88db110 --- /dev/null +++ b/krb5-trunk-close-err.patch @@ -0,0 +1,19 @@ +Check for errors returned by close(), which is when we notice out-of-space +errors on NFS. Patch by Tomas Smetana. RT#6399 + +Index: src/appl/bsd/krcp.c +=================================================================== +--- src/appl/bsd/krcp.c (revision 22038) ++++ src/appl/bsd/krcp.c (working copy) +@@ -1115,7 +1115,10 @@ + wrerr++; + if (ftruncate(of, size)) + error("rcp: can't truncate %s: %s\n", nambuf, error_message(errno)); +- (void) close(of); ++ if (close(of) != 0) ++ { ++ error("rcp: error closing %s: %s\n", nambuf, error_message(errno)); ++ } + (void) response(); + if (setimes) { + setimes = 0;