Re: Question about Threads y gtk+



Inexplicably (read: I don't know), there is no glib equivalent for the
function pthread_kill().

Not sure why, perhaps the glib gurus could elaborate on why it is not
possible to externally kill a thread a la pthread_kill()?

Or is there some equivalent I have not found?

Assuming there is no glib thread kill function, you've got to get creative
here: let the thread complete and then ignore its results, or,
periodically read a queue that the main thread writes to telling the
thread it needs to quit, or, periodically read a global flag, etc.

richard

On Fri, Oct 3, 2008 at 1:56 AM, Moises <ammoises yahoo com mx> wrote:

    Question about Threads y gtk+

    To end a thread, you have to leave the function of the thread with an
exit, return  or calling g_thread_exit.

    My question is how can I finish the thread from my main thread?

    I try to use g_object_unref, for finish the thread but get me error.






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