libcpupower: Hide private function
authorBen Hutchings <ben@decadent.org.uk>
Sat, 1 Dec 2018 19:22:50 +0000 (19:22 +0000)
committerSalvatore Bonaccorso <carnil@debian.org>
Wed, 8 Dec 2021 16:21:12 +0000 (16:21 +0000)
cpupower_read_sysfs() (previously known as sysfs_read_file()) is an
internal function in libcpupower and should not be exported when
libcpupower is a shared library.  Change its visibility to "hidden".

Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Gbp-Pq: Topic bugfix/all
Gbp-Pq: Name libcpupower-hide-private-function.patch

tools/power/cpupower/lib/cpupower.c

index 3656e697537ee9835a91091f75fcbdbc446ad405..e0b57121e0a9ebf1f2a77ac4e9d3b25569d7df88 100644 (file)
@@ -14,6 +14,7 @@
 #include "cpupower.h"
 #include "cpupower_intern.h"
 
+__attribute__((visibility("hidden")))
 unsigned int cpupower_read_sysfs(const char *path, char *buf, size_t buflen)
 {
        int fd;