summaryrefslogtreecommitdiffstats
path: root/source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2016-06-30 20:26:57 +0000
committer Eric Hameleers <alien@slackware.com>2018-05-31 23:31:18 +0200
commitd31c50870d0bee042ce660e445c9294a59a3a65b (patch)
tree6bfc0de3c95267b401b620c2c67859557dc60f97 /source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch
parent76fc4757ac91ac7947a01fb7b53dddf9a78a01d1 (diff)
downloadcurrent-d31c50870d0bee042ce660e445c9294a59a3a65b.tar.gz
current-d31c50870d0bee042ce660e445c9294a59a3a65b.tar.xz
Slackware 14.2slackware-14.2
Thu Jun 30 20:26:57 UTC 2016 Slackware 14.2 x86_64 stable is released! The long development cycle (the Linux community has lately been living in "interesting times", as they say) is finally behind us, and we're proud to announce the release of Slackware 14.2. The new release brings many updates and modern tools, has switched from udev to eudev (no systemd), and adds well over a hundred new packages to the system. Thanks to the team, the upstream developers, the dedicated Slackware community, and everyone else who pitched in to help make this release a reality. The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware project by picking up a copy from store.slackware.com. We're taking pre-orders now, and offer a discount if you sign up for a subscription. Have fun! :-)
Diffstat (limited to 'source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch')
-rw-r--r--source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch51
1 files changed, 51 insertions, 0 deletions
diff --git a/source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch b/source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch
new file mode 100644
index 000000000..c54d542e7
--- /dev/null
+++ b/source/n/rpcbind/0004-Delete-the-unix-socket-only-if-we-have-created-it.patch
@@ -0,0 +1,51 @@
+From 3a664b1b5a310df39bd0f325b0edb1deb31c2249 Mon Sep 17 00:00:00 2001
+From: Laurent Bigonville <bigon@bigon.be>
+Date: Wed, 18 Nov 2015 14:34:26 -0500
+Subject: [PATCH 4/4] Delete the unix socket only if we have created it
+
+From: Laurent Bigonville <bigon@bigon.be>
+
+If systemd has created the unix socket on our behalf, we shouldn't try
+to delete it.
+
+https://bugzilla.redhat.com/show_bug.cgi?id=1279076
+
+Signed-off-by: Laurent Bigonville <bigon@bigon.be
+Signed-off-by: Steve Dickson <steved@redhat.com>
+---
+ src/rpcbind.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/src/rpcbind.c b/src/rpcbind.c
+index 045daa1..c4265cd 100644
+--- a/src/rpcbind.c
++++ b/src/rpcbind.c
+@@ -87,6 +87,7 @@ static inline void __nss_configure_lookup(const char *db, const char *s) {}
+ int debugging = 0; /* Tell me what's going on */
+ int doabort = 0; /* When debugging, do an abort on errors */
+ int dofork = 1; /* fork? */
++int createdsocket = 0; /* Did I create the socket or systemd did it for me? */
+
+ rpcblist_ptr list_rbl; /* A list of version 3/4 rpcbind services */
+
+@@ -445,6 +446,7 @@ init_transport(struct netconfig *nconf)
+ memset(&sun, 0, sizeof sun);
+ sun.sun_family = AF_LOCAL;
+ unlink(_PATH_RPCBINDSOCK);
++ createdsocket = 1; /* We are now in the process of creating the unix socket */
+ strcpy(sun.sun_path, _PATH_RPCBINDSOCK);
+ addrlen = SUN_LEN(&sun);
+ sa = (struct sockaddr *)&sun;
+@@ -846,7 +848,8 @@ static void
+ terminate(int dummy /*__unused*/)
+ {
+ close(rpcbindlockfd);
+- unlink(_PATH_RPCBINDSOCK);
++ if(createdsocket)
++ unlink(_PATH_RPCBINDSOCK);
+ unlink(RPCBINDDLOCK);
+ #ifdef WARMSTART
+ write_warmstart(); /* Dump yourself */
+--
+2.6.4
+