summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillem Jover <guillem@hadrons.org>2021-02-19 06:49:24 +0100
committerGuillem Jover <guillem@hadrons.org>2021-02-28 05:30:25 +0100
commit25278891d8b0c5af378ff548881cd3558426ba3d (patch)
tree2923aa5563639a7f7be69d2a9926f0eec5f7eaaf
parente35d9141dcff06931287e392706f70c92c239e2e (diff)
Mark local functions as static
Warned-by: gcc
-rw-r--r--src/closefrom.c2
-rw-r--r--test/funopen.c8
-rw-r--r--test/md5.c2
3 files changed, 6 insertions, 6 deletions
diff --git a/src/closefrom.c b/src/closefrom.c
index 087ccad..2df5d03 100644
--- a/src/closefrom.c
+++ b/src/closefrom.c
@@ -79,7 +79,7 @@ sys_close_range(unsigned int fd, unsigned int max_fd, unsigned int flags)
* Close all file descriptors greater than or equal to lowfd.
* This is the expensive (fallback) method.
*/
-void
+static void
closefrom_fallback(int lowfd)
{
long fd, maxfd;
diff --git a/test/funopen.c b/test/funopen.c
index aae558c..2b34f7e 100644
--- a/test/funopen.c
+++ b/test/funopen.c
@@ -37,7 +37,7 @@ struct test_cookie {
int index;
};
-int
+static int
test_readfn(void *cookie, char *buf, int size)
{
struct test_cookie *tc = cookie;
@@ -56,7 +56,7 @@ test_readfn(void *cookie, char *buf, int size)
return size;
}
-int
+static int
test_writefn(void *cookie, const char *buf, int size)
{
struct test_cookie *tc = cookie;
@@ -75,7 +75,7 @@ test_writefn(void *cookie, const char *buf, int size)
return size;
}
-off_t
+static off_t
test_seekfn(void *cookie, off_t offset, int whence)
{
struct test_cookie *tc = cookie;
@@ -95,7 +95,7 @@ test_seekfn(void *cookie, off_t offset, int whence)
return tc->index;
}
-int
+static int
test_closefn(void *cookie)
{
struct test_cookie *tc = cookie;
diff --git a/test/md5.c b/test/md5.c
index d421ab8..bc2ed7d 100644
--- a/test/md5.c
+++ b/test/md5.c
@@ -28,7 +28,7 @@
#include <md5.h>
#include <string.h>
-void
+static void
test_md5(const char *digest, const char *string)
{
char result[MD5_DIGEST_STRING_LENGTH];