FALL_THROUGH attribute and AIX build

Amitay Isaacs amitay at gmail.com
Fri Feb 22 04:12:42 UTC 2019


Hi Andreas,

On Thu, Feb 21, 2019 at 6:45 PM Andreas Schneider <asn at samba.org> wrote:
>
> On Thursday, February 21, 2019 4:40:11 AM CET Amitay Isaacs wrote:
> > Hi Andreas,
> >
> > On Tue, Feb 19, 2019 at 6:49 PM Andreas Schneider <asn at samba.org> wrote:
> > > On Tuesday, February 19, 2019 8:24:13 AM CET Amitay Isaacs via
> > > samba-technical>
> > > wrote:
> > > > Hi,
> > >
> > > Hi Amitay,
> > >
> > > > Attached is a potential patch to socket_wrapper.
> > >
> > > could you please fork https://gitlab.com/cwrap/socket_wrapper and push to
> > > your private branch to see if the CI succeeds with your change?
> >
> > CI fails mysteriously with following error which doesn't make sense
> > because I have removed those lines.
> >
> > ----------------------------
> > [  1%] Building C object
> > src/CMakeFiles/socket_wrapper.dir/socket_wrapper.c.o
> > /builds/amitayisaacs/socket_wrapper/src/socket_wrapper.c:613:3: error:
> > expected expression <--[clang]
> >                 FALL_THROUGH;
> >                 ^
> > /builds/amitayisaacs/socket_wrapper/src/socket_wrapper.c:632:3: error:
> > expected expression <--[clang]
> >                 FALL_THROUGH;
> >                 ^
> > 2 errors generated.
> > ----------------------------
> >
> > I can build using clang 7.0.1 with -DPICKY_DEVELOPER on my laptop (fedora
> > 29).
>
> That doesn't seem to be a problem.
>
> It fails because what it found in "ADDED DEFECTS". Could you fix those too,
> then it should be fine :-)

If I added the defects because of my code change, I would be happy to
fix them. However the added defects have nothing to do with my code
change.

Can you explain how is the following added defect is related to my
removing FALL_THROUGH attribute in a completely different function?

---------------------------
Error: CLANG_WARNING:
src/socket_wrapper.c:2542:3: warning: Value stored to 'wire_hdr_len'
is never read
#                wire_hdr_len += icmp_hdr_len;
#                ^               ~~~~~~~~~~~~
src/socket_wrapper.c:2542:3: note: Value stored to 'wire_hdr_len' is never read
#                wire_hdr_len += icmp_hdr_len;
#                ^               ~~~~~~~~~~~~
# 2540|   icmp_truncate_len = wire_len - 64;
# 2541|   }
# 2542|-> wire_hdr_len += icmp_hdr_len;
# 2543|   wire_len += icmp_hdr_len;
# 2544|   }
---------------------------

I am not going to waste my time on some random errors reported by broken CI.

Amitay.



More information about the samba-technical mailing list