Mercurial > pidgin
comparison src/debug.c @ 13104:e1e5462b7d81
[gaim-migrate @ 15466]
Rework lots of date parsing. I either introduced a whole lot of bugs, or I've made sure all dates are localized properly now. Only time will tell which it is... ;)
committer: Tailor Script <tailor@pidgin.im>
| author | Richard Laager <rlaager@wiktel.com> |
|---|---|
| date | Thu, 02 Feb 2006 19:50:51 +0000 |
| parents | 921f64947cad |
| children | 756c3d7177d9 |
comparison
equal
deleted
inserted
replaced
| 13103:a6811e213977 | 13104:e1e5462b7d81 |
|---|---|
| 23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 24 */ | 24 */ |
| 25 #include "debug.h" | 25 #include "debug.h" |
| 26 #include "internal.h" | 26 #include "internal.h" |
| 27 #include "prefs.h" | 27 #include "prefs.h" |
| 28 #include "util.h" | |
| 28 | 29 |
| 29 static GaimDebugUiOps *debug_ui_ops = NULL; | 30 static GaimDebugUiOps *debug_ui_ops = NULL; |
| 30 | 31 |
| 31 /* | 32 /* |
| 32 * This determines whether debug info should be written to the | 33 * This determines whether debug info should be written to the |
| 55 arg_s = g_strdup_vprintf(format, args); | 56 arg_s = g_strdup_vprintf(format, args); |
| 56 | 57 |
| 57 if ((category != NULL) && | 58 if ((category != NULL) && |
| 58 (gaim_prefs_exists("/core/debug/timestamps")) && | 59 (gaim_prefs_exists("/core/debug/timestamps")) && |
| 59 (gaim_prefs_get_bool("/core/debug/timestamps"))) { | 60 (gaim_prefs_get_bool("/core/debug/timestamps"))) { |
| 60 gchar mdate[64]; | 61 const char *mdate; |
| 61 | 62 |
| 62 time_t mtime = time(NULL); | 63 time_t mtime = time(NULL); |
| 63 strftime(mdate, sizeof(mdate), "%H:%M:%S", localtime(&mtime)); | 64 mdate = gaim_utf8_strftime("%H:%M:%S", localtime(&mtime)); |
| 64 ts_s = g_strdup_printf("(%s) ", mdate); | 65 ts_s = g_strdup_printf("(%s) ", mdate); |
| 65 } else { | 66 } else { |
| 66 ts_s = g_strdup(""); | 67 ts_s = g_strdup(""); |
| 67 } | 68 } |
| 68 | 69 |
