aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2007-10-26 20:15:44 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2007-10-26 20:15:44 +0800
commit7517f413700c53fb8d6ae7e43957435060fd714f (patch)
treecbdf26199f130fd788bb7bedea41ecc0511683da /calendar/gui
parente48ca861ed32f75ae66aa6efab698635ef2b1cb9 (diff)
downloadgsoc2013-evolution-7517f413700c53fb8d6ae7e43957435060fd714f.tar.gz
gsoc2013-evolution-7517f413700c53fb8d6ae7e43957435060fd714f.tar.zst
gsoc2013-evolution-7517f413700c53fb8d6ae7e43957435060fd714f.zip
Zero out the GnomePilotRecord struct to silence a compiler warning.
2007-10-26 Matthew Barnes <mbarnes@redhat.com> * addressbook/conduit/address-conduit.c (local_record_to_pilot_record): * calendar/conduits/calendar/calendar-conduit.c (local_record_to_pilot_record): * calendar/conduits/memo/memo-conduit.c (local_record_to_pilot_record): * calendar/conduits/todo/todo-conduit.c (local_record_to_pilot_record): Zero out the GnomePilotRecord struct to silence a compiler warning. * calendar/gui/dialogs/memo-page.c (memo_page_select_organizer): Initialize def_address. * calendar/gui/e-itip-control.c: Use unions to avoid strict-aliasing violations. svn path=/trunk/; revision=34434
Diffstat (limited to 'calendar/gui')
-rw-r--r--calendar/gui/dialogs/memo-page.c2
-rw-r--r--calendar/gui/e-itip-control.c22
2 files changed, 17 insertions, 7 deletions
diff --git a/calendar/gui/dialogs/memo-page.c b/calendar/gui/dialogs/memo-page.c
index 56d422bc18..c1890ee37e 100644
--- a/calendar/gui/dialogs/memo-page.c
+++ b/calendar/gui/dialogs/memo-page.c
@@ -1112,7 +1112,7 @@ memo_page_select_organizer (MemoPage *mpage, const char *backend_address)
MemoPagePrivate *priv;
GList *l;
EAccount *def_account;
- gchar *def_address;
+ gchar *def_address = NULL;
gboolean subscribed_cal = FALSE;
ESource *source = NULL;
const char *user_addr = NULL;
diff --git a/calendar/gui/e-itip-control.c b/calendar/gui/e-itip-control.c
index 651aae31bd..69598568a6 100644
--- a/calendar/gui/e-itip-control.c
+++ b/calendar/gui/e-itip-control.c
@@ -72,9 +72,19 @@ struct _EItipControlPrivate {
char action;
gboolean rsvp;
- GtkWidget *ok;
- GtkWidget *hbox;
- GtkWidget *vbox;
+ /* Use the gpointer variants for weak pointers. */
+ union {
+ GtkWidget *ok;
+ gpointer ok_pointer;
+ };
+ union {
+ GtkWidget *hbox;
+ gpointer hbox_pointer;
+ };
+ union {
+ GtkWidget *vbox;
+ gpointer vbox_pointer;
+ };
char *vcalendar;
ECalComponent *comp;
@@ -2200,12 +2210,12 @@ insert_boxes (GtkHTMLEmbedded *eb, EItipControl *itip)
priv = itip->priv;
priv->vbox = gtk_vbox_new (FALSE, 12);
- g_object_add_weak_pointer (G_OBJECT (priv->vbox), (gpointer *) &(priv->vbox));
+ g_object_add_weak_pointer (G_OBJECT (priv->vbox), &priv->vbox_pointer);
gtk_container_add (GTK_CONTAINER (eb), priv->vbox);
gtk_widget_show (priv->vbox);
priv->hbox = gtk_hbox_new (FALSE, 6);
- g_object_add_weak_pointer (G_OBJECT (priv->hbox), (gpointer *) &(priv->hbox));
+ g_object_add_weak_pointer (G_OBJECT (priv->hbox), &priv->hbox_pointer);
gtk_box_pack_start (GTK_BOX (priv->vbox), priv->hbox, FALSE, TRUE, 0);
gtk_widget_show (priv->hbox);
@@ -2263,7 +2273,7 @@ insert_ok (GtkWidget *hbox, EItipControl *itip)
priv = itip->priv;
priv->ok = gtk_button_new_from_stock (GTK_STOCK_OK);
- g_object_add_weak_pointer (G_OBJECT (priv->ok), (gpointer *) &(priv->ok) );
+ g_object_add_weak_pointer (G_OBJECT (priv->ok), &priv->ok_pointer);
g_signal_connect (priv->ok, "clicked", G_CALLBACK (ok_clicked_cb), itip);