Skip to content

Commit

Permalink
fixed small memory leak
Browse files Browse the repository at this point in the history
git-svn-id: https://vcs.maemo.org/svn/omweather/trunk@3802 5aa3d57c-301e-0410-a7f2-8fec96c11689
  • Loading branch information
vasvlad committed Feb 23, 2010
1 parent d4385c8 commit a0d0335
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
4 changes: 2 additions & 2 deletions omweather-gismeteo-ru-stations-db/configure.ac
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
AC_PREREQ(2.59)
AC_INIT(omweather-gismeteo-ru-source, 0.1)
AM_INIT_AUTOMAKE(omweather-gismeteo-ru-source, 0.1)
AC_INIT(omweather-gismeteo-ru-source, 0.5)
AM_INIT_AUTOMAKE(omweather-gismeteo-ru-source, 0.5)
AC_CONFIG_HEADER([src/config.h:src/config.h.in])
AC_CONFIG_SRCDIR([src/main.c])
AC_CANONICAL_HOST
Expand Down
6 changes: 6 additions & 0 deletions omweather-gismeteo-ru-stations-db/debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
omweather-gismeteo-ru-stations-db (0.5) unstable; urgency=low

* Fixed small memory leak

-- Vlad Vasiliev <[email protected]> Mon, 22 Feb 2010 16:53:20 +0200

omweather-gismeteo-ru-stations-db (0.4) unstable; urgency=low

* Optified
Expand Down
4 changes: 3 additions & 1 deletion omweather-gismeteo-ru-stations-db/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,10 @@ get_station_weather_data(const gchar *station_id_with_path, GHashTable *data,
if(!doc)
return -1;
root_node = xmlDocGetRootElement(doc);
if (!root_node)
if (!root_node){
xmlFreeDoc(doc);
return -1;
}
/* htmlDocDump(stdout, doc); */
if(root_node->type == XML_ELEMENT_NODE &&
strstr((char*)root_node->name, "err")){
Expand Down

0 comments on commit a0d0335

Please sign in to comment.