s3: Remove an unneeded check
authorVolker Lendecke <vl@samba.org>
Sat, 29 Jan 2011 13:07:59 +0000 (14:07 +0100)
committerVolker Lendecke <vlendec@samba.org>
Sat, 29 Jan 2011 14:00:09 +0000 (15:00 +0100)
In many other places we already assume that if asprintf returns !=-1 then the
result is allocated.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat Jan 29 15:00:09 CET 2011 on sn-devel-104

source3/libsmb/smb_share_modes.c

index fd5f0ea2271f1d6223d67f1773e58358d57866cc..31745008204655375abe9742507d464e061409ea 100644 (file)
@@ -272,7 +272,7 @@ static uint32_t smb_name_hash(const char *sharepath, const char *filename, int *
 
        *err = 0;
        ret = asprintf(&fullpath, "%s/%s", sharepath, filename);
-       if (ret == -1 || fullpath == NULL) {
+       if (ret == -1) {
                *err = 1;
                return 0;
        }