From cd5d24021340bc95eb4e0cc3c39ff276792ef422 Mon Sep 17 00:00:00 2001 From: Peter Howkins Date: Mon, 30 Apr 2018 01:51:15 +0100 Subject: [PATCH] dticon: Fix broken string length calculation --- cde/programs/dticon/utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cde/programs/dticon/utils.c b/cde/programs/dticon/utils.c index 27aaee80..2f7cf266 100644 --- a/cde/programs/dticon/utils.c +++ b/cde/programs/dticon/utils.c @@ -2296,7 +2296,7 @@ SaveSession( void ) { tmpStr = GETSTR(16,24, "Couldn't save session to file"); tmpStr2 = (char *)XtMalloc(strlen(tmpStr) + strlen(path)+ 3); - snprintf(tmpStr2, sizeof(strlen(tmpStr) + strlen(path)+ 3), "%s: %s\n", tmpStr, path); + snprintf(tmpStr2, strlen(tmpStr) + strlen(path) + 3, "%s: %s\n", tmpStr, path); _DtSimpleErrnoError(progName, DtError, NULL, tmpStr2, NULL); XtFree(tmpStr2); XtFree ((char *)path); -- 2.25.1