Ticket #1733 (closed bug: fixed)
BAlert sometimes crashes (appears to be somewhere in BMessage's internals)
| Reported by: | anevilyak | Owned by: | axeld |
|---|---|---|---|
| Priority: | normal | Milestone: | R1 |
| Component: | Kits/Application Kit | Version: | R1 development |
| Cc: | Blocked By: | ||
| Platform: | All | Blocking: |
Description
In Vision, there is an option to warn you on pasting multiline messages. This brings up a BAlert that is constructed as follows:
BString str; str += "As if there isn't enough, you "; str += "are about to add "; str << lines; str += " more lines of spam to "; str += "the internet. How "; str += "would you like to go about this?";
BAlert *alert (new BAlert ( "Spam", str.String(), "Cancel", "Spam!", "Single Line", B_WIDTH_FROM_WIDEST, B_OFFSET_SPACING, B_WARNING_ALERT));
BMessage *invokeMsg (new BMessage (msg)); BInvoker *invoker (new BInvoker (invokeMsg, msgr)); invokeMsg->AddPointer ("invoker", invoker); alert->Go (invoker);
Roughly every other time, picking any of the presented options on the aforementioned alert results in a crash with the following trace:
0x003d09a1 in BMessage::IsSourceWaiting () from / boot/beos/system/lib/libbe.so (gdb) bt #0 0x003d09a1 in BMessage::IsSourceWaiting () from /boot/beos/system/lib/libbe.so #1 0x003d3158 in BMessage::_SendMessage () from / boot/beos/system/lib/libbe.so #2 0x003d97d8 in BMessenger::SendMessage () from /boot/beos/system/lib/libbe.so #3 0x003d971b in BMessenger::SendMessage () from /boot/beos/system/lib/libbe.so #4 0x003cb805 in BInvoker::Invoke () from /boot/ beos/system/lib/libbe.so #5 0x003e8da3 in BAlert::MessageReceived () from /boot/beos/system/lib/libbe.so #6 0x003ccd1b in BLooper::DispatchMessage () from /boot/beos/system/lib/libbe.so #7 0x0046d769 in BWindow::DispatchMessage () from /boot/beos/system/lib/libbe.so #8 0x003e8eeb in BAlert::DispatchMessage () from /boot/beos/system/lib/libbe.so #9 0x00470f00 in BWindow::task_looper () from / boot/beos/system/lib/libbe.so #10 0x003ce253 in BLooper::_task0_ () from /boot/ beos/system/lib/libbe.so #11 0x0086e264 in thread_entry () from /boot/beos/ system/lib/libroot.so #12 0x70184fec in ?? ()
Unfortunately I'm unable to debug this further using gdb because I've been unsuccessful at building debugging versions of libbe (halted by libroot failing to link).
