Hi,
some more information:
the error described in the last mail is a consecutive fault of another
error:
FXRuby crashed in FXRbWindow::markfunc:
// Mark child windows
register FXWindow* child=self->getFirst();
while(child!=NULL){
FXRbGcMark(child);
child=child->getNext(); <------ child is 0x00000004!!!!
}
}
The error is catched by the ruby error handler. The handler calls abort.
Abort shows another message box and FXRuby crashes a second time with this
box.
Maybe this is a Qnil??? How does it get into the list of children?
FXRbWindow::markfunc(FX::FXWindow * 0x037b8f28) line 170 + 3 bytes
FXRbComposite::markfunc(FX::FXComposite * 0x037b8f28) line 117 + 9 bytes
FXRbRootWindow::markfunc(FX::FXRootWindow * 0x037b8f28) line 839 + 9 bytes
FXRbApp::markfunc(FX::FXApp * 0x032049a8) line 310 + 24 bytes
MSVCRT-RUBY18! 1003d300()
MSVCRT-RUBY18! 1003cf50()
MSVCRT-RUBY18! 1003cf6e()
FXRbGcMark(void * 0x032049a8) line 340 + 9 bytes
FXRbId::markfunc(FX::FXId * 0x037c20b0) line 130 + 18 bytes
FXRbDrawable::markfunc(FX::FXDrawable * 0x037c20b0) line 122 + 9 bytes
FXRbWindow::markfunc(FX::FXWindow * 0x037c20b0) line 152 + 9 bytes
FXRbComposite::markfunc(FX::FXComposite * 0x037c20b0) line 117 + 9 bytes
FXRbTextField::markfunc(FX::FXTextField * 0x037c20b0) line 881 + 9 bytes
Hello fxruby-users,
does anybody have experience with FXRuby and multithreading?
My Problem:
- I populate a FXTreeList widget with items. This is done in an extra worker
thread, as this task takes some minutes
- In the meantime, the user can continue to work with the application.
All works fine, until the user opens a modal window (e.g. a FXMessageBox).
Sometimes FXRuby crashes with an acess violation in FXWindow::getShell:
while((p=win->parent) && p->parent) win=p;
p seems to be invalid in this situation
The this-pointer seems to be ok and points to the MXMessageBox.
The processed message is a WM_KILLFOCUS message
FX::FXWindow::getShell() line 383 + 18 bytes
FX::FXApp::dispatchEvent(void * 0x002b1b58, unsigned int 8, unsigned int 0,
long 0) line 3943 + 8 bytes
FX::FXApp::wndproc(void * 0x002b1b58, unsigned int 8, unsigned int 0, long
0) line 3446
USER32! InternalCallWinProc@20 + 27 bytes
USER32! UserCallWinProcCheckWow@32 + 183 bytes
USER32! DispatchClientMessage@20 + 77 bytes
USER32! __fnDWORD@4 + 34 bytes
NTDLL! KiUserCallbackDispatcher@12 + 19 bytes
USER32! 77d49105()
USER32! SoftModalMessageBox@4 + 1380 bytes
USER32! MessageBoxWorker@4 + 314 bytes
USER32! MessageBoxTimeoutW@24 + 89 bytes
USER32! SoftModalMessageBox@4 + 1380 bytes
USER32! MessageBoxWorker@4 + 314 bytes
USER32! MessageBoxTimeoutW@24 + 89 bytes
USER32! MessageBoxWorker@4 + 314 bytes
USER32! MessageBoxTimeoutA@24 + 111 bytes
NTDLL! RtlImageDirectoryEntryToData@16 + 61 bytes
023f83dc()
ruby 1.8.2
fxruby 1.2.6
regards
Dirk
--
5 GB Mailbox, 50 FreeSMS http://www.gmx.net/de/go/promail
+++ GMX - die erste Adresse f?r Mail, Message, More +++
--
GMX DSL = Maximale Leistung zum minimalen Preis!
2000 MB nur 2,99, Flatrate ab 4,99 Euro/Monat: http://www.gmx.net/de/go/dsl
Hello,
the problem can be reproduced with the groupbox.rbw example:
- take the example file groupbox.rbw
- add a GC.start in the clockThread
- start the programm
- Open the About dialog
--> the About box shows: FOX is a really, really cool C++ library!
--> Windows XP says: Access Violation at address 0x02cd05a3
I''m using Ruby 1.8.2
Best regards
Dirk
Hi,
some more information:
the error described in the last mail is a consecutive fault of another
error:
FXRuby crashed in FXRbWindow::markfunc:
// Mark child windows
register FXWindow* child=self->getFirst();
while(child!=NULL){
FXRbGcMark(child);
child=child->getNext(); <------ child is 0x00000004!!!!
}
}
The error is catched by the ruby error handler. The handler calls abort.
Abort shows another message box and FXRuby crashes a second time with this
box.
Maybe this is a Qnil??? How does it get into the list of children?
FXRbWindow::markfunc(FX::FXWindow * 0x037b8f28) line 170 + 3 bytes
FXRbComposite::markfunc(FX::FXComposite * 0x037b8f28) line 117 + 9 bytes
FXRbRootWindow::markfunc(FX::FXRootWindow * 0x037b8f28) line 839 + 9 bytes
FXRbApp::markfunc(FX::FXApp * 0x032049a8) line 310 + 24 bytes
MSVCRT-RUBY18! 1003d300()
MSVCRT-RUBY18! 1003cf50()
MSVCRT-RUBY18! 1003cf6e()
FXRbGcMark(void * 0x032049a8) line 340 + 9 bytes
FXRbId::markfunc(FX::FXId * 0x037c20b0) line 130 + 18 bytes
FXRbDrawable::markfunc(FX::FXDrawable * 0x037c20b0) line 122 + 9 bytes
FXRbWindow::markfunc(FX::FXWindow * 0x037c20b0) line 152 + 9 bytes
FXRbComposite::markfunc(FX::FXComposite * 0x037c20b0) line 117 + 9 bytes
FXRbTextField::markfunc(FX::FXTextField * 0x037c20b0) line 881 + 9 bytes
Hello fxruby-users,
does anybody have experience with FXRuby and multithreading?
My Problem:
- I populate a FXTreeList widget with items. This is done in an extra worker
thread, as this task takes some minutes
- In the meantime, the user can continue to work with the application.
All works fine, until the user opens a modal window (e.g. a FXMessageBox).
Sometimes FXRuby crashes with an acess violation in FXWindow::getShell:
while((p=win->parent) && p->parent) win=p;
p seems to be invalid in this situation
The this-pointer seems to be ok and points to the MXMessageBox.
The processed message is a WM_KILLFOCUS message
FX::FXWindow::getShell() line 383 + 18 bytes
FX::FXApp::dispatchEvent(void * 0x002b1b58, unsigned int 8, unsigned int 0,
long 0) line 3943 + 8 bytes
FX::FXApp::wndproc(void * 0x002b1b58, unsigned int 8, unsigned int 0, long
0) line 3446
USER32! InternalCallWinProc@20 + 27 bytes
USER32! UserCallWinProcCheckWow@32 + 183 bytes
USER32! DispatchClientMessage@20 + 77 bytes
USER32! __fnDWORD@4 + 34 bytes
NTDLL! KiUserCallbackDispatcher@12 + 19 bytes
USER32! 77d49105()
USER32! SoftModalMessageBox@4 + 1380 bytes
USER32! MessageBoxWorker@4 + 314 bytes
USER32! MessageBoxTimeoutW@24 + 89 bytes
USER32! SoftModalMessageBox@4 + 1380 bytes
USER32! MessageBoxWorker@4 + 314 bytes
USER32! MessageBoxTimeoutW@24 + 89 bytes
USER32! MessageBoxWorker@4 + 314 bytes
USER32! MessageBoxTimeoutA@24 + 111 bytes
NTDLL! RtlImageDirectoryEntryToData@16 + 61 bytes
023f83dc()
ruby 1.8.2
fxruby 1.2.6
regards
Dirk
--
5 GB Mailbox, 50 FreeSMS http://www.gmx.net/de/go/promail
+++ GMX - die erste Adresse f?r Mail, Message, More +++
--
GMX DSL = Maximale Leistung zum minimalen Preis!
2000 MB nur 2,99, Flatrate ab 4,99 Euro/Monat: http://www.gmx.net/de/go/dsl
--
5 GB Mailbox, 50 FreeSMS http://www.gmx.net/de/go/promail
+++ GMX - die erste Adresse f?r Mail, Message, More +++
Hello fxruby-users, does anybody have experience with FXRuby and multithreading? My Problem: - I populate a FXTreeList widget with items. This is done in an extra worker thread, as this task takes some minutes - In the meantime, the user can continue to work with the application. All works fine, until the user opens a modal window (e.g. a FXMessageBox). Sometimes FXRuby crashes with an acess violation in FXWindow::getShell: while((p=win->parent) && p->parent) win=p; p seems to be invalid in this situation The this-pointer seems to be ok and points to the MXMessageBox. The processed message is a WM_KILLFOCUS message FX::FXWindow::getShell() line 383 + 18 bytes FX::FXApp::dispatchEvent(void * 0x002b1b58, unsigned int 8, unsigned int 0, long 0) line 3943 + 8 bytes FX::FXApp::wndproc(void * 0x002b1b58, unsigned int 8, unsigned int 0, long 0) line 3446 USER32! InternalCallWinProc@20 + 27 bytes USER32! UserCallWinProcCheckWow@32 + 183 bytes USER32! DispatchClientMessage@20 + 77 bytes USER32! __fnDWORD@4 + 34 bytes NTDLL! KiUserCallbackDispatcher@12 + 19 bytes USER32! 77d49105() USER32! SoftModalMessageBox@4 + 1380 bytes USER32! MessageBoxWorker@4 + 314 bytes USER32! MessageBoxTimeoutW@24 + 89 bytes USER32! SoftModalMessageBox@4 + 1380 bytes USER32! MessageBoxWorker@4 + 314 bytes USER32! MessageBoxTimeoutW@24 + 89 bytes USER32! MessageBoxWorker@4 + 314 bytes USER32! MessageBoxTimeoutA@24 + 111 bytes NTDLL! RtlImageDirectoryEntryToData@16 + 61 bytes 023f83dc() ruby 1.8.2 fxruby 1.2.6 regards Dirk -- 5 GB Mailbox, 50 FreeSMS http://www.gmx.net/de/go/promail +++ GMX - die erste Adresse für Mail, Message, More +++
I can confirm this bug, under FXRuby1.4.2. Under 1.2, it seems to work
fine.
Adding:
@clockThread = Thread.new(@clockLabel) { |clockLabel|
while true
clockLabel.text = Time.now.strftime("%I:%M:%S %p")
sleep(1)
GC.start ### new addition
end
}
will cause a segfault. This seems akin to the segfaults I''ve been
seeing
with IFMapper whenever I called the garbage collector, so the problem may be
related.
----- Original Message -----
From: <ujb1@gmx.de>
To: <fxruby-users@rubyforge.org>
Sent: Friday, September 02, 2005 5:27 AM
Subject: [fxruby-users] FXRuby and multithreading
> Hello,
>
> the problem can be reproduced with the groupbox.rbw example:
> - take the example file groupbox.rbw
> - add a GC.start in the clockThread
> - start the programm
> - Open the About dialog
>