Bug 1402254

Summary: compile warning unused variable
Product: [Community] GlusterFS Reporter: Michael Adam <madam>
Component: glusterdAssignee: Michael Adam <madam>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: low Docs Contact:
Priority: unspecified    
Version: mainlineCC: amukherj, bugs
Target Milestone: ---Keywords: EasyFix, Triaged
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: glusterfs-3.11.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-05-30 18:37:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michael Adam 2016-12-07 06:53:19 UTC
Description of problem:

When compiling without bd xlator, we get a warning:

  CC       glusterd_la-glusterd-utils.lo
glusterd-utils.c: In function ‘glusterd_brickinfo_new_from_brick’:
glusterd-utils.c:1081:33: warning: variable ‘vg’ set but not used [-Wunused-but-set-variable]
         char                   *vg            = NULL;
                                 ^~


Version-Release number of selected component (if applicable):

master

How reproducible:

always

Steps to Reproduce:
1. ./configure
2. make
3. look at output

Actual results:

get compiler warning

Expected results:

don't get compiler warning
Additional info:

Comment 1 Michael Adam 2016-12-07 06:53:39 UTC
patch coming...

Comment 2 Worker Ant 2016-12-07 06:55:43 UTC
REVIEW: http://review.gluster.org/16049 (glusterd: fix compiler warning (unused var) if bd xlator is not enabled) posted (#1) for review on master by Michael Adam (obnox)

Comment 3 Worker Ant 2017-01-27 08:09:24 UTC
REVIEW: https://review.gluster.org/16049 (glusterd: fix compiler warning (unused var) if bd xlator is not enabled) posted (#2) for review on master by Atin Mukherjee (amukherj)

Comment 4 Worker Ant 2017-01-31 04:18:20 UTC
REVIEW: https://review.gluster.org/16049 (glusterd: fix compiler warning (unused var) if bd xlator is not enabled) posted (#3) for review on master by Atin Mukherjee (amukherj)

Comment 5 Worker Ant 2017-01-31 07:55:38 UTC
COMMIT: https://review.gluster.org/16049 committed in master by Atin Mukherjee (amukherj) 
------
commit 7292905c3a3291a98b55b36aed713a10553d7523
Author: Michael Adam <obnox>
Date:   Wed Dec 7 07:45:57 2016 +0100

    glusterd: fix compiler warning (unused var) if bd xlator is not enabled
    
    BUG: 1402254
    
    Change-Id: Id4450c5e00e9eb6d63dcdf65b0a13bc535a32d98
    Signed-off-by: Michael Adam <obnox>
    Reviewed-on: https://review.gluster.org/16049
    Tested-by: Atin Mukherjee <amukherj>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    Smoke: Gluster Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.org>
    Reviewed-by: Atin Mukherjee <amukherj>

Comment 6 Shyamsundar 2017-05-30 18:37:22 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.11.0, please open a new bug report.

glusterfs-3.11.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://lists.gluster.org/pipermail/announce/2017-May/000073.html
[2] https://www.gluster.org/pipermail/gluster-users/