wxWidgets / wxWidgets

Cross-Platform C++ GUI Library
https://www.wxwidgets.org/
6.15k stars 1.77k forks source link

SIGSEGV in wxAnyValueTypeImpl when usign libraries compiled with --enable-no_rtti #24657

Closed leonid-galperin closed 3 weeks ago

leonid-galperin commented 4 months ago

Description

I try to run simple empty window application using static libraries compiled with the following configuration

--disable-shared  --with-gtk=3 --disable-sys-libs --disable-tests --disable-precomp-headers

Bug description:

When I close window I receive SIGSEGV

Stack trace:

Thread 1 "BWVControlCente" received signal SIGSEGV, Segmentation fault.
0x0000555555e33b6f in wxAnyValueTypeImpl<wxAnyList>::IsSameType(wxAnyValueType const*) const ()
(gdb) bt
#0  0x0000555555e33b6f in wxAnyValueTypeImpl<wxAnyList>::IsSameType(wxAnyValueType const*) const ()
#1  0x00005555558aff67 in wxAnyValueTypeScopedPtr::~wxAnyValueTypeScopedPtr()
    (this=0x555556287078 <wxAnyValueTypeImpl<wxAnyList>::sm_instance>, __in_chrg=<optimized out>)
    at ./../../common/libs/wx_3.2/include/wx/any.h:134
#2  0x00007ffff6845495 in __run_exit_handlers
    (status=0, listp=0x7ffff6a1a838 <__exit_funcs>, run_list_atexit=run_list_atexit@entry=true, run_dtors=run_dtors@entry=true) at ./stdlib/exit.c:113
#3  0x00007ffff6845610 in __GI_exit (status=<optimized out>) at ./stdlib/exit.c:143
#4  0x00007ffff6829d97 in __libc_start_call_main
     (main=main@entry=0x55555589395b <main(int, char**)>, argc=argc@entry=1, argv=argv@entry=0x7fffffffe4a8)
    at ../sysdeps/nptl/libc_start_call_main.h:74
#5  0x00007ffff6829e40 in __libc_start_main_impl
     (main=0x55555589395b <main(int, char**)>, argc=1, argv=0x7fffffffe4a8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffffffe498) at ../csu/libc-start.c:392
#6  0x00005555557e3fc5 in _start () 

Patch or snippet allowing to reproduce the problem:

To Reproduce:

  1. Remove flag "--enable-no_rtti" from configuration
  2. Recompile libraries
  3. Recompile application
  4. Platform and version information

oneeyeman1 commented 4 months ago

@leonid-galperin , What code leads to this? Can it be seen in the minimal sample? If nor - can you post a patch reproducing the crash?

Thank you.

vadz commented 4 months ago

Sorry, what do you mean by Remove flag "--enable-no_rtti" from configuration, i.e. which configuration? Did you accidentally omit this flag from configure options you listed at the top? Otherwise this doesn't make sense to me...

It would indeed be also useful to know if the problem can be reproduced in the sample.

github-actions[bot] commented 3 weeks ago

This issue has been automatically closed because there has been no response to our request for more information from the original author since 100 days and we're unable to do anything about the problem without more information. Please comment on this issue if you can provide any additional data so that we could investigate it further.