diff options
author | Jean-François Rameau <jframeau@cvs.gnome.org> | 2006-03-02 21:23:34 +0000 |
---|---|---|
committer | Jean-François Rameau <jframeau@src.gnome.org> | 2006-03-02 21:23:34 +0000 |
commit | 8dc95a5c584d8fdb99afec102702bd8801b95266 (patch) | |
tree | 2b0682233b70018437c4bc140a3d32f1ad45d9d6 /src/ephy-shell.c | |
parent | 4f2b380361e6bf153a04cc80dba762733a5963c1 (diff) | |
download | epiphany-8dc95a5c584d8fdb99afec102702bd8801b95266.tar.gz |
Fix gcc 4.1 warnings (dereferencing type-punned pointer will break
2006-03-02 Jean-François Rameau <jframeau@cvs.gnome.org>
* embed/ephy-embed-shell.c:(ephy_embed_shell_dispose):
* src/ephy-encoding-menu.c: (ephy_encoding_menu_view_dialog_cb):
* src/ephy-history-window.c: (cmd_clear), (ephy_history_window_finalize):
* src/ephy-shell.c: (ephy_shell_get_pdm_dialog),(ephy_shell_get_prefs_dialog),
(ephy_shell_get_print_setup_dialog):
* src/prefs-dialog.c: (prefs_dialog_finalize), (font_prefs_button_clicked_cb),
(language_editor_add_button_clicked_cb):
* src/bookmarks/ephy-bookmarks-editor.c: (ephy_bookmarks_editor_finalize):
Fix gcc 4.1 warnings (dereferencing type-punned pointer will break strict-aliasing rules).
Diffstat (limited to 'src/ephy-shell.c')
-rw-r--r-- | src/ephy-shell.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/src/ephy-shell.c b/src/ephy-shell.c index 3938d5eb2..aa88aa11d 100644 --- a/src/ephy-shell.c +++ b/src/ephy-shell.c @@ -815,10 +815,14 @@ ephy_shell_get_pdm_dialog (EphyShell *shell) { if (shell->priv->pdm_dialog == NULL) { + GObject **dialog; + shell->priv->pdm_dialog = g_object_new (EPHY_TYPE_PDM_DIALOG, NULL); + dialog = &shell->priv->pdm_dialog; + g_object_add_weak_pointer (shell->priv->pdm_dialog, - (gpointer *) &shell->priv->pdm_dialog); + (gpointer *) dialog); } return shell->priv->pdm_dialog; @@ -829,10 +833,14 @@ ephy_shell_get_prefs_dialog (EphyShell *shell) { if (shell->priv->prefs_dialog == NULL) { + GObject **dialog; + shell->priv->prefs_dialog = g_object_new (EPHY_TYPE_PREFS_DIALOG, NULL); + dialog = &shell->priv->prefs_dialog; + g_object_add_weak_pointer (shell->priv->prefs_dialog, - (gpointer *) &shell->priv->prefs_dialog); + (gpointer *) dialog); } return shell->priv->prefs_dialog; @@ -843,10 +851,14 @@ ephy_shell_get_print_setup_dialog (EphyShell *shell) { if (shell->priv->print_setup_dialog == NULL) { + GObject **dialog; + shell->priv->print_setup_dialog = G_OBJECT (ephy_print_setup_dialog_new ()); + dialog = &shell->priv->print_setup_dialog; + g_object_add_weak_pointer (shell->priv->print_setup_dialog, - (gpointer *) &shell->priv->print_setup_dialog); + (gpointer *) dialog); } return shell->priv->print_setup_dialog; |