Changeset: ed5747601dbf for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ed5747601dbf
Modified Files:
MonetDB5/src/modules/mal/tablet.mx
Branch: default
Log Message:
ensure the parent BAT is read-only before we get a BATslice()
such that the slice is indeed a cheap view, not an expensive copy
diffs (17 lines):
diff -r eb227c6e8cfb -r ed5747601dbf MonetDB5/src/modules/mal/tablet.mx
--- a/MonetDB5/src/modules/mal/tablet.mx Sun Dec 26 16:05:45 2010 +0100
+++ b/MonetDB5/src/modules/mal/tablet.mx Mon Dec 27 00:06:47 2010 +0100
@@ -1353,10 +1353,11 @@
return NULL;
for (i = 0; i < as->nr_attrs; i++) {
BAT *b = fmt[i].c[0];
- BAT *bv = BATslice(b, offset, BATcount(b));
+ BAT *bv = NULL;
+ BATsetaccess(b, BAT_READ);
+ bv = BATslice(b, offset, BATcount(b));
BUNins(bats, (ptr) fmt[i].name, (ptr) &bv->batCacheid, FALSE);
- BATsetaccess(b, BAT_READ);
BATaccessBegin(bv, USE_ALL, MMAP_WILLNEED);
BATpropcheck(bv, BATPROPS_ALL);
/* drop the hashes, we don't need them now and they consume
space */
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list