summaryrefslogtreecommitdiffstats
path: root/generic/tclCkalloc.c
diff options
context:
space:
mode:
authorgriffin <briang42@easystreet.net>2023-05-20 23:24:54 (GMT)
committergriffin <briang42@easystreet.net>2023-05-20 23:24:54 (GMT)
commitc6cce703b575fc84d5337526cc517be30e8b92a5 (patch)
treef5394034a7e4c16b13a9ea1de0b959802cc57d7d /generic/tclCkalloc.c
parentf19e2665d309df5a484a53ea6d9b1098275e33db (diff)
downloadtcl-c6cce703b575fc84d5337526cc517be30e8b92a5.zip
tcl-c6cce703b575fc84d5337526cc517be30e8b92a5.tar.gz
tcl-c6cce703b575fc84d5337526cc517be30e8b92a5.tar.bz2
Add cleanup to lseq tests. Fix assertion.
Diffstat (limited to 'generic/tclCkalloc.c')
-rw-r--r--generic/tclCkalloc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclCkalloc.c b/generic/tclCkalloc.c
index 106a62c..324755d 100644
--- a/generic/tclCkalloc.c
+++ b/generic/tclCkalloc.c
@@ -1278,7 +1278,7 @@ TclAllocElemsEx(
* Attempts to allocate (oldPtr == NULL) or reallocate memory of the
* requested size plus some more for future growth. The amount of
* reallocation is adjusted depending on on failure.
- *
+ *
*
* Results:
* Pointer to allocated memory block which is at least as large
@@ -1288,7 +1288,7 @@ TclAllocElemsEx(
*/
void *
TclAttemptReallocElemsEx(
- void *oldPtr, /* Pointer to memory block to reallocate or
+ void *oldPtr, /* Pointer to memory block to reallocate or
* NULL to indicate this is a new allocation */
Tcl_Size elemCount, /* Allocation will store at least these many... */
Tcl_Size elemSize, /* ...elements of this size */
@@ -1303,7 +1303,7 @@ TclAttemptReallocElemsEx(
assert(elemCount > 0);
assert(elemSize > 0);
assert(elemSize < TCL_SIZE_MAX);
- assert(leadSize > 0);
+ assert(leadSize >= 0);
assert(leadSize < TCL_SIZE_MAX);
limit = (TCL_SIZE_MAX - leadSize) / elemSize;