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

Small Netplay dialog cleanups. #1528

Merged
merged 3 commits into from Nov 12, 2014
Merged

Conversation

lioncash
Copy link
Member

No description provided.

The text control is limited to 2000 characters on creation.
@waddlesplash
Copy link
Contributor

LGTM

lioncash added a commit that referenced this pull request Nov 12, 2014
Small Netplay dialog cleanups.
@lioncash lioncash merged commit 5a89ba2 into dolphin-emu:master Nov 12, 2014
@lioncash lioncash deleted the netplay branch November 12, 2014 02:19
@jcowgill
Copy link
Contributor

After the commit "NetPlayDiag: Get rid of event table" when I try to host a NetPlay game I get this:

Program received signal SIGSEGV, Segmentation fault.
wxString::AsChar (this=0x7fffd00009f0, conv=...) at ../src/common/string.cpp:540
540 ../src/common/string.cpp: No such file or directory.
(gdb) bt
#0  wxString::AsChar (this=0x7fffd00009f0, conv=...) at ../src/common/string.cpp:540
#1  0x00000000005c5eb1 in wxString::AsCharBuf (this=0x7fffd00009f0, conv=...) at /usr/include/wx-3.0/wx/string.h:3546
#2  0x00000000005c5e17 in wxString::mb_str (this=0x7fffd00009f0, conv=...) at /usr/include/wx-3.0/wx/string.h:1829
#3  0x00000000005e8a00 in wxString::utf8_str (this=0x7fffd00009f0) at /usr/include/wx-3.0/wx/string.h:1751
#4  0x00000000005e8a35 in wxString::ToUTF8 (this=0x7fffd00009f0) at /usr/include/wx-3.0/wx/string.h:1782
#5  0x0000000000625400 in WxStrToStr (str=...) at /home/james/deb-pkg/dolphin-emu/dolphin/Source/Core/DolphinWX/WxUtils.cpp:96
#6  0x00000000005f7155 in NetPlayDiag::OnThread (this=0x1d50c00, event=...)
    at /home/james/deb-pkg/dolphin-emu/dolphin/Source/Core/DolphinWX/NetWindow.cpp:579
#7  0x00007ffff28dcd5e in wxAppConsoleBase::CallEventHandler (this=0x1998510, handler=0x1d50c00, functor=..., event=...)
    at ../src/common/appbase.cpp:623
#8  0x00007ffff2a784c8 in wxEvtHandler::ProcessEventIfMatchesId (entry=..., handler=<optimized out>, event=...) at ../src/common/event.cpp:1392
#9  0x00007ffff2a788b6 in wxEvtHandler::SearchDynamicEventTable (this=0x1d50c00, event=...) at ../src/common/event.cpp:1751
#10 0x00007ffff2a7893e in wxEvtHandler::TryHereOnly (this=0x1d50c00, event=...) at ../src/common/event.cpp:1585
#11 0x00007ffff2a78a03 in TryBeforeAndHere (event=..., this=0x1d50c00) at ../include/wx/event.h:3671
#12 wxEvtHandler::ProcessEventLocally (this=0x1d50c00, event=...) at ../src/common/event.cpp:1522
#13 0x00007ffff2a78a65 in wxEvtHandler::ProcessEvent (this=0x1d50c00, event=...) at ../src/common/event.cpp:1495
#14 0x00007ffff2a79bf8 in wxEvtHandler::ProcessPendingEvents (this=0x1d50c00) at ../src/common/event.cpp:1359
#15 0x00007ffff28e0cd7 in wxAppConsoleBase::ProcessPendingEvents (this=0x1998510) at ../src/common/appbase.cpp:520
#16 0x00007ffff3670f62 in wxApp::DoIdle (this=0x1998510) at ../src/gtk/app.cpp:136
#17 0x00007ffff36710a3 in wxapp_idle_callback () at ../src/gtk/app.cpp:107
#18 0x00007ffff78f4b6d in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#19 0x00007ffff78f4f48 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#20 0x00007ffff78f5272 in g_main_loop_run () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#21 0x00007ffff572d4b7 in gtk_main () from /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#22 0x00007ffff36928a5 in wxGUIEventLoop::DoRun (this=0x1a2e570) at ../src/gtk/evtloop.cpp:65
#23 0x00007ffff2922d50 in wxEventLoopBase::Run (this=0x1a2e570) at ../src/common/evtloopcmn.cpp:78
#24 0x00007ffff28df086 in wxAppConsoleBase::MainLoop (this=0x1998510) at ../src/common/appbase.cpp:334
#25 0x00007ffff2979c20 in wxEntry (argc=<optimized out>, argv=<optimized out>) at ../src/common/init.cpp:495
#26 0x00000000005e6749 in main (argc=1, argv=0x7fffffffe208) at /home/james/deb-pkg/dolphin-emu/dolphin/Source/Core/DolphinWX/Main.cpp:90
(gdb) frame 6
#6  0x00000000005f7155 in NetPlayDiag::OnThread (this=0x1d50c00, event=...)
    at /home/james/deb-pkg/dolphin-emu/dolphin/Source/Core/DolphinWX/NetWindow.cpp:579
