From 342f4e929888c0aaa088e39fb98a74957bf45fa7 Mon Sep 17 00:00:00 2001 From: Martin Szulecki Date: Tue, 12 Jan 2010 19:09:36 +0100 Subject: Refactor and unify internal debug system for ease of use and verbosity This introduces a new debug_info macro which automatically prints the calling function, file and line number information instead of having that information passed to every old log_debug_msg call. --- src/userpref.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/userpref.c') diff --git a/src/userpref.c b/src/userpref.c index c677fda..6eff534 100644 --- a/src/userpref.c +++ b/src/userpref.c @@ -106,7 +106,7 @@ static int userpref_set_host_id(const char *host_id) key_file = g_key_file_new(); /* Store in config file */ - log_debug_msg("%s: setting hostID to %s\n", __func__, host_id); + debug_info("setting hostID to %s", host_id); g_key_file_set_value(key_file, "Global", "HostID", host_id); /* Write config file on disk */ @@ -155,7 +155,7 @@ void userpref_get_host_id(char **host_id) userpref_set_host_id(*host_id); } - log_debug_msg("%s: Using %s as HostID\n", __func__, *host_id); + debug_info("Using %s as HostID", *host_id); } /** Determines whether this iPhone has been connected to this system before. -- cgit v1.1-32-gdbae