Update of /cvsroot/monetdb/pathfinder/modules/pftijah
In directory
sfp-cvsdas-1.v30.ch3.sourceforge.com:/tmp/cvs-serv30872/modules/pftijah
Modified Files:
Tag: M5XQ
nexi_generate_plan.c
Log Message:
propagated changes of Monday Jan 04 2010
from the XQFT branch to the M5XQ branch
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2010/01/04 - sjoerd: modules/pftijah/nexi_generate_plan.c,1.9.24.1
propagated changes of Saturday Dec 26 2009 - Monday Jan 04 2010
from the development trunk to the XQFT branch
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2009/12/26 - stmane: modules/pftijah/nexi_generate_plan.c,1.10
propagated changes of Wednesday Dec 23 2009 - Saturday Dec 26 2009
from the Nov2009 branch to the development trunk
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2009/12/23 - sjoerd: modules/pftijah/nexi_generate_plan.c,1.9.20.1
Clean up on error.
Found by Coverity.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Index: nexi_generate_plan.c
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/modules/pftijah/nexi_generate_plan.c,v
retrieving revision 1.9
retrieving revision 1.9.14.1
diff -u -d -r1.9 -r1.9.14.1
--- nexi_generate_plan.c 14 Jan 2008 14:06:07 -0000 1.9
+++ nexi_generate_plan.c 4 Jan 2010 15:20:52 -0000 1.9.14.1
@@ -150,12 +150,12 @@
if ( mil_filename && !(mil_file = fopen(mil_filename,"w")) ) {
printf("Error: cannot find file for writing mil code.\n");
- return NULL;
+ goto error;
}
if ( logical_filname && !(logical_file = fopen(logical_filname,"w")) ) {
printf("Error: cannot find file for writing logical plan.\n");
- return NULL;
+ goto error;
}
/* formating the mil header */
@@ -185,7 +185,7 @@
p_command = GDKmalloc(MAX_QUERIES*OPERAND_MAX * sizeof(command_tree));
if ( !p_command_array || !p_command ) {
stream_printf(GDKout,"CAS_plan_gen: GDKmalloc failed.\n");
- return 0;
+ goto error;
}
/* printf("%d\n",p_command_array); */
@@ -3000,4 +3000,8 @@
return p_command_start;
+ error:
+ if ( mil_file ) fclose(mil_file);
+ if ( logical_file ) fclose(logical_file);
+ return NULL;
}
------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins