aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/copy-tool
diff options
context:
space:
mode:
authorSimon Zheng <Simon.Zheng@Sun.Com>2005-11-30 16:09:56 +0800
committerHarry Lu <haip@src.gnome.org>2005-11-30 16:09:56 +0800
commit4b7704155ec1b6d4cfe355122ec4d48bf03629fe (patch)
treea0923914e1a4216e04daa3137ae101085889eb92 /plugins/copy-tool
parentf9ea878ce0af4b24b141facf701908bd67c674a6 (diff)
downloadgsoc2013-evolution-4b7704155ec1b6d4cfe355122ec4d48bf03629fe.tar.gz
gsoc2013-evolution-4b7704155ec1b6d4cfe355122ec4d48bf03629fe.tar.zst
gsoc2013-evolution-4b7704155ec1b6d4cfe355122ec4d48bf03629fe.zip
Fix for 322733.
2005-11-30 Simon Zheng <Simon.Zheng@Sun.Com> Fix for 322733. * copy-tool.c: (ct_selection_get): Removed printf() statement in order to avoid printing NULL point. (org_gnome_copy_tool_copy_address): Removed printf() statement. (ct_selection_clear_event): Removed printf() statement. svn path=/trunk/; revision=30709
Diffstat (limited to 'plugins/copy-tool')
-rw-r--r--plugins/copy-tool/ChangeLog8
-rw-r--r--plugins/copy-tool/copy-tool.c12
2 files changed, 6 insertions, 14 deletions
diff --git a/plugins/copy-tool/ChangeLog b/plugins/copy-tool/ChangeLog
index fc391e095a..f29bcf4662 100644
--- a/plugins/copy-tool/ChangeLog
+++ b/plugins/copy-tool/ChangeLog
@@ -1,9 +1,11 @@
-2005-11-29 Simon Zheng <Simon.Zheng@Sun.Com>
+2005-11-30 Simon Zheng <Simon.Zheng@Sun.Com>
Fix for 322733.
- * copy-tool.c: (ct_selection_get): Move printf() statement after
- NULL checking.
+ * copy-tool.c: (ct_selection_get): Removed printf() statement
+ in order to avoid printing NULL point.
+ (org_gnome_copy_tool_copy_address): Removed printf() statement.
+ (ct_selection_clear_event): Removed printf() statement.
2005-05-11 Not Zed <NotZed@Ximian.com>
diff --git a/plugins/copy-tool/copy-tool.c b/plugins/copy-tool/copy-tool.c
index ad28dfde1a..b14d762346 100644
--- a/plugins/copy-tool/copy-tool.c
+++ b/plugins/copy-tool/copy-tool.c
@@ -35,8 +35,6 @@ org_gnome_copy_tool_copy_address(void *ep, EMPopupTargetURI *t)
g_free(address_uri);
address_uri = g_strdup(t->uri);
- printf("copying address '%s'\n", address_uri);
-
gtk_selection_owner_set(invisible, GDK_SELECTION_PRIMARY, gtk_get_current_event_time());
gtk_selection_owner_set(invisible, GDK_SELECTION_CLIPBOARD, gtk_get_current_event_time());
}
@@ -44,12 +42,7 @@ org_gnome_copy_tool_copy_address(void *ep, EMPopupTargetURI *t)
static void
ct_selection_get(GtkWidget *widget, GtkSelectionData *data, guint info, guint time_stamp, void *dummy)
{
- if (address_uri == NULL)
- return;
-
- printf("get selection, address is '%s'\n", address_uri);
-
- if (strncmp (address_uri, "mailto:", 7) == 0) {
+ if (address_uri && (strncmp (address_uri, "mailto:", 7) == 0)) {
CamelInternetAddress *cia = camel_internet_address_new();
CamelURL *curl;
char *addr;
@@ -60,7 +53,6 @@ ct_selection_get(GtkWidget *widget, GtkSelectionData *data, guint info, guint ti
/* should it perhaps use address format? */
addr = camel_address_encode((CamelAddress *)cia);
tmp = addr && addr[0] ? addr : address_uri + 7;
- printf("get selection, setting to' %s'\n", tmp);
gtk_selection_data_set(data, data->target, 8, tmp, strlen(tmp));
g_free(addr);
@@ -72,8 +64,6 @@ ct_selection_get(GtkWidget *widget, GtkSelectionData *data, guint info, guint ti
static void
ct_selection_clear_event(GtkWidget *widget, GdkEventSelection *event, void *dummy)
{
- printf("selection clear event\n");
-
g_free(address_uri);
address_uri = NULL;
}