diff options
author | Thomas E. Dickey <dickey@invisible-island.net> | 2019-05-28 17:06:15 -0400 |
---|---|---|
committer | Thomas E. Dickey <dickey@invisible-island.net> | 2019-05-29 04:33:07 -0400 |
commit | 5ad20c90e31abfb9854cf2eae8292e44f2e18671 (patch) | |
tree | c49e8beb9edeccd5a9b0a5fa21a308509c10384f /src | |
parent | 7a6ca8784b3b1d75539962ad7b303ad0e5167e6a (diff) |
build-fix and compiler-warnings when TRACE_TM is defined
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
Diffstat (limited to 'src')
-rw-r--r-- | src/TMaction.c | 7 | ||||
-rw-r--r-- | src/TMstate.c | 6 |
2 files changed, 7 insertions, 6 deletions
diff --git a/src/TMaction.c b/src/TMaction.c index d1ca2ca..84ba2a0 100644 --- a/src/TMaction.c +++ b/src/TMaction.c @@ -476,11 +476,12 @@ static XtActionProc *EnterBindCache( bindCache->widgetClass = XtClass(w); if (_XtGlobalTM.numBindCache == _XtGlobalTM.bindCacheTblSize) { - _XtGlobalTM.bindCacheTblSize += 16; + _XtGlobalTM.bindCacheTblSize = + (TMShortCard)(_XtGlobalTM.bindCacheTblSize + 16); _XtGlobalTM.bindCacheTbl = (TMBindCache *) XtRealloc((char *)_XtGlobalTM.bindCacheTbl, - ((_XtGlobalTM.bindCacheTblSize) * - sizeof(TMBindCache))); + (Cardinal)((_XtGlobalTM.bindCacheTblSize) * + sizeof(TMBindCache))); } _XtGlobalTM.bindCacheTbl[_XtGlobalTM.numBindCache++] = bindCache; #endif /* TRACE_TM */ diff --git a/src/TMstate.c b/src/TMstate.c index 0856909..910788a 100644 --- a/src/TMstate.c +++ b/src/TMstate.c @@ -1423,10 +1423,10 @@ XtTranslations _XtCreateXlations( #ifdef TRACE_TM LOCK_PROCESS; if (_XtGlobalTM.numTms == _XtGlobalTM.tmTblSize) { - _XtGlobalTM.tmTblSize += 16; + _XtGlobalTM.tmTblSize = (TMShortCard)(_XtGlobalTM.tmTblSize + 16); _XtGlobalTM.tmTbl = (XtTranslations *) XtRealloc((char *)_XtGlobalTM.tmTbl, - _XtGlobalTM.tmTblSize * sizeof(XtTranslations)); + (Cardinal)(_XtGlobalTM.tmTblSize * sizeof(XtTranslations))); } _XtGlobalTM.tmTbl[_XtGlobalTM.numTms++] = xlations; UNLOCK_PROCESS; @@ -1601,7 +1601,7 @@ void _XtAddEventSeqToStateTree( AmbigActions(initialEvent, state, stateTree); (*state)->actions = eventSeq->actions; #ifdef TRACE_TM - LOCK_PROCESS + LOCK_PROCESS; _XtGlobalTM.numComplexActions++; UNLOCK_PROCESS; #endif /* TRACE_TM */ |