real ctx retured now
authorMarcel Poul <marcel.poul@cern.ch>
Tue, 1 Nov 2011 08:28:15 +0000 (08:28 +0000)
committerMarcel Poul <marcel.poul@cern.ch>
Tue, 1 Nov 2011 08:28:15 +0000 (08:28 +0000)
emi.canl.canl-c/src/canl.c

index f3681ee..42b0d0a 100644 (file)
@@ -27,8 +27,10 @@ canl_ctx canl_create_ctx()
     new_ctx->io_ctx = NULL;
     new_ctx->err_msg = NULL;
 end:
-    return new_ctx;
-
+    if (err)
+        return NULL;
+    else
+        return new_ctx;
 }
 
 void canl_free_ctx(canl_ctx cc)