Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed build with debug disabled

  • Loading branch information...
commit 41884d9919f3b00e44809207ec4f8e7658f606a7 1 parent e2d914f
@smokku smokku authored
Showing with 9 additions and 6 deletions.
  1. +7 −4 util/log.c
  2. +2 −2 util/util.h
View
11 util/log.c
@@ -223,12 +223,12 @@ void set_debug_flag(int v)
debug_flag = v;
}
-int set_debug_log_from_config(config_t c)
+void set_debug_log_from_config(config_t c)
{
return set_debug_file(config_get_one(c, "log.debug", 0));
-};
+}
-JABBERD2_API int set_debug_file(const char *filename)
+JABBERD2_API void set_debug_file(const char *filename)
{
// Close debug output file but not stderr
if (debug_log_target != 0 &&
@@ -255,7 +255,7 @@ JABBERD2_API int set_debug_file(const char *filename)
// set stderr
debug_log_target = stderr;
}
-};
+}
#else /* DEBUG */
void debug_log(const char *file, int line, const char *msgfmt, ...)
@@ -263,4 +263,7 @@ void debug_log(const char *file, int line, const char *msgfmt, ...)
void set_debug_flag(int v)
{ }
+
+void set_debug_log_from_config(config_t c)
+{ }
#endif
View
4 util/util.h
@@ -414,9 +414,9 @@ JABBERD2_API int hex_to_raw(char *in, int inlen, char *out);
JABBERD2_API int get_debug_flag(void);
JABBERD2_API void set_debug_flag(int v);
JABBERD2_API void debug_log(const char *file, int line, const char *msgfmt, ...);
-JABBERD2_API int set_debug_file(const char *filename);
+JABBERD2_API void set_debug_file(const char *filename);
-JABBERD2_API int set_debug_log_from_config(config_t c);
+JABBERD2_API void set_debug_log_from_config(config_t c);
#define ZONE __FILE__,__LINE__
#define MAX_DEBUG 8192
Please sign in to comment.
Something went wrong with that request. Please try again.