summaryrefslogtreecommitdiff
path: root/sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-12-10 03:19:26 +0000
committerV3n3RiX <venerix@koprulu.sector>2022-12-10 03:19:26 +0000
commitcaf79cb4f7c4d5f7cce488d8f50dfb98ddbd09ab (patch)
tree4fb39a9252efabe8f160ef46b7b3be2f52af25aa /sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch
parent3606ceecb950b302a6ba2a9882aeeff2a851e5dc (diff)
gentoo auto-resync : 10:12:2022 - 03:19:26
Diffstat (limited to 'sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch')
-rw-r--r--sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch b/sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch
new file mode 100644
index 000000000000..fddf4b2dbc80
--- /dev/null
+++ b/sys-block/partimage/files/partimage-0.6.9-musl-null-type.patch
@@ -0,0 +1,34 @@
+In newer musl, the type of NULL in C++ is nullptr rather than an
+integer.
+
+Upstream: https://git.musl-libc.org/cgit/musl/commit/?id=98e688a9da5e7b2925dda17a2d6820dddf1fb287
+Bug: https://bugs.gentoo.org/853883
+
+diff --git a/src/server/partimaged-client.cpp b/src/server/partimaged-client.cpp
+index 7c5f856..35b3514 100644
+--- a/src/server/partimaged-client.cpp
++++ b/src/server/partimaged-client.cpp
+@@ -89,9 +89,9 @@ void CPartimagedClients::Release(unsigned int client)
+ pthread_mutex_lock(&mClients);
+ showDebug(1, "%d released\n", client);
+ shutdown(Clients[client].Sock, SHUT_RDWR);
+- Clients[client].Sock = NULL;
++ Clients[client].Sock = 0x0;
+ Clients[client].Present = false;
+- Clients[client].MyPid = NULL;
++ Clients[client].MyPid = 0x0;
+ pthread_mutex_unlock(&mClients);
+ }
+
+@@ -109,9 +109,9 @@ void CPartimagedClients::ReleaseClientByPid(unsigned int client_pid)
+ found = true;
+ showDebug(1, "client %d pid = %d released by pid\n", next, client_pid);
+ shutdown(Clients[next].Sock, SHUT_RDWR);
+- Clients[next].Sock = NULL;
++ Clients[next].Sock = 0x0;
+ Clients[next].Present = false;
+- Clients[next].MyPid = NULL;
++ Clients[next].MyPid = 0x0;
+ }
+ else
+ next++;