summaryrefslogtreecommitdiff
path: root/src/common/nullpo.c
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2018-07-01 21:51:00 +0200
committerGitHub <noreply@github.com>2018-07-01 21:51:00 +0200
commit0a151c27ebef40f965cd87f436c72c044a3284ac (patch)
treed2892f1fe37846f56da93c89aa0b29e9442205ca /src/common/nullpo.c
parent392238d4a9fe4ca3cc68098d9709c27c92409c8b (diff)
parent42f7eb821648b0076163faf968a83ab5dd2ce672 (diff)
downloadhercules-0a151c27ebef40f965cd87f436c72c044a3284ac.tar.gz
hercules-0a151c27ebef40f965cd87f436c72c044a3284ac.tar.bz2
hercules-0a151c27ebef40f965cd87f436c72c044a3284ac.tar.xz
hercules-0a151c27ebef40f965cd87f436c72c044a3284ac.zip
Merge pull request #2112 from MishimaHaruna/staticfunctions
Staticfunctions
Diffstat (limited to 'src/common/nullpo.c')
-rw-r--r--src/common/nullpo.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/common/nullpo.c b/src/common/nullpo.c
index 1441ff853..e19f7f846 100644
--- a/src/common/nullpo.c
+++ b/src/common/nullpo.c
@@ -32,7 +32,7 @@
#include <execinfo.h>
#endif // HAVE_EXECINFO
-struct nullpo_interface nullpo_s;
+static struct nullpo_interface nullpo_s;
struct nullpo_interface *nullpo;
/**
@@ -44,7 +44,8 @@ struct nullpo_interface *nullpo;
* @param targetname Name of the checked symbol
* @param title Message title to display (i.e. failed assertion or nullpo info)
*/
-void assert_report(const char *file, int line, const char *func, const char *targetname, const char *title) {
+static void assert_report(const char *file, int line, const char *func, const char *targetname, const char *title)
+{
#ifdef HAVE_EXECINFO
void *array[10];
int size;
@@ -72,7 +73,8 @@ void assert_report(const char *file, int line, const char *func, const char *tar
/**
*
**/
-void nullpo_defaults(void) {
+void nullpo_defaults(void)
+{
nullpo = &nullpo_s;
nullpo->assert_report = assert_report;
}