projects
/
oweals
/
cde.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0da93b0
)
dtcm: Coverity 89439 and 89458
author
Peter Howkins
<flibble@users.sf.net>
Wed, 4 Jul 2018 22:58:03 +0000
(23:58 +0100)
committer
Peter Howkins
<flibble@users.sf.net>
Wed, 4 Jul 2018 22:58:03 +0000
(23:58 +0100)
cde/programs/dtcm/libDtCmP/util.c
patch
|
blob
|
history
diff --git
a/cde/programs/dtcm/libDtCmP/util.c
b/cde/programs/dtcm/libDtCmP/util.c
index a0a6593672d66803e7c7cb1b16274cc6613e17a1..d33b8ba11f5f87cf507202e5d94333f5b2676d83 100644
(file)
--- a/
cde/programs/dtcm/libDtCmP/util.c
+++ b/
cde/programs/dtcm/libDtCmP/util.c
@@
-872,8
+872,11
@@
same_user(char *user1, char *user2)
str1 = get_head(user1, '@');
str2 = get_head(user2, '@');
- if (str1 == NULL || str2 == NULL)
+ if (str1 == NULL || str2 == NULL) {
+ free(str1);
+ free(str2); /* Handle if only one alloc success */
return(B_FALSE);
+ }
if (strcmp(str1, str2)) {
free(str1);