Closed Bug 1869457 Opened 7 months ago Closed 6 months ago

gecko/xpcom/base/AvailableMemoryWatcherLinux.cpp:133:36: runtime error: division by zero

Categories

(Core :: XPCOM, defect, P2)

Unspecified
Linux
defect

Tracking

()

RESOLVED FIXED
123 Branch
Tracking Status
firefox122 --- wontfix
firefox123 --- fixed

People

(Reporter: tsmith, Assigned: gsvelto)

References

(Blocks 2 open bugs)

Details

(Keywords: csectype-undefined, Whiteboard: [fuzzblocker])

Attachments

(1 file)

Found while fuzzing m-c 20231208-31a6430ad25b (--enable-address-sanitizer --enable-fuzzing)

This is being reported some what frequently but a reliable test cases is unavailable. I think this is related to when a OOM happens and when a check is performed.

/gecko/xpcom/base/AvailableMemoryWatcherLinux.cpp:133:36: runtime error: division by zero
    #0 0x7fe61dc49b32 in mozilla::nsAvailableMemoryWatcher::IsMemoryLow() /gecko/xpcom/base/AvailableMemoryWatcherLinux.cpp:133:36
    #1 0x7fe61dc9ef11 in operator() /gecko/xpcom/base/AvailableMemoryWatcherLinux.cpp:175:13
    #2 0x7fe61dc9ef11 in mozilla::detail::RunnableFunction<mozilla::nsAvailableMemoryWatcher::Notify(nsITimer*)::$_0>::Run() /builds/worker/workspace/obj-build/dist/include/nsThreadUtils.h:548:5
    #3 0x7fe61df1371d in nsThread::ProcessNextEvent(bool, bool*) /gecko/xpcom/threads/nsThread.cpp:1193:16
    #4 0x7fe61df20fda in NS_ProcessNextEvent(nsIThread*, bool) /gecko/xpcom/threads/nsThreadUtils.cpp:480:10
    #5 0x7fe61fba2b99 in mozilla::ipc::MessagePumpForNonMainThreads::Run(base::MessagePump::Delegate*) /gecko/ipc/glue/MessagePump.cpp:330:5
    #6 0x7fe61f9c956a in RunInternal /gecko/ipc/chromium/src/base/message_loop.cc:370:10
    #7 0x7fe61f9c956a in RunHandler /gecko/ipc/chromium/src/base/message_loop.cc:363:3
    #8 0x7fe61f9c956a in MessageLoop::Run() /gecko/ipc/chromium/src/base/message_loop.cc:345:3
    #9 0x7fe61df09f70 in nsThread::ThreadFunc(void*) /gecko/xpcom/threads/nsThread.cpp:370:10
    #10 0x7fe6458eb11f in _pt_root /gecko/nsprpub/pr/src/pthreads/ptthread.c:201:5
    #11 0x55ee88eeb74a in asan_thread_start(void*) /builds/worker/fetches/llvm-project/compiler-rt/lib/asan/asan_interceptors.cpp:225:31
    #12 0x7fe6460caac2 in start_thread nptl/pthread_create.c:442:8
    #13 0x7fe64615b813 in __clone misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:100
See Also: → 1869600
Assignee: nobody → gsvelto
Status: NEW → ASSIGNED
Whiteboard: [fuzzblocker]
Severity: -- → S3
Priority: -- → P2
Pushed by gsvelto@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/b1c8877fa4c8
Don't attempt to compute low-memory conditions if we don't know how much memory is in the system r=KrisWright
Blocks: site-scout
Status: ASSIGNED → RESOLVED
Closed: 6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 123 Branch

The patch landed in nightly and beta is affected.
:gsvelto, is this bug important enough to require an uplift?

  • If yes, please nominate the patch for beta approval.
  • If no, please set status-firefox122 to wontfix.

For more information, please visit BugBot documentation.

Flags: needinfo?(gsvelto)

This is not worth uplifting

Flags: needinfo?(gsvelto)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: