zabbix: zabbix_helper_mac80211.c: use POSIX <libgen.h> header 23599/head
authorTony Ambardar <itugrok@yahoo.com>
Wed, 6 Mar 2024 09:18:34 +0000 (01:18 -0800)
committerTony Ambardar <itugrok@yahoo.com>
Wed, 6 Mar 2024 13:44:46 +0000 (05:44 -0800)
commit3cf17ad13023928f5eab925e1d157319a74f50ef
treedcedb0107605ee3b5d87678e7a1fc6b82b6384fb
parent3f592f6d5940065019b9656cae6c4bd12ecb444b
zabbix: zabbix_helper_mac80211.c: use POSIX <libgen.h> header

The musl libc only implements POSIX basename() but provided a GNU header
kludge in <string.h>, which was removed in musl 1.2.5 [1]. Use the standard
<libgen.h> header to avoid compilation warnings like:

zabbix-6.4.7/zabbix-extra-mac80211/zabbix_helper_mac80211.c:37:11: warning:
 implicit declaration of function 'basename' [-Wimplicit-function-declaration]
   37 |     phy = basename(phy);
      |           ^~~~~~~~
zabbix-6.4.7/zabbix-extra-mac80211/zabbix_helper_mac80211.c:37:9: warning:
 assignment to 'char *' from 'int' makes pointer from integer without a cast
 [-Wint-conversion]
   37 |     phy = basename(phy);
      |         ^
zabbix-6.4.7/zabbix-extra-mac80211/zabbix_helper_mac80211.c:38:10: warning:
 assignment to 'char *' from 'int' makes pointer from integer without a cast
 [-Wint-conversion]
   38 |     stat = basename(stat);
      |          ^

Link 1: https://git.musl-libc.org/cgit/musl/log/?qt=grep&q=basename

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
admin/zabbix/Makefile
admin/zabbix/files/zabbix_helper_mac80211.c