Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segfault when destroying WinToast #5601

Closed
4 tasks done
Nerixyz opened this issue Sep 22, 2024 · 0 comments · Fixed by #5728
Closed
4 tasks done

Segfault when destroying WinToast #5601

Nerixyz opened this issue Sep 22, 2024 · 0 comments · Fixed by #5728

Comments

@Nerixyz
Copy link
Contributor

Nerixyz commented Sep 22, 2024

Checklist

  • I'm reporting a problem with Chatterino
  • I've verified that I'm running the most recent nightly build or stable release
  • I've looked for my problem on the wiki
  • I've searched the issues and pull requests for similar looking reports

Describe your issue

When closing Chatterino yesterday, I got a crash while destroying WinToast. It's not regular, I got this yesterday for the first time.

This might not be a bug in Chatterino, but in WinToast or some Windows internals.

Stack
  • [0x0] ntdll!NtDelayExecution+0x14
  • [0x1] KERNELBASE!SleepEx+0x9e
  • [0x2] chatterino!crashpad::'anonymous namespace'::UnhandledExceptionHandler+0xde
  • [0x3] KERNELBASE!UnhandledExceptionFilter+0x1e7
  • [0x4] ntdll!RtlUserThreadStart$filt$0+0xa2
  • [0x5] ntdll!_C_specific_handler+0x96
  • [0x6] ntdll!RtlpExecuteHandlerForException+0xf
  • [0x7] ntdll!RtlDispatchException+0x244
  • [0x8] ntdll!KiUserExceptionDispatch+0x2e
  • [0x9] wpnapps!Microsoft::WRL::ComPtr<WpnNotificationData>::InternalRelease+0x14
  • [0xa] wpnapps!Microsoft::WRL::ComPtr<Windows::Data::Xml::Dom::IXmlDocument>::{dtor}+0x5 (Inline Function)
  • [0xb] wpnapps!BaseNotification::~BaseNotification+0x96
  • [0xc] wpnapps!ToastNotificationImpl::'scalar deleting destructor'+0x14
  • [0xd] wpnapps!Microsoft::WRL::Details::RuntimeClassImpl<Microsoft::WRL::RuntimeClassFlags<1>,1,1,0,Microsoft::WRL::Implements<Windows::UI::Notifications::IToastNotification,Windows::UI::Notifications::IToastNotification2,Windows::UI::Notifications::IToastNotification3,Windows::UI::Notifications::IToastNotification4,IInspectable,Windows::UI::Notifications::IToastNotification6,Windows::UI::Notifications::Internal::IPostNotification,Microsoft::WRL::CloakedIid<Windows::UI::Notifications::Internal::IToastNotificationInternal> >,BaseNotification,Microsoft::WRL::FtmBase>::Release+0x65
  • [0xe] chatterino!Microsoft::WRL::ComPtr<ABI::Windows::UI::Notifications::IToastNotification>::InternalRelease+0x15 (Inline Function)
  • [0xf] chatterino!Microsoft::WRL::ComPtr<ABI::Windows::UI::Notifications::IToastNotification>::{dtor}+0x15 (Inline Function)
  • 0x10 chatterino!WinToastLib::WinToast::NotifyData::~NotifyData+0x5a
  • [0x11] chatterino!std::_Tree_val<std::_Tree_simple_types<std::pair<__int64 const ,WinToastLib::WinToast::NotifyData> > >::_Erase_tree<std::allocator<std::_Tree_node<std::pair<__int64 const ,WinToastLib::WinToast::NotifyData>,void *> > >+0x4e
  • [0x12] chatterino!std::_Tree_val<std::_Tree_simple_types<std::pair<__int64 const ,WinToastLib::WinToast::NotifyData> > >::_Erase_head+0x15 (Inline Function)
  • [0x13] chatterino!std::_Tree<std::_Tmap_traits<__int64,WinToastLib::WinToast::NotifyData,std::less<__int64>,std::allocator<std::pair<__int64 const ,WinToastLib::WinToast::NotifyData> >,0> >::{dtor}+0x15 (Inline Function)
  • 0x14 chatterino!WinToastLib::WinToast::~WinToast+0x3d
  • [0x15] chatterino!__dyn_tls_dtor+0x63
  • [0x16] ucrtbase!<lambda_ad52fe89635f51ec3b38e9c3ac6dac81>::operator()+0x68
  • [0x17] ucrtbase!__crt_seh_guarded_call<void>::operator()<<lambda_123965863b7b46a3332720573f9ce793>,<lambda_ad52fe89635f51ec3b38e9c3ac6dac81> &,<lambda_8d528b66de6ae1e796d7f5e3101fca72> >+0x3b
  • [0x18] ucrtbase!common_exit+0x5e
  • [0x19] chatterino!__scrt_common_main_seh+0x168
  • [0x1a] KERNEL32!BaseThreadInitThunk+0x14
  • [0x1b] ntdll!RtlUserThreadStart+0x21

Seems like it's mohabouje/WinToast#44 - we could call clear() when exiting.

Screenshots

No response

OS and Chatterino Version

Chatterino Nightly 7.5.1 (commit facd28a) built on 2024-09-02 with Qt 6.7.1, MSVC 194134120, Crashpad Running on Windows 10 Version 22H2, kernel: 10.0.19045

@Nerixyz Nerixyz added the issue-report An issue reported by a user. label Sep 22, 2024
@pajlada pajlada added crash OS: Windows and removed issue-report An issue reported by a user. labels Nov 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants