Changeset: 57d4a514d665 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/57d4a514d665
Modified Files:
gdk/gdk_heap.c
Branch: Jan2022
Log Message:
Don't call mempcy with 0 size.
diffs (13 lines):
diff --git a/gdk/gdk_heap.c b/gdk/gdk_heap.c
--- a/gdk/gdk_heap.c
+++ b/gdk/gdk_heap.c
@@ -283,7 +283,8 @@ HEAPextend(Heap *h, size_t size, bool ma
h->base = HEAPcreatefile(h->farmid, &h->size,
h->filename);
if (h->base) {
h->newstorage = h->storage = STORE_MMAP;
- memcpy(h->base, bak.base, bak.free);
+ if (bak.free > 0)
+ memcpy(h->base, bak.base,
bak.free);
HEAPfree(&bak, false);
return GDK_SUCCEED;
}
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]