579         m_selected_game.assign(WxStrToStr(event.GetString()));
(gdb) print event
$1 = (wxThreadEvent &) @0x7fffd0000990: {<wxEvent> = {<wxObject> = {_vptr.wxObject = 0xd6e5d0 <vtable for wxCommandEvent@@WXU_3.0+16>, 
      static ms_classInfo = {m_className = 0x7ffff2aa3e10 L"wxObject", m_objectSize = 16, m_objectConstructor = 0x0, m_baseInfo1 = 0x0, 
        m_baseInfo2 = 0x0, static sm_first = 0x7ffff33f11e0 <wxAuiNotebookXmlHandler::ms_classInfo>, 
        m_next = 0x7ffff2d25ce0 <wxMemoryOutputStream::ms_classInfo>, static sm_classTable = 0x1934700}, m_refData = 0x0}, m_eventObject = 0x0, 
    m_eventType = 10005, m_timeStamp = 0, m_id = 45, m_callbackUserData = 0x0, m_handlerToProcessOnlyIn = 0x0, m_propagationLevel = 2147483647, 
    m_propagatedFrom = 0x0, m_skipped = false, m_isCommandEvent = true, m_wasProcessed = true, m_willBeProcessedAgain = false, 
    static ms_classInfo = {m_className = 0x7ffff2ab4438 L"wxEvent", m_objectSize = 88, m_objectConstructor = 0x0, 
      m_baseInfo1 = 0x7ffff2d25dc0 <wxObject::ms_classInfo>, m_baseInfo2 = 0x0, 
      static sm_first = 0x7ffff33f11e0 <wxAuiNotebookXmlHandler::ms_classInfo>, m_next = 0x7ffff2d28580 <wxEvtHandler::ms_classInfo>, 
      static sm_classTable = 0x1934700}}, <wxEventAnyPayloadMixin> = {<wxEventBasicPayloadMixin> = {m_cmdString = {
        static npos = 18446744073709551615, m_impl = <error reading variable: Cannot access memory at address 0xffffffffffffffe8>, 
        m_convertedToChar = {m_str = 0x4c00000041 <error: Cannot access memory at address 0x4c00000041>, m_len = 206158430208}}, m_commandInt = 0, 
      m_extraLong = 0}, m_payload = {m_buffer = {m_alignment = {m_int64 = 493921239145, m_longDouble = <invalid float value>, 
          m_funcPtr = 0x7300000069, m_mFuncPtr = &virtual table offset 493921239144, this adjustment 37}, m_ptr = 0x7300000069, 
        m_buffer = "i\000\000\000s\000\000\000%\000\000\000\000\000\000"}, m_type = 0x986210 <vtable for CSIDevice_Null+16>}}, 
  static ms_classInfo = {m_className = 0x7ffff2ab4488 L"wxThreadEvent", m_objectSize = 176, 
    m_objectConstructor = 0x7ffff2a77bf0 <wxThreadEvent::wxCreateObject()>, m_baseInfo1 = 0x7ffff2d28540 <wxEvent::ms_classInfo>, m_baseInfo2 = 0x0, 
    static sm_first = 0x7ffff33f11e0 <wxAuiNotebookXmlHandler::ms_classInfo>, m_next = 0x7ffff2d28500 <wxIdleEvent::ms_classInfo>, 
    static sm_classTable = 0x1934700}}

it looks like a wxCommandEvent was reinterpreted as a wxThreadEvent

@lioncash
Copy link
Member Author

I'll look into it

@OussamaDanba
Copy link
Contributor

Seems to be linux specific? Can't seem to reproduce it on Windows 8.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants