summaryrefslogtreecommitdiff
path: root/devel/ccache/patches
diff options
context:
space:
mode:
authorenami <enami>2002-05-09 01:40:03 +0000
committerenami <enami>2002-05-09 01:40:03 +0000
commit3841b35a295700b016db60d8522a5574d6a6ecd9 (patch)
tree5c5e1fe1f53ac2cfd35440922b2d7a301311f542 /devel/ccache/patches
parent74c0cb151b120943fa253ea95e228e836111fd1d (diff)
downloadpkgsrc-3841b35a295700b016db60d8522a5574d6a6ecd9.tar.gz
Test if close(2) is failed after writing to file. This is necssary if
a file is on nfs filesystem.
Diffstat (limited to 'devel/ccache/patches')
-rw-r--r--devel/ccache/patches/patch-aa17
1 files changed, 17 insertions, 0 deletions
diff --git a/devel/ccache/patches/patch-aa b/devel/ccache/patches/patch-aa
new file mode 100644
index 00000000000..f4413130b5a
--- /dev/null
+++ b/devel/ccache/patches/patch-aa
@@ -0,0 +1,17 @@
+$NetBSD: patch-aa,v 1.1 2002/05/09 01:40:04 enami Exp $
+
+--- util.c.orig Sat Apr 6 22:48:03 2002
++++ util.c
+@@ -83,8 +83,11 @@
+ }
+ }
+
+- close(fd2);
+ close(fd1);
++ if (close(fd2) == -1) {
++ unlink(dest);
++ return -1;
++ }
+ return 0;
+ }
+