Merge lp:~dobey/ubuntuone-client/fix-570261-stable into lp:ubuntuone-client/stable-1-2

Proposed by dobey
Status: Merged
Approved by: Natalia Bidart
Approved revision: 513
Merged at revision: 513
Proposed branch: lp:~dobey/ubuntuone-client/fix-570261-stable
Merge into: lp:ubuntuone-client/stable-1-2
Diff against target: 16 lines (+4/-2)
1 file modified
nautilus/ubuntuone-nautilus.c (+4/-2)
To merge this branch: bzr merge lp:~dobey/ubuntuone-client/fix-570261-stable
Reviewer Review Type Date Requested Status
Natalia Bidart (community) Approve
Rodrigo Moya (community) Approve
Review via email: mp+26317@code.launchpad.net

Commit message

As path can be NULL, guard against calling hash_remove with it

To post a comment you must log in.
Revision history for this message
Natalia Bidart (nataliabidart) wrote :

Is there any way I can test this, manually at least?

review: Needs Information
Revision history for this message
Rodrigo Moya (rodrigo-moya) wrote :

Indeed g_hash_table_* crash if the passed argument is NULL (although it should really not), so looks good

review: Approve
Revision history for this message
Natalia Bidart (nataliabidart) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'nautilus/ubuntuone-nautilus.c'
--- nautilus/ubuntuone-nautilus.c 2010-04-16 16:23:19 +0000
+++ nautilus/ubuntuone-nautilus.c 2010-05-28 15:27:40 +0000
@@ -1475,8 +1475,10 @@
1475 gchar * path;1475 gchar * path;
14761476
1477 path = g_hash_table_lookup (hash, "path");1477 path = g_hash_table_lookup (hash, "path");
1478 g_hash_table_remove (uon->udfs, path);1478 if (path != NULL) {
1479 ubuntuone_nautilus_reset_emblem (uon, path);1479 g_hash_table_remove (uon->udfs, path);
1480 ubuntuone_nautilus_reset_emblem (uon, path);
1481 }
1480}1482}
14811483
1482static void ubuntuone_nautilus_udf_error (DBusGProxy * proxy,1484static void ubuntuone_nautilus_udf_error (DBusGProxy * proxy,

Subscribers

People subscribed via source and target branches

to all changes: