Closed
Bug 1383007
Opened 7 years ago
Closed 7 years ago
security/sandbox/linux/SandboxFilter.cpp: statement will never be executed [-Werror=switch-unreachable]
Categories
(Core :: Security: Process Sandboxing, defect)
Core
Security: Process Sandboxing
Tracking
()
RESOLVED
FIXED
mozilla56
Tracking | Status | |
---|---|---|
firefox56 | --- | fixed |
People
(Reporter: Sylvestre, Assigned: Sylvestre)
References
Details
Attachments
(1 file)
+++ This bug was initially created as a clone of Bug #1371626 +++
Fails the build with gcc 7.1 & --enable-warnings-as-errors
/usr/bin/g++-7 -std=gnu++11 -o SandboxChroot.o -c -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/system_wrappers -include /root/firefox-gcc-last/config/gcc_hidden.h -DDEBUG=1 -DNS_NO_XPCOM -I/root/firefox-gcc-last/security/sandbox/linux -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/security/sandbox/linux -I/root/firefox-gcc-last/security/sandbox/linux -I/root/firefox-gcc-last/security/sandbox/chromium-shim -I/root/firefox-gcc-last/security/sandbox/chromium -I/root/firefox-gcc-last/nsprpub -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include/nspr -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/mozilla-config.h -MD -MP -MF .deps/SandboxChroot.o.pp -Wall -Wc++11-compat -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wsign-compare -Wtype-limits -Wunreachable-code -Wwrite-strings -Wno-invalid-offsetof -Wc++14-compat -Wc++1z-compat -Wno-error=maybe-uninitialized -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=free-nonheap-object -Wformat -Wformat-overflow=2 -fno-exceptions -fno-strict-aliasing -fno-rtti -fno-exceptions -fno-math-errno -pthread -pipe -g -freorder-blocks -Os -fno-omit-frame-pointer -Werror -Wno-shadow /root/firefox-gcc-last/security/sandbox/linux/SandboxChroot.cpp
/usr/bin/g++-7 -std=gnu++11 -o SandboxFilter.o -c -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/system_wrappers -include /root/firefox-gcc-last/config/gcc_hidden.h -DDEBUG=1 -DNS_NO_XPCOM -I/root/firefox-gcc-last/security/sandbox/linux -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/security/sandbox/linux -I/root/firefox-gcc-last/security/sandbox/linux -I/root/firefox-gcc-last/security/sandbox/chromium-shim -I/root/firefox-gcc-last/security/sandbox/chromium -I/root/firefox-gcc-last/nsprpub -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include/nspr -I/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/mozilla-config.h -MD -MP -MF .deps/SandboxFilter.o.pp -Wall -Wc++11-compat -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wsign-compare -Wtype-limits -Wunreachable-code -Wwrite-strings -Wno-invalid-offsetof -Wc++14-compat -Wc++1z-compat -Wno-error=maybe-uninitialized -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=free-nonheap-object -Wformat -Wformat-overflow=2 -fno-exceptions -fno-strict-aliasing -fno-rtti -fno-exceptions -fno-math-errno -pthread -pipe -g -freorder-blocks -Os -fno-omit-frame-pointer -Werror -Wno-shadow /root/firefox-gcc-last/security/sandbox/linux/SandboxFilter.cpp
/root/firefox-gcc-last/security/sandbox/linux/SandboxFilter.cpp: In member function 'virtual mozilla::Maybe<std::shared_ptr<const sandbox::bpf_dsl::internal::ResultExprImpl> > mozilla::ContentSandboxPolicy::EvaluateIpcCall(int) const':
/root/firefox-gcc-last/security/sandbox/linux/SandboxFilter.cpp:578:24: error: statement will never be executed [-Werror=switch-unreachable]
return Some(Allow());
Comment hidden (mozreview-request) |
Comment 2•7 years ago
|
||
mozreview-review |
Comment on attachment 8888729 [details]
Bug 1383007 - Move the declaration in the #ifdef declaration to silent a warning
https://reviewboard.mozilla.org/r/159756/#review165194
r=me for the sandbox change; thanks for the fix.
::: build/moz.configure/toolchain.configure:1186
(Diff revision 1)
> +@depends('--enable-linker', select_linker, c_compiler)
> +def select_linker(value, gold, c_compiler):
> + if linker == 'lld':
> + if c_compiler.type != 'clang':
> + die("lld requires clang (version >= 3.8)")
> + return "-fuse-ld=" + linker
Did you mean to include this change? This would need a build peer.
Attachment #8888729 -
Flags: review?(jld) → review+
Comment hidden (mozreview-request) |
Assignee | ||
Comment 4•7 years ago
|
||
mozreview-review-reply |
Comment on attachment 8888729 [details]
Bug 1383007 - Move the declaration in the #ifdef declaration to silent a warning
https://reviewboard.mozilla.org/r/159756/#review165194
> Did you mean to include this change? This would need a build peer.
oups, my bad. fixed
Pushed by sledru@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/394b3d22db19
Move the declaration in the #ifdef declaration to silent a warning r=jld
Comment 6•7 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox56:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
Backout by jedavis@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1efacc8c49ba
Backed out 3 changesets (bug 1383007, bug 1376910)
Updated•7 years ago
|
status-firefox57:
affected → ---
You need to log in
before you can comment on or make changes to this bug.
Description
•