1
0
Fork 0
mirror of git://git.code.sf.net/p/cdesktopenv/code synced 2025-02-15 04:32:24 +00:00

DtSvc/DtUtil1: Coverity (memory corruption, moderate)

This commit is contained in:
Jon Trulson 2014-12-26 15:56:10 -07:00
parent 9d26729d65
commit 775008571d

View file

@ -654,7 +654,7 @@ get_link_info(type_info_t *info)
while((n = readlink(name, buff, MAXPATHLEN)) > 0) while((n = readlink(name, buff, MAXPATHLEN)) > 0)
{ {
buff[n] = 0; buff[n - 1] = 0;
free((void *)name); free((void *)name);
name = strdup(buff); name = strdup(buff);
} }