[nautilus] places-sidebar: return if we fail to compute a drop position
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus] places-sidebar: return if we fail to compute a drop position
- Date: Wed, 19 Oct 2011 21:03:06 +0000 (UTC)
commit 4764a856c7a6e5a84d4067e7b105c09a93ffdbe4
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Wed Oct 19 17:01:31 2011 -0400
places-sidebar: return if we fail to compute a drop position
Instead of using an invalid GtkTreePath, which could cause a segfault
later.
https://bugzilla.gnome.org/show_bug.cgi?id=660876
src/nautilus-places-sidebar.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/src/nautilus-places-sidebar.c b/src/nautilus-places-sidebar.c
index 567d8eb..6db86e1 100644
--- a/src/nautilus-places-sidebar.c
+++ b/src/nautilus-places-sidebar.c
@@ -1441,7 +1441,10 @@ drag_data_received_callback (GtkWidget *widget,
}
/* Compute position */
- compute_drop_position (tree_view, x, y, &tree_path, &tree_pos, sidebar);
+ success = compute_drop_position (tree_view, x, y, &tree_path, &tree_pos, sidebar);
+ if (!success) {
+ goto out;
+ }
success = FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]