QNX RTOS v4 Knowledge Base
QNX RTOS v4 Knowledge Base
Title |
Managing a PtWindow widget causes a SIGSEGV |
Ref. No. |
QNX.000009906 |
Category(ies) |
Development |
Issue |
While trying to manage the opening and closing of a PtWindow, we found out that the application SIGSEGV's.
What could be the problem? |
Solution |
When your WindowOKButtonActivated() callback is attached as a Done callbacks, it causes the window to get destroyed when the button is pressed. After the window has been destroyed, your gfWin variable points to free memory, and calling PtRealizeWidget() or PtWindowToFront() on it will either crash or just do nothing... If you want to hide the window without destroying it, change the callback from Done to Code, and do the hiding in your code. |
|