void-packages/srcpkgs/iwd/patches/musl-rawmemchr.patch
Peter Bui 5e68aeb1fb iwd: update to 1.1.
Add patch for musl (does not have rawmemchr, so replace with memchr).
2019-11-19 14:30:58 +01:00

14 lines
405 B
Diff

--- src/wiphy.c.orig 2019-11-16 09:09:02.009699886 -0500
+++ src/wiphy.c 2019-11-16 09:25:25.188776792 -0500
@@ -500,7 +500,11 @@
if (out_num)
*out_num =
+#if defined(__GLIBC__)
(uint8_t *) rawmemchr(wiphy->supported_rates[band], 0) -
+#else
+ (uint8_t *) memchr(wiphy->supported_rates[band], 0, SIZE_MAX) -
+#endif
wiphy->supported_rates[band];
return wiphy->supported_rates[band];