Browse Source

Merge pull request #135 from badochov/compilation_fix

Removed global variable definition in header
Fredrik Svantesson 1 year ago
parent
commit
c5fb45423e
No account linked to committer's email
2 changed files with 2 additions and 1 deletions
  1. 1
    0
      src/helpers.c
  2. 1
    1
      src/helpers.h

+ 1
- 0
src/helpers.c View File

9
 #include <errno.h> // errno
9
 #include <errno.h> // errno
10
 #include <libgen.h> // dirname 
10
 #include <libgen.h> // dirname 
11
 
11
 
12
+light_loglevel_t light_loglevel;
12
 
13
 
13
 bool light_file_read_uint64(char const *filename, uint64_t *val)
14
 bool light_file_read_uint64(char const *filename, uint64_t *val)
14
 {
15
 {

+ 1
- 1
src/helpers.h View File

21
     LIGHT_NOTE_LEVEL
21
     LIGHT_NOTE_LEVEL
22
 } light_loglevel_t;
22
 } light_loglevel_t;
23
 
23
 
24
-light_loglevel_t light_loglevel;
24
+extern light_loglevel_t light_loglevel;
25
 
25
 
26
 #define LIGHT_LOG(lvl, fp, fmt, args...)\
26
 #define LIGHT_LOG(lvl, fp, fmt, args...)\
27
     if(light_loglevel >= lvl)\
27
     if(light_loglevel >= lvl)\