From 722cfc70ebb55d97264f89a93c9d9b63f6cf8da7 Mon Sep 17 00:00:00 2001 From: Jon Trulson Date: Sat, 27 Dec 2014 20:06:53 -0700 Subject: [PATCH] dtsession/SrvFile_io: fix CID's 88299 and 89441 --- cde/programs/dtsession/SrvFile_io.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/cde/programs/dtsession/SrvFile_io.c b/cde/programs/dtsession/SrvFile_io.c index 237722bde..1fa77e540 100644 --- a/cde/programs/dtsession/SrvFile_io.c +++ b/cde/programs/dtsession/SrvFile_io.c @@ -228,10 +228,8 @@ char *palette) DEFAULT_PALETTE); } - if (path != NULL) - SRV_FREE(path); - if (palettePath != NULL) - SRV_FREE(palettePath); + SRV_FREE(path); + SRV_FREE(palettePath); return (paletteDef); @@ -372,6 +370,7 @@ ReadPaletteFile( error_value = 1; unlink(palettePath); SRV_FREE(fullPath); + close(fd); return((struct _palette *) NULL); } }