[geocode-glib] forward: Move variable init in an inner block
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geocode-glib] forward: Move variable init in an inner block
- Date: Mon, 30 Mar 2015 13:29:48 +0000 (UTC)
commit bd00b896658abd8e314a63da0414d8578053ed13
Author: Bastien Nocera <hadess hadess net>
Date: Mon Mar 30 15:28:44 2015 +0200
forward: Move variable init in an inner block
geocode-glib/geocode-forward.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/geocode-glib/geocode-forward.c b/geocode-glib/geocode-forward.c
index 630231a..446d6b5 100644
--- a/geocode-glib/geocode-forward.c
+++ b/geocode-glib/geocode-forward.c
@@ -850,12 +850,14 @@ _geocode_create_place_from_attributes (GHashTable *ht)
static void
insert_place_into_tree (GNode *place_tree, GHashTable *ht)
{
- GNode *start = place_tree, *child = NULL;
+ GNode *start = place_tree;
GeocodePlace *place = NULL;
char *attr_val = NULL;
guint i;
for (i = 0; i < G_N_ELEMENTS(attributes); i++) {
+ GNode *child = NULL;
+
attr_val = g_hash_table_lookup (ht, attributes[i]);
if (!attr_val) {
/* Add a dummy node if the attribute value is not
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]