mirror of
https://github.com/lm-sensors/lm-sensors.git
synced 2026-11-07 16:01:34 +00:00
libsensors: Prevent warning with glibc >= 2.20
Since glibc 2.20, the usage of _BSD_SOURCE is deprecated. Fix it like described here: https://sourceware.org/glibc/wiki/Release/2.20#Deprecation_of__BSD_SOURCE_and__SVID_SOURCE_feature_macros Inspired from a similar patch by Wolfram Sang for i2c-tools. Signed-off-by: Jean Delvare <jdelvare@suse.de>
This commit is contained in:
1 parent
7478a7da14
commit
4ab7331755
1 file changed
+2
-1
+2
-1
@@ -20,7 +20,8 @@
|
||||
*/
|
||||
|
||||
/* Needed for scandir() and alphasort() */
|
||||
#define _BSD_SOURCE
|
||||
#define _BSD_SOURCE 1 /* for glibc < 2.19 */
|
||||
#define _DEFAULT_SOURCE 1 /* for glibc >= 2.19 */
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
Reference in new issue
Block a user