Changeset: 04ac9b8ce9ca for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=04ac9b8ce9ca
Modified Files:
clients/mapiclient/mclient.c
Branch: Jan2014
Log Message:
Avoid potential memory leak, and don't do redundant stuff.
diffs (19 lines):
diff --git a/clients/mapiclient/mclient.c b/clients/mapiclient/mclient.c
--- a/clients/mapiclient/mclient.c
+++ b/clients/mapiclient/mclient.c
@@ -2002,14 +2002,12 @@ doFile(Mapi mid, const char *file, int u
if (line == NULL) {
/* end of file */
if (hdl == NULL) {
- if (line != NULL)
- continue;
/* nothing more to do */
+ free(buf);
goto bailout;
}
/* hdl != NULL, we should finish the current query */
- line = NULL;
length = 0;
} else
length = strlen(line);
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list