Re: gtk-based sip client "locking up"



Thanks to you and everyone that replied.

The application is threaded, it uses between 2 and 6 Pthreads (depending on whats happening at the time). Why is it necessary to register these file descriptors? I have all my files set to async operation (open(..., O_NONBLOCK)). I might add that the client continues to work and the buttons are still active. For example, when you want to call someone, you hit the dial button, the text of the button then changes to hangup and if you hit that button again, it terminates the call. These functions continue to work, its just that there is no "repainting" of any of the widgets but they are still generating their signals.

Also FYI, I running Red Hat 9 stock.

FM


Nils O. Selåsdal wrote:

On Mon, 2004-04-26 at 01:58, Frank W. Miller wrote:
Greetings,

I'm new to programming with GTK and new to this list. I apologize in advance if this is a simple question and I just havent dug hard enough to find the answer. I've been through a number of programming docs and scanned some mailing lists to no avail so far.
It all depends on how you do your networking.
I guess you have a callback signal somewhere that gets called
when user clicks the Dial button.
If that callback does the network setup(handling the initial
dialog handshake) it will block the GUI updating. That is
the appliation will wait for a connection to complete and wait
for the answer back instead of updating the GUI. Basically, any time
your code executes, the GUI will block. Usually this is no problem
since such code executes and finishes fast. But if it does networking
it might take a very long time.
So, basically, use async IO.
http://developer.gnome.org/doc/API/2.0/glib/glib-IO-Channels.html#g-io-add-watch-full
Or do networing in a seperat thread.
If the above is not the problem, you have to track down in your code where/when it
stops/hangs and provide that info.






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]