aboutsummaryrefslogtreecommitdiffstats
path: root/net-p2p/napshare/files/patch-src_hosts.c
diff options
context:
space:
mode:
authorAdam Weinberger <adamw@FreeBSD.org>2014-07-29 17:12:47 +0000
committerAdam Weinberger <adamw@FreeBSD.org>2014-07-29 17:12:47 +0000
commit08a006d08a4c35d2c3ecc9a3d10cf7fd14661a84 (patch)
tree0cfc4f0736babb895eb97a65c6defe632a0249c7 /net-p2p/napshare/files/patch-src_hosts.c
parentf474a16cfbfad1844b9c50e45e36a3a77f0c59b5 (diff)
Rename all patches that contain '::' as a path separator, and use
'__' instead.
Diffstat (limited to 'net-p2p/napshare/files/patch-src_hosts.c')
-rw-r--r--net-p2p/napshare/files/patch-src_hosts.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/net-p2p/napshare/files/patch-src_hosts.c b/net-p2p/napshare/files/patch-src_hosts.c
new file mode 100644
index 000000000000..9eb943e6f166
--- /dev/null
+++ b/net-p2p/napshare/files/patch-src_hosts.c
@@ -0,0 +1,14 @@
+--- src/hosts.c.orig Sat Jan 4 13:25:05 2003
++++ src/hosts.c Sat Jan 4 13:27:43 2003
+@@ -265,6 +265,11 @@
+ g_snprintf(h_tmp, sizeof(h_tmp), "%s/NAPS-urlcache.txt", path);
+ cachef = fopen(h_tmp, "r"); // open the normal file
+ }
++ // Try opening from data directory
++ if (cachef == NULL) {
++ g_snprintf(h_tmp, sizeof(h_tmp), "%s/NAPS-urlcache.txt", PACKAGE_DATA_DIR);
++ cachef = fopen(h_tmp, "r");
++ }
+ }
+
+ if (!cachef) {