[cairo] Fatal IO error 104 (Connection reset by peer) on show_text
Jake Brownson
jbrownson at gmail.com
Thu Nov 15 21:53:19 PST 2007
The window just flashes up and then I quickly get:
"Fatal IO error 104 (Connection reset by peer) on X server :0.0."
If I use a debugger the crash happens on the line with the show_text
call, but I don't seem to even get a signal, the app just crashes with
the message. I'm not completely sure what it really means. Is there an
error in the way gtk is dealing w/ X? Even if I'm doing something
wrong it seems like there should be a better error message.
I tried going through pango to draw text and see the same problem. I
sent this to a friend (who runs the same distro and version I do) and
he had the same problem. I also tried setting up all the font settings
like in example code that comes with libcairomm, but that didn't seem
to help.
Am I doing something wrong? or is this a bug?
I'm using Ubuntu 7.10, gtkmm 2.12.0, gtk 2.12.0, pango 1.18.3, cairo
1.4.10, cairomm 1.2.4
Here is a minimal example:
#include <gtkmm.h>
#include <cairomm/cairomm.h>
class CairoWindow : public Gtk::Window
{
public:
virtual bool on_expose_event(GdkEventExpose*)
{
Cairo::RefPtr<Cairo::Context> c = get_window()->create_cairo_context();
Gtk::Allocation allocation = get_allocation();
c->scale(allocation.get_width(), allocation.get_height());
c->show_text("Crash Here"); // Crashes here with " Fatal IO error
104 (Connection reset by peer) on X server :0.0."
}
};
int main(int argc, char *argv[])
{
Gtk::Main kit(argc, argv);
CairoWindow window;
kit.run(window);
}
More information about the cairo
mailing list