Added a couple items to .gitignore.

Corrected an issue reported by Coverity static analysis where memory was allocated but was not freed.
This commit is contained in:
Ward Fisher 2013-12-04 16:02:43 -07:00
parent 4a894dc154
commit 0af7499eb4
2 changed files with 6 additions and 2 deletions

2
.gitignore vendored
View File

@ -4,3 +4,5 @@ doxygen*.tmp
\#*.*\#
autom4te.cache
myhtml
CMakeLists.txt.user
scan-build

View File

@ -693,8 +693,10 @@ ocmktmp(const char* base, char** tmpnamep, int* fdp)
tmpname = (char*)malloc(tmpsize);
if(tmpname == NULL) return OC_ENOMEM;
if(!occopycat(tmpname,tmpsize,1,base))
return OC_EOVERRUN;
if(!occopycat(tmpname,tmpsize,1,base)) {
free(tmpname);
return OC_EOVERRUN;
}
#ifdef HAVE_MKSTEMP
if(!occoncat(tmpname,tmpsize,1,"XXXXXX"))
return OC_EOVERRUN;