Closed Bug 1923274 Opened 4 months ago Closed 4 months ago

-Werror=dangling-pointer= - RootingAPI.h:1169:18: error: storing the address of local variable ‘reflector’

Categories

(Core :: JavaScript Engine, defect)

defect

Tracking

()

RESOLVED INVALID

People

(Reporter: Sylvestre, Unassigned)

References

(Blocks 1 open bug)

Details


/root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include/js/RootingAPI.h:1169:18: error: storing the address of local variable ‘reflector’ in ‘((js::StackRootedBase**)aCx)[3]’ [-Werror=dangling-pointer=]
 1169 |     *this->stack = this;
      |     ~~~~~~~~~~~~~^~~~~~
In file included from /root/firefox-gcc-last/accessible/aom/AccessibleNode.cpp:7:
Summary: RootingAPI.h:1169:18: error: storing the address of local variable ‘reflector’ → -Werror=dangling-pointer= - RootingAPI.h:1169:18: error: storing the address of local variable ‘reflector’
Component: Source Code Analysis → JavaScript Engine
Product: Developer Infrastructure → Core

This is a false positive: the locally stored variable is actually discarded in the class destructor, see https://searchfox.org/mozilla-central/source/js/public/RootingAPI.h#1224

Status: NEW → RESOLVED
Closed: 4 months ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.