Changeset: 52ad8b375ab1 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=52ad8b375ab1
Modified Files:
        monetdb5/modules/mal/remote.c
Branch: Jan2014
Log Message:

Close resource leak.


diffs (19 lines):

diff --git a/monetdb5/modules/mal/remote.c b/monetdb5/modules/mal/remote.c
--- a/monetdb5/modules/mal/remote.c
+++ b/monetdb5/modules/mal/remote.c
@@ -490,10 +490,13 @@ str RMTget(Client cntxt, MalBlkPtr mb, M
           Since the put() encodes the type as known to the remote site
           we can simple compare it here */
        rt = getTypeIdentifier(rtype);
-       if (strcmp(ident + strlen(ident) - strlen(rt), rt))
-               throw(MAL, "remote.get", ILLEGAL_ARGUMENT
+       if (strcmp(ident + strlen(ident) - strlen(rt), rt)) {
+               tmp = createException(MAL, "remote.get", ILLEGAL_ARGUMENT
                        ": remote object type %s does not match expected type 
%s",
                        rt, ident);
+               GDKfree(rt);
+               return tmp;
+       }
        GDKfree(rt);
 
        if (isaBatType(rtype) && (localtype == 0 || localtype != c->type || 
(ATOMvarsized(getHeadType(rtype)))))
_______________________________________________
checkin-list mailing list
checkin-list@monetdb.org
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to