[SCM] Samba Shared Repository - branch v3-2-test updated -
release-3-2-0pre2-3459-gf7dc45f
Jeremy Allison
jra at samba.org
Fri Feb 13 18:07:19 GMT 2009
The branch, v3-2-test has been updated
via f7dc45f72145f0bba40c4a2e1a3ac7e4a85fd9cd (commit)
from eee6c3cd63c08f999c400d864dd7f7de68c03b85 (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-test
- Log -----------------------------------------------------------------
commit f7dc45f72145f0bba40c4a2e1a3ac7e4a85fd9cd
Author: Volker Lendecke <vl at samba.org>
Date: Fri Feb 13 10:06:26 2009 -0800
Fix Coverity IDs 879 and 880 (RESOURCE_LEAK, REVERSE_INULL)
-----------------------------------------------------------------------
Summary of changes:
source/client/umount.cifs.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source/client/umount.cifs.c b/source/client/umount.cifs.c
index 81925ed..1227e7a 100644
--- a/source/client/umount.cifs.c
+++ b/source/client/umount.cifs.c
@@ -240,10 +240,9 @@ static int remove_from_mtab(char * mountpoint)
static char *
canonicalize(char *path)
{
- char *canonical = malloc (PATH_MAX + 1);
+ char *canonical;
- if (!canonical) {
- fprintf(stderr, "Error! Not enough memory!\n");
+ if (path == NULL) {
return NULL;
}
@@ -252,8 +251,12 @@ canonicalize(char *path)
return NULL;
}
- if (path == NULL)
+ canonical = (char *)malloc (PATH_MAX + 1);
+
+ if (!canonical) {
+ fprintf(stderr, "Error! Not enough memory!\n");
return NULL;
+ }
if (realpath (path, canonical))
return canonical;
--
Samba Shared Repository
More information about the samba-cvs
mailing list