media_harmony: Fix a crash bug
authorVolker Lendecke <vl@samba.org>
Thu, 11 Sep 2014 11:33:42 +0000 (11:33 +0000)
committerMichael Adam <obnox@samba.org>
Fri, 12 Sep 2014 00:45:40 +0000 (02:45 +0200)
Now that the dust has settled, fix a crash bug that was hidden behind
the warnings...

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Simo Sorce <idra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Fri Sep 12 02:45:40 CEST 2014 on sn-devel-104

source3/modules/vfs_media_harmony.c

index 7f499df..2418349 100644 (file)
@@ -490,8 +490,8 @@ static int alloc_get_client_smb_fname(struct vfs_handle_struct *handle,
        DEBUG(MH_INFO_DEBUG, ("Entering with smb_fname->base_name '%s'\n",
                              smb_fname->base_name));
 
-       clientFname = cp_smb_filename(ctx, smb_fname);
-       if (clientFname == NULL) {
+       *clientFname = cp_smb_filename(ctx, smb_fname);
+       if ((*clientFname) == NULL) {
                DEBUG(MH_ERR_DEBUG, ("alloc_get_client_smb_fname "
                                        "NTERR\n"));
                errno = ENOMEM;