Closed
Bug 1491742
Opened 6 years ago
Closed 6 years ago
UBSan: load of value which is not a valid value for type 'bool' in src/accessible/generic/ImageAccessible.cpp:66
Categories
(Core :: Disability Access APIs, defect, P3)
Core
Disability Access APIs
Tracking
()
RESOLVED
FIXED
mozilla64
Tracking | Status | |
---|---|---|
firefox64 | --- | fixed |
People
(Reporter: tsmith, Assigned: surkov)
References
(Blocks 1 open bug)
Details
(Keywords: csectype-undefined, testcase)
Attachments
(2 files)
(deleted),
text/html
|
Details | |
(deleted),
patch
|
Jamie
:
review+
|
Details | Diff | Splinter Review |
The latest Linux ASan opt builds now include some UBSan checks.
Reduced with m-c:
BuildID=20180916213810
SourceStamp=5165e750ffabb930deb846410ab62dcc6d1f9e52
src/accessible/generic/ImageAccessible.cpp:66:9: runtime error: load of value 176, which is not a valid value for type 'bool'
#0 0x7f8cbd022f82 in mozilla::a11y::ImageAccessible::NativeState() const src/accessible/generic/ImageAccessible.cpp:66:9
#1 0x7f8cbcfd2899 in mozilla::a11y::Accessible::State() src/accessible/generic/Accessible.cpp:1206:20
#2 0x7f8cbcff8929 in AccStateChangeEvent src/accessible/base/AccEvent.h:154:34
#3 0x7f8cbcff8929 in mozilla::a11y::DocAccessible::AttributeChangedImpl(mozilla::a11y::Accessible*, int, nsAtom*) src/accessible/generic/DocAccessible.cpp:948
#4 0x7f8cbcff693b in mozilla::a11y::DocAccessible::AttributeChanged(mozilla::dom::Element*, int, nsAtom*, int, nsAttrValue const*) src/accessible/generic/DocAccessible.cpp:805:3
#5 0x7f8cb3c21867 in nsNodeUtils::AttributeChanged(mozilla::dom::Element*, int, nsAtom*, int, nsAttrValue const*) src/dom/base/nsNodeUtils.cpp:170:3
#6 0x7f8cb3819b4c in mozilla::dom::Element::UnsetAttr(int, nsAtom*, bool) src/dom/base/Element.cpp:3052:5
#7 0x7f8cb381bc86 in mozilla::dom::Element::RemoveAttribute(nsTSubstring<char16_t> const&, mozilla::ErrorResult&) src/dom/base/Element.cpp:1413:12
#8 0x7f8cb61f0c6b in mozilla::dom::Element_Binding::removeAttribute(JSContext*, JS::Handle<JSObject*>, mozilla::dom::Element*, JSJitMethodCallArgs const&) src/obj-firefox/dom/bindings/ElementBinding.cpp:1378:9
#9 0x7f8cb6acff90 in bool mozilla::dom::binding_detail::GenericMethod<mozilla::dom::binding_detail::NormalThisPolicy, mozilla::dom::binding_detail::ThrowExceptions>(JSContext*, unsigned int, JS::Value*) src/dom/bindings/BindingUtils.cpp:3296:13
#10 0x7f8cbf93b16b in CallJSNative src/js/src/vm/Interpreter.cpp:460:15
#11 0x7f8cbf93b16b in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct) src/js/src/vm/Interpreter.cpp:552
#12 0x7f8cbf923e46 in CallFromStack src/js/src/vm/Interpreter.cpp:612:12
#13 0x7f8cbf923e46 in Interpret(JSContext*, js::RunState&) src/js/src/vm/Interpreter.cpp:3439
#14 0x7f8cbf908a03 in js::RunScript(JSContext*, js::RunState&) src/js/src/vm/Interpreter.cpp:439:12
#15 0x7f8cbf93bc7e in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct) src/js/src/vm/Interpreter.cpp:579:15
#16 0x7f8cbf93da12 in js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>) src/js/src/vm/Interpreter.cpp:625:10
#17 0x7f8cbe9d744d in JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) src/js/src/jsapi.cpp:2959:12
#18 0x7f8cb608172a in mozilla::dom::EventHandlerNonNull::Call(JSContext*, JS::Handle<JS::Value>, mozilla::dom::Event&, JS::MutableHandle<JS::Value>, mozilla::ErrorResult&) src/obj-firefox/dom/bindings/EventHandlerBinding.cpp:264:37
#19 0x7f8cb736caba in void mozilla::dom::EventHandlerNonNull::Call<nsISupports*>(nsISupports* const&, mozilla::dom::Event&, JS::MutableHandle<JS::Value>, mozilla::ErrorResult&, char const*, mozilla::dom::CallbackObject::ExceptionHandling, JS::Realm*) src/obj-firefox/dist/include/mozilla/dom/EventHandlerBinding.h:363:12
#20 0x7f8cb7369f6e in mozilla::JSEventHandler::HandleEvent(mozilla::dom::Event*) src/dom/events/JSEventHandler.cpp:214:12
#21 0x7f8cb731d115 in mozilla::EventListenerManager::HandleEventSubType(mozilla::EventListenerManager::Listener*, mozilla::dom::Event*, mozilla::dom::EventTarget*) src/dom/events/EventListenerManager.cpp:1111:52
#22 0x7f8cb731f30c in mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) src/dom/events/EventListenerManager.cpp:1342:20
#23 0x7f8cb73031be in HandleEvent src/obj-firefox/dist/include/mozilla/EventListenerManager.h:390:5
#24 0x7f8cb73031be in mozilla::EventTargetChainItem::HandleEvent(mozilla::EventChainPostVisitor&, mozilla::ELMCreationDetector&) src/dom/events/EventDispatcher.cpp:420
#25 0x7f8cb73014e3 in mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) src/dom/events/EventDispatcher.cpp:637:16
#26 0x7f8cb7307db2 in mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) src/dom/events/EventDispatcher.cpp:1112:9
#27 0x7f8cb9f6d7c8 in nsDocumentViewer::LoadComplete(nsresult) src/layout/base/nsDocumentViewer.cpp:1167:7
#28 0x7f8cbcddb0e3 in nsDocShell::EndPageLoad(nsIWebProgress*, nsIChannel*, nsresult) src/docshell/base/nsDocShell.cpp:7088:21
#29 0x7f8cbcdd6157 in nsDocShell::OnStateChange(nsIWebProgress*, nsIRequest*, unsigned int, nsresult) src/docshell/base/nsDocShell.cpp:6881:7
#30 0x7f8cbcddf5a7 in non-virtual thunk to nsDocShell::OnStateChange(nsIWebProgress*, nsIRequest*, unsigned int, nsresult) src/docshell/base/nsDocShell.cpp
#31 0x7f8cb2171b85 in nsDocLoader::DoFireOnStateChange(nsIWebProgress*, nsIRequest*, int&, nsresult) src/uriloader/base/nsDocLoader.cpp:1309:3
#32 0x7f8cb217076c in nsDocLoader::doStopDocumentLoad(nsIRequest*, nsresult) src/uriloader/base/nsDocLoader.cpp:852:14
#33 0x7f8cb216c259 in nsDocLoader::DocLoaderIsEmpty(bool) src/uriloader/base/nsDocLoader.cpp:741:9
#34 0x7f8cb216eb32 in nsDocLoader::OnStopRequest(nsIRequest*, nsISupports*, nsresult) src/uriloader/base/nsDocLoader.cpp:627:5
#35 0x7f8cb2170294 in non-virtual thunk to nsDocLoader::OnStopRequest(nsIRequest*, nsISupports*, nsresult) src/uriloader/base/nsDocLoader.cpp
#36 0x7f8cafb43582 in mozilla::net::nsLoadGroup::RemoveRequest(nsIRequest*, nsISupports*, nsresult) src/netwerk/base/nsLoadGroup.cpp:629:28
#37 0x7f8cb33ec6e0 in imgRequestProxy::RemoveFromLoadGroup() src/image/imgRequestProxy.cpp:440:15
#38 0x7f8cb33f512f in imgRequestProxy::OnLoadComplete(bool) src/image/imgRequestProxy.cpp:1084:7
#39 0x7f8cb33e3adc in operator() src/image/ProgressTracker.cpp:358:13
#40 0x7f8cb33e3adc in void mozilla::image::ImageObserverNotifier<mozilla::image::ObserverTable const*>::operator()<void mozilla::image::SyncNotifyInternal<mozilla::image::ObserverTable const*>(mozilla::image::ObserverTable const* const&, bool, unsigned int, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&)::{lambda(mozilla::image::IProgressObserver*)#7}>(void mozilla::image::SyncNotifyInternal<mozilla::image::ObserverTable const*>(mozilla::image::ObserverTable const* const&, bool, unsigned int, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&)::{lambda(mozilla::image::IProgressObserver*)#7}) src/image/ProgressTracker.cpp:283
#41 0x7f8cb33e1386 in void mozilla::image::SyncNotifyInternal<mozilla::image::ObserverTable const*>(mozilla::image::ObserverTable const* const&, bool, unsigned int, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&) src/image/ProgressTracker.cpp:357:5
#42 0x7f8cb3332af1 in operator() src/image/ProgressTracker.cpp:378:5
#43 0x7f8cb3332af1 in Read<(lambda at src/image/ProgressTracker.cpp:377:19)> src/image/CopyOnWrite.h:179
#44 0x7f8cb3332af1 in mozilla::image::ProgressTracker::SyncNotifyProgress(unsigned int, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&) src/image/ProgressTracker.cpp:377
#45 0x7f8cb33408fc in mozilla::image::RasterImage::NotifyProgress(unsigned int, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&, mozilla::Maybe<unsigned int> const&, mozilla::image::DecoderFlags, mozilla::image::SurfaceFlags) src/image/RasterImage.cpp:1726:28
#46 0x7f8cb335a1de in NotifyForLoadEvent src/image/RasterImage.cpp:1001:3
#47 0x7f8cb335a1de in mozilla::image::RasterImage::NotifyDecodeComplete(mozilla::image::DecoderFinalStatus const&, mozilla::image::ImageMetadata const&, mozilla::image::DecoderTelemetry const&, unsigned int, mozilla::gfx::IntRectTyped<mozilla::gfx::UnknownUnits> const&, mozilla::Maybe<unsigned int> const&, mozilla::image::DecoderFlags, mozilla::image::SurfaceFlags) src/image/RasterImage.cpp:1808
#48 0x7f8cb332b564 in operator() src/image/IDecodingTask.cpp:130:12
#49 0x7f8cb332b564 in mozilla::detail::RunnableFunction<mozilla::image::IDecodingTask::NotifyDecodeComplete(mozilla::NotNull<mozilla::image::RasterImage*>, mozilla::NotNull<mozilla::image::Decoder*>)::$_2>::Run() src/xpcom/threads/nsThreadUtils.h:564
#50 0x7f8caf8bfd08 in nsThread::ProcessNextEvent(bool, bool*) src/xpcom/threads/nsThread.cpp:1161:14
#51 0x7f8caf8c8955 in NS_ProcessNextEvent(nsIThread*, bool) src/xpcom/threads/nsThreadUtils.cpp:519:10
#52 0x7f8cb0adead3 in mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) src/ipc/glue/MessagePump.cpp:97:21
#53 0x7f8cb09de3ec in RunInternal src/ipc/chromium/src/base/message_loop.cc:325:10
#54 0x7f8cb09de3ec in RunHandler src/ipc/chromium/src/base/message_loop.cc:318
#55 0x7f8cb09de3ec in MessageLoop::Run() src/ipc/chromium/src/base/message_loop.cc:298
#56 0x7f8cb96ee5a3 in nsBaseAppShell::Run() src/widget/nsBaseAppShell.cpp:158:27
#57 0x7f8cbdb874fe in XRE_RunAppShell() src/toolkit/xre/nsEmbedFunctions.cpp:944:22
#58 0x7f8cb09de3ec in RunInternal src/ipc/chromium/src/base/message_loop.cc:325:10
#59 0x7f8cb09de3ec in RunHandler src/ipc/chromium/src/base/message_loop.cc:318
#60 0x7f8cb09de3ec in MessageLoop::Run() src/ipc/chromium/src/base/message_loop.cc:298
#61 0x7f8cbdb86623 in XRE_InitChildProcess(int, char**, XREChildData const*) src/toolkit/xre/nsEmbedFunctions.cpp:770:34
#62 0x55d3b249db91 in content_process_main src/browser/app/../../ipc/contentproc/plugin-container.cpp:50:30
#63 0x55d3b249db91 in main src/browser/app/nsBrowserApp.cpp:287
#64 0x7f8cd1e8082f in __libc_start_main /build/glibc-Cl5G7W/glibc-2.23/csu/../csu/libc-start.c:291
#65 0x55d3b23ccf3c in _start (firefox+0x2cf3c)
Flags: in-testsuite?
Assignee | ||
Comment 1•6 years ago
|
||
it should fix the bug, there are implementations that don't always initialize output value https://dxr.mozilla.org/mozilla-central/search?q=%2Boverrides%3A%22imgIContainer%3A%3AGetAnimated%28bool+%2A%29%22
Assignee: nobody → surkov.alexander
Attachment #9010151 -
Flags: review?(jteh)
Assignee | ||
Updated•6 years ago
|
Priority: -- → P3
Updated•6 years ago
|
Attachment #9010151 -
Flags: review?(jteh) → review+
Pushed by surkov.alexander@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/7be2a431c9cb
UBSan: load of value which is not a valid value for type 'bool' in ImageAccessible.cpp, r=jamie
Comment 3•6 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
You need to log in
before you can comment on or make changes to this bug.
Description
•