Status: Unconfirmed
Owner: ----
Labels: OS-Linux Area-Misc Type-Bug

New issue 25466 by rdwald: Compile failure in  
src/net/websockets/websocket.cc:383: suggest parentheses around + or - in  
operand of &
http://code.google.com/p/chromium/issues/detail?id=25466

Chrome Version       : 4.0.224.0 (29589)
OS + version : Gentoo Linux
CPU architecture (32-bit / 64-bit): amd64
window manager : xmonad
URLs (if applicable) : n/a
Behavior in Firefox 3.x (if applicable): n/a
Behavior in Chrome for Windows (optional): n/a

What steps will reproduce the problem?
1. Attempt to compile Chromium

What is the expected result?
scons: done building targets

What happens instead?
cc1plus: warnings being treated as errors
/home/rwald/chromium/src/net/websockets/websocket.cc: In member function
'void net::WebSocket::ProcessFrameData()':
/home/rwald/chromium/src/net/websockets/websocket.cc:383: error: suggest
parentheses around + or - in operand of &
scons: ***
[/home/rwald/chromium/src/sconsbuild/Release/obj/net/net/websockets/websock
et.o] Error 1
scons: building terminated because of errors.

Pretty clear-cut: gcc is throwing a warning over the following line, and
because warnings are being treated as errors, it stops the build:

length = length * 128 + *p & 0x7f;

Since binary + takes precedence over unary &, I'm guessing the proper
parentheses would be:

length = ((length * 128) + *p) & 0x7f;

So if someone with commit access could make the appropriate changes to the
code, this bug would go away.

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--~--~---------~--~----~------------~-------~--~----~
Automated mail from issue updates at http://crbug.com/
Subscription options: http://groups.google.com/group/chromium-bugs
-~----------~----~----~----~------~----~------~--~---

Reply via email to