diff options
| author | monsta <[email protected]> | 2016-02-08 11:11:57 +0300 | 
|---|---|---|
| committer | monsta <[email protected]> | 2016-02-08 11:11:57 +0300 | 
| commit | f8d6a14a1f551b3e2e9d3b3d76dbc9eace9cdee9 (patch) | |
| tree | 29634f8837f09915075dd0fb8bb692cf5a02fa5e | |
| parent | 883201a49341d588f5a6ffe2b7fd54676eb71019 (diff) | |
| download | caja-f8d6a14a1f551b3e2e9d3b3d76dbc9eace9cdee9.tar.bz2 caja-f8d6a14a1f551b3e2e9d3b3d76dbc9eace9cdee9.tar.xz | |
window-slot: fix wrong reference handling on dispose
adapted from:
https://git.gnome.org/browse/nautilus/commit/?id=97a2553ada8c8015fe22e6ec87e48123b29fa4d4
https://git.gnome.org/browse/nautilus/commit/?id=fd2685f838e613387179968d8e0b1326fe503a16
| -rw-r--r-- | src/caja-window-slot.c | 10 | 
1 files changed, 1 insertions, 9 deletions
| diff --git a/src/caja-window-slot.c b/src/caja-window-slot.c index 51847293..e7d53f2a 100644 --- a/src/caja-window-slot.c +++ b/src/caja-window-slot.c @@ -660,16 +660,8 @@ caja_window_slot_dispose (GObject *object)      }      caja_window_slot_set_viewed_file (slot, NULL); -    /* TODO? why do we unref here? the file is NULL. -     * It was already here before the slot move, though */ -    caja_file_unref (slot->viewed_file); -    if (slot->location) -    { -        /* TODO? why do we ref here, instead of unreffing? -         * It was already here before the slot migration, though */ -        g_object_ref (slot->location); -    } +    g_clear_object (&slot->location);      g_list_free_full (slot->pending_selection, g_free);      slot->pending_selection = NULL; | 
