diff options
Diffstat (limited to 'generic/tclClockFmt.c')
-rw-r--r-- | generic/tclClockFmt.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/generic/tclClockFmt.c b/generic/tclClockFmt.c index 358c4f0..beec218 100644 --- a/generic/tclClockFmt.c +++ b/generic/tclClockFmt.c @@ -565,7 +565,10 @@ ClockFmtScnStorageAllocProc( allocsize -= sizeof(hPtr->key); } - fss = (ClockFmtScnStorage *)Tcl_Alloc(allocsize); + fss = (ClockFmtScnStorage *)Tcl_AttemptAlloc(allocsize); + if (!fss) { + return NULL; + } /* initialize */ memset(fss, 0, sizeof(*fss)); |