dtcalc: Coverity (memory corruption, moderate)
This commit is contained in:
@@ -178,7 +178,7 @@ ds_load_resources(Display *display)
|
|||||||
|
|
||||||
if ((ptr = getenv("DTCALCDEF")) == NULL)
|
if ((ptr = getenv("DTCALCDEF")) == NULL)
|
||||||
{
|
{
|
||||||
SPRINTF(name, "%s/.dtcalcdef", home) ;
|
snprintf(name, MAXPATHLEN - 1, "%s/.dtcalcdef", home) ;
|
||||||
db = XrmGetFileDatabase(name) ;
|
db = XrmGetFileDatabase(name) ;
|
||||||
}
|
}
|
||||||
else db = XrmGetFileDatabase(ptr) ;
|
else db = XrmGetFileDatabase(ptr) ;
|
||||||
|
|||||||
Reference in New Issue
Block a user