summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhobbs <hobbs>1999-11-10 02:56:24 (GMT)
committerhobbs <hobbs>1999-11-10 02:56:24 (GMT)
commit8020027ee76699a95ec4005e0c56b22b4a90a022 (patch)
tree1912e07593588a0c5abeb297e8d9e518281969fe
parent5489dc1ec2b7f92517a7ab8f4370e82216a1b7f1 (diff)
downloadtk-8020027ee76699a95ec4005e0c56b22b4a90a022.zip
tk-8020027ee76699a95ec4005e0c56b22b4a90a022.tar.gz
tk-8020027ee76699a95ec4005e0c56b22b4a90a022.tar.bz2
* generic/tkGrid.c: changed Tcl_Alloc to ckalloc
* generic/tkEntry.c: fixed C expr error in destroy of entry that could lead to 'malformed bucket chain' error
-rw-r--r--generic/tkEntry.c4
-rw-r--r--generic/tkGrid.c14
2 files changed, 9 insertions, 9 deletions
diff --git a/generic/tkEntry.c b/generic/tkEntry.c
index fd46cb3..8ae1b06 100644
--- a/generic/tkEntry.c
+++ b/generic/tkEntry.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkEntry.c,v 1.5 1999/08/10 05:05:48 jingham Exp $
+ * RCS: @(#) $Id: tkEntry.c,v 1.6 1999/11/10 02:56:24 hobbs Exp $
*/
#include "tkInt.h"
@@ -1946,7 +1946,7 @@ EntryCmdDeletedProc(clientData)
* destroys the widget.
*/
- if (! entryPtr->flags & ENTRY_DELETED) {
+ if (!(entryPtr->flags & ENTRY_DELETED)) {
Tk_DestroyWindow(entryPtr->tkwin);
}
}
diff --git a/generic/tkGrid.c b/generic/tkGrid.c
index e44569f..fbc8306 100644
--- a/generic/tkGrid.c
+++ b/generic/tkGrid.c
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkGrid.c,v 1.5 1999/07/01 00:39:44 redman Exp $
+ * RCS: @(#) $Id: tkGrid.c,v 1.6 1999/11/10 02:56:25 hobbs Exp $
*/
#include "tkInt.h"
@@ -1431,7 +1431,7 @@ ResolveConstraints(masterPtr, slotType, maxOffset)
gridCount = MAX(constraintCount,slotCount);
if (gridCount >= TYPICAL_SIZE) {
- layoutPtr = (GridLayout *) Tcl_Alloc(sizeof(GridLayout) * (1+gridCount));
+ layoutPtr = (GridLayout *) ckalloc(sizeof(GridLayout) * (1+gridCount));
} else {
layoutPtr = layoutData;
}
@@ -1750,7 +1750,7 @@ GetGrid(tkwin)
if (!new) {
return (Gridder *) Tcl_GetHashValue(hPtr);
}
- gridPtr = (Gridder *) Tcl_Alloc(sizeof(Gridder));
+ gridPtr = (Gridder *) ckalloc(sizeof(Gridder));
gridPtr->tkwin = tkwin;
gridPtr->masterPtr = NULL;
gridPtr->masterDataPtr = NULL;
@@ -1873,7 +1873,7 @@ CheckSlotData(masterPtr, slot, slotType, checkOnly)
int newNumSlot = slot + PREALLOC ;
size_t oldSize = numSlot * sizeof(SlotInfo) ;
size_t newSize = newNumSlot * sizeof(SlotInfo) ;
- SlotInfo *new = (SlotInfo *) Tcl_Alloc(newSize);
+ SlotInfo *new = (SlotInfo *) ckalloc(newSize);
SlotInfo *old = (slotType == ROW) ?
masterPtr->masterDataPtr->rowPtr :
masterPtr->masterDataPtr->columnPtr;
@@ -1925,17 +1925,17 @@ InitMasterData(masterPtr)
size_t size;
if (masterPtr->masterDataPtr == NULL) {
GridMaster *gridPtr = masterPtr->masterDataPtr =
- (GridMaster *) Tcl_Alloc(sizeof(GridMaster));
+ (GridMaster *) ckalloc(sizeof(GridMaster));
size = sizeof(SlotInfo) * TYPICAL_SIZE;
gridPtr->columnEnd = 0;
gridPtr->columnMax = 0;
- gridPtr->columnPtr = (SlotInfo *) Tcl_Alloc(size);
+ gridPtr->columnPtr = (SlotInfo *) ckalloc(size);
gridPtr->columnSpace = 0;
gridPtr->columnSpace = TYPICAL_SIZE;
gridPtr->rowEnd = 0;
gridPtr->rowMax = 0;
- gridPtr->rowPtr = (SlotInfo *) Tcl_Alloc(size);
+ gridPtr->rowPtr = (SlotInfo *) ckalloc(size);
gridPtr->rowSpace = 0;
gridPtr->rowSpace = TYPICAL_SIZE;