Error that aborts a running GTK application using threads.
- From: "Mario Segura" <masegurita gmail com>
- To: gtkmm-list <gtkmm-list gnome org>
- Subject: Error that aborts a running GTK application using threads.
- Date: Sat, 29 Apr 2006 18:44:08 -0400
Hi,
I got the following message, that aborts my application:
-----------------------------
(principalgui:2792): Gtk-WARNING **: gtktextview.c:4221: somehow some
text lines were modified or scrolling occurred since the last
validation of lines on the s creen - may be a text widget bug.
Gtk-ERROR **: file gtktextview.c: line 4222 (gtk_text_view_paint): should not be reached
aborting...
Aborted
-----------------------------
This happens randomly when a thread is running and it tries to use a
text buffer to write some lines. Some times the thread can write almost
all the lines, sometimes in the first line the application crashes, it
don't depend in the number of lines the thread writes. I use mutex
every time i want to write a line in the buffer.
C++ code that randomly produces the error used by a thread. variable "line" contains the text that will be added.
------------
Glib::Mutex mut;
mut.unlock();
consolabuffer->insert_at_cursor(line);//Agrega al buffer el texto recibido
mut.lock();
------------
Any idea how i could prevent this error without avoing the use of the buffer?
Thanks,
--
Mario Segura S.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]