diff options
-rw-r--r-- | e-util/ChangeLog | 4 | ||||
-rw-r--r-- | e-util/e-account.c | 15 | ||||
-rw-r--r-- | e-util/e-menu.c | 4 | ||||
-rw-r--r-- | e-util/e-plugin-mono.c | 10 | ||||
-rw-r--r-- | e-util/md5-utils.c | 8 |
5 files changed, 21 insertions, 20 deletions
diff --git a/e-util/ChangeLog b/e-util/ChangeLog index f88a68649d..293b8860d3 100644 --- a/e-util/ChangeLog +++ b/e-util/ChangeLog @@ -1,3 +1,7 @@ +2005-03-01 Not Zed <NotZed@Ximian.com> + + * *.c: Remove/disable debug. + 2005-02-23 Hans Petter Jansson <hpj@novell.com> * Makefile.am (eutilinclude_HEADERS) diff --git a/e-util/e-account.c b/e-util/e-account.c index b919a56cc2..79cc78e282 100644 --- a/e-util/e-account.c +++ b/e-util/e-account.c @@ -33,6 +33,8 @@ #include <gconf/gconf-client.h> +#define d(x) + enum { CHANGED, LAST_SIGNAL @@ -820,6 +822,7 @@ gboolean e_account_get_bool(EAccount *ea, e_account_item_t type) return *((gboolean *)addr(ea, type)); } +#if d(!)0 static void dump_account(EAccount *ea) { @@ -830,6 +833,7 @@ dump_account(EAccount *ea) printf(" ->\n%s\n", xml); g_free(xml); } +#endif /* TODO: should it return true if it changed? */ void e_account_set_string(EAccount *ea, e_account_item_t type, const char *val) @@ -840,13 +844,12 @@ void e_account_set_string(EAccount *ea, e_account_item_t type, const char *val) g_warning("Trying to set non-writable option account value"); } else { p = (char **)addr(ea, type); - printf("Setting string %d: old '%s' new '%s'\n", type, *p, val); + d(printf("Setting string %d: old '%s' new '%s'\n", type, *p, val)); if (*p != val && (*p == NULL || val == NULL || strcmp(*p, val) != 0)) { g_free(*p); *p = g_strdup(val); - - dump_account(ea); + d(dump_account(ea)); g_signal_emit(ea, signals[CHANGED], 0, type); } } @@ -861,7 +864,7 @@ void e_account_set_int(EAccount *ea, e_account_item_t type, int val) if (*p != val) { *p = val; - dump_account(ea); + d(dump_account(ea)); g_signal_emit(ea, signals[CHANGED], 0, type); } } @@ -876,7 +879,7 @@ void e_account_set_bool(EAccount *ea, e_account_item_t type, gboolean val) if (*p != val) { *p = val; - dump_account(ea); + d(dump_account(ea)); g_signal_emit(ea, signals[CHANGED], 0, type); } } @@ -899,7 +902,7 @@ e_account_writable_option(EAccount *ea, const char *protocol, const char *option info = g_hash_table_lookup(ea_option_table, key); } - printf("checking writable option '%s' perms=%08x\n", option, info?info->perms:0); + d(printf("checking writable option '%s' perms=%08x\n", option, info?info->perms:0)); return info == NULL || (info->perms & ea_perms) == 0; diff --git a/e-util/e-menu.c b/e-util/e-menu.c index 0f76f301fc..68c1f65c5e 100644 --- a/e-util/e-menu.c +++ b/e-util/e-menu.c @@ -829,7 +829,7 @@ emph_construct(EPluginHook *eph, EPlugin *ep, xmlNodePtr root) menu = emph_construct_menu(eph, node); if (menu) { - printf(" plugin adding factory %p\n", klass); + d(printf(" plugin adding factory %p\n", klass)); e_menu_class_add_factory(klass, menu->id, emph_menu_factory, menu); emph->menus = g_slist_append(emph->menus, menu); } @@ -857,7 +857,7 @@ emph_finalise(GObject *o) static void emph_class_init(EPluginHookClass *klass) { - printf("EMenuHook class init %p '%s'\n", klass, g_type_name(((GObjectClass *)klass)->g_type_class.g_type)); + d(printf("EMenuHook class init %p '%s'\n", klass, g_type_name(((GObjectClass *)klass)->g_type_class.g_type))); ((GObjectClass *)klass)->finalize = emph_finalise; klass->construct = emph_construct; diff --git a/e-util/e-plugin-mono.c b/e-util/e-plugin-mono.c index 9b7c39a3f9..2692620133 100644 --- a/e-util/e-plugin-mono.c +++ b/e-util/e-plugin-mono.c @@ -11,6 +11,8 @@ #include <mono/metadata/assembly.h> #include <mono/jit/jit.h> +#define d(x) + static MonoDomain *domain; /* ********************************************************************** */ @@ -68,7 +70,7 @@ epm_invoke(EPlugin *ep, const char *name, void *data) if (epm->handler == NULL || (p->klass = mono_class_from_name(mono_assembly_get_image(p->assembly), "", epm->handler)) == NULL) { - printf("Using static callbacks only"); + d(printf("Using static callbacks only")); } else { p->plugin = mono_object_new(domain, p->klass); /* could conceivably init with some context too */ @@ -79,7 +81,7 @@ epm_invoke(EPlugin *ep, const char *name, void *data) m = g_hash_table_lookup(p->methods, name); if (m == NULL) { if (p->klass) { - printf("looking up method '%s' in class\n", name); + d(printf("looking up method '%s' in class\n", name)); /* class method */ d = mono_method_desc_new(name, FALSE); if (d == NULL) { @@ -93,7 +95,7 @@ epm_invoke(EPlugin *ep, const char *name, void *data) return NULL; } } else { - printf("looking up static method '%s'\n", name); + d(printf("looking up static method '%s'\n", name)); /* static method */ d = mono_method_desc_new(name, FALSE); if (d == NULL) { @@ -121,7 +123,7 @@ epm_invoke(EPlugin *ep, const char *name, void *data) if (res) { void **p = mono_object_unbox(res); - printf("mono method returned '%p' %ld\n", *p, (long int)*p); + d(printf("mono method returned '%p' %ld\n", *p, (long int)*p)); return *p; } else return NULL; diff --git a/e-util/md5-utils.c b/e-util/md5-utils.c index 6f7e06f48d..e550968828 100644 --- a/e-util/md5-utils.c +++ b/e-util/md5-utils.c @@ -336,8 +336,6 @@ md5_get_digest_from_file (const gchar *filename, guchar digest[16]) gint nb_bytes_read; FILE *fp; - printf("generating checksum\n"); - md5_init (&ctx); fp = fopen(filename, "r"); if (!fp) { @@ -354,10 +352,4 @@ md5_get_digest_from_file (const gchar *filename, guchar digest[16]) md5_final (&ctx, digest); - - printf("checksum done\n"); } - - - - |