From: Kaj-Michael Lang Date: Mon, 23 Jul 2007 12:36:25 +0000 (+0300) Subject: Check that w is not null before freeing. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=972ba3da2221324e5437eb051ef9f3dacf4c7fea;p=mapper Check that w is not null before freeing. --- diff --git a/src/osm-db.c b/src/osm-db.c index 8628f96..184023b 100644 --- a/src/osm-db.c +++ b/src/osm-db.c @@ -107,6 +107,8 @@ g_list_free(w->nodes); void osm_way_free(osm_way *w) { +if (!w) + return; osm_way_nodes_free(w); if (w->name) g_free(w->name);