From 07a67fa4bcc1b8bf2651ab41e5fc54a05059cf7e Mon Sep 17 00:00:00 2001 From: Mike Hommey Date: Sat, 29 Apr 2006 21:57:40 +0200 Subject: Load /tmp/libxml2-2.6.24 into libxml2/branches/upstream/current. --- example/Makefile.in | 10 ++++------ example/gjobread.c | 12 +++++++----- 2 files changed, 11 insertions(+), 11 deletions(-) (limited to 'example') diff --git a/example/Makefile.in b/example/Makefile.in index b97da80..d1ac9ef 100644 --- a/example/Makefile.in +++ b/example/Makefile.in @@ -1,8 +1,8 @@ -# Makefile.in generated by automake 1.9.2 from Makefile.am. +# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004 Free Software Foundation, Inc. +# 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -14,8 +14,6 @@ @SET_MAKE@ -SOURCES = $(gjobread_SOURCES) - srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ @@ -59,11 +57,11 @@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --mode=compile --tag=CC $(CC) $(DEFS) \ +LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) -LINK = $(LIBTOOL) --mode=link --tag=CC $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ +LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(gjobread_SOURCES) DIST_SOURCES = $(gjobread_SOURCES) diff --git a/example/gjobread.c b/example/gjobread.c index b192bf4..d3f6d57 100644 --- a/example/gjobread.c +++ b/example/gjobread.c @@ -237,12 +237,14 @@ parseGjobFile(char *filename) { */ /* First level we expect just Jobs */ cur = cur->xmlChildrenNode; - while ( cur && xmlIsBlankNode ( cur ) ) - { + while ( cur && xmlIsBlankNode ( cur ) ) { cur = cur -> next; - } - if ( cur == 0 ) - return ( NULL ); + } + if ( cur == 0 ) { + xmlFreeDoc(doc); + free(ret); + return ( NULL ); + } if ((xmlStrcmp(cur->name, (const xmlChar *) "Jobs")) || (cur->ns != ns)) { fprintf(stderr,"document of the wrong type, was '%s', Jobs expected", cur->name); -- cgit v1.2.3