[GRASS-SVN] r36329 - grass/trunk/db/drivers/dbf

svn_grass at osgeo.org svn_grass at osgeo.org
Wed Mar 11 06:00:01 EDT 2009


Author: marisn
Date: 2009-03-11 06:00:01 -0400 (Wed, 11 Mar 2009)
New Revision: 36329

Modified:
   grass/trunk/db/drivers/dbf/dbfexe.c
Log:
Don't use SQLPSTMT after freeing it. Fixes #400 (merge from develbranch_6 r36326)

Modified: grass/trunk/db/drivers/dbf/dbfexe.c
===================================================================
--- grass/trunk/db/drivers/dbf/dbfexe.c	2009-03-11 09:57:11 UTC (rev 36328)
+++ grass/trunk/db/drivers/dbf/dbfexe.c	2009-03-11 10:00:01 UTC (rev 36329)
@@ -66,10 +66,10 @@
     sqpInitParser(st);
 
     if (yyparse() != 0) {
-	sqpFreeStmt(st);
 	G_free(tmpsql);
 	append_error("SQL parser error: %s\n", st->errmsg);
 	append_error("in statement:\n%s\n", sql);
+	sqpFreeStmt(st);
 	return DB_FAILED;
     }
     G_free(tmpsql);



More information about the grass-commit mailing list