Bug 1332134

Summary: bitrot: Build generates Compilation Warning.
Product: [Community] GlusterFS Reporter: Kotresh HR <khiremat>
Component: bitrotAssignee: Kotresh HR <khiremat>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact: bugs <bugs>
Priority: unspecified    
Version: mainlineCC: bugs
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-03-08 09:24:00 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 Kotresh HR 2016-05-02 10:45:25 UTC
Description of problem:
The build generates compilation warning ""initialization discards qualifiers
from pointer target type". But somehow it's not being shown by build machine
of master branch and caught on 3.7 branch. Since this is actual warning, needs fix in master branch too.
This is introduced by http://review.gluster.org/#/c/14044/

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

How reproducible:
always

Steps to Reproduce:
1. build gluster from source
2.
3.

Actual results:
Generates compilation warning

Expected results:
There should be no compilation warnings during build!

Additional info:

Comment 1 Vijay Bellur 2016-05-02 10:46:48 UTC
REVIEW: http://review.gluster.org/14146 (features/bitrot: Fix Compilation Warning!!!) posted (#2) for review on master by Kotresh HR (khiremat)

Comment 2 Vijay Bellur 2016-05-02 16:43:08 UTC
REVIEW: http://review.gluster.org/14146 (features/bitrot: Fix Compilation Warning!!!) posted (#3) for review on master by Kotresh HR (khiremat)

Comment 3 Vijay Bellur 2016-05-02 18:04:34 UTC
COMMIT: http://review.gluster.org/14146 committed in master by Jeff Darcy (jdarcy) 
------
commit 19264ccb20070798121d2ebfb3a0d2b1fb7a03bb
Author: Kotresh HR <khiremat>
Date:   Mon May 2 15:33:13 2016 +0530

    features/bitrot: Fix Compilation Warning!!!
    
    Earlier the lock  was using glusterfs macros
    LOCK/UNLOCK/LOCK_INIT/LOCK_DESTROY. The patch
    http://review.gluster.org/#/c/14140/ used 'pthread_cleanup_push'
    interface for the same lock which was giving "initialization
    discards qualifiers from pointer target type". It's strange that
    the build succeeded in master branch with no warnings but fails for
    the backport http://review.gluster.org/#/c/14140/ in 3.7 branch
    treating this warning as error.
    
    Change-Id: I75c8a65a2bfb1147fe9a84cfd8f09a97c089ae70
    BUG: 1332134
    Signed-off-by: Kotresh HR <khiremat>
    Reviewed-on: http://review.gluster.org/14146
    NetBSD-regression: NetBSD Build System <jenkins.org>
    CentOS-regression: Gluster Build System <jenkins.com>
    Smoke: Gluster Build System <jenkins.com>
    Reviewed-by: Jeff Darcy <jdarcy>

Comment 4 Kotresh HR 2017-03-08 09:24:00 UTC
v3.10.0 contains the fix.