Changeset: 81a658153ff1 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/81a658153ff1
Modified Files:
gdk/gdk_calc.c
Branch: default
Log Message:
If the conversion fails, don't compute atom's length
diffs (24 lines):
diff --git a/gdk/gdk_calc.c b/gdk/gdk_calc.c
--- a/gdk/gdk_calc.c
+++ b/gdk/gdk_calc.c
@@ -16929,12 +16929,14 @@ VARconvert(ValPtr ret, const ValRecord *
0, abort_on_error, &reduce,
scale1, scale2, precision);
}
- if (nils == BUN_NONE + 1) {
- GDKerror("conversion from type %s to type %s "
- "unsupported.\n",
- ATOMname(v->vtype), ATOMname(ret->vtype));
+ if (nils >= BUN_NONE) {
+ if (nils == BUN_NONE + 1) {
+ GDKerror("conversion from type %s to type %s "
+ "unsupported.\n",
+ ATOMname(v->vtype), ATOMname(ret->vtype));
+ }
return GDK_FAIL;
}
ret->len = ATOMlen(ret->vtype, VALptr(ret));
- return nils == BUN_NONE ? GDK_FAIL : GDK_SUCCEED;
-}
+ return GDK_SUCCEED;
+}
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list