Fl_Text_Buffer().append() (or text(char*) causes segmentation fault

Bug #363128 reported by pbeeson
2
Affects Status Importance Assigned to Milestone
fltk1.1 (Ubuntu)
New
Undecided
Unassigned

Bug Description

When I download the Ubuntu source for fltk1.1.9 and compile it myself, my program works just fine. Also version 1.1.5 (dapper) works fine with my code. But, the pre-built libfltk.so that is installed by default segfaults.

Simple test case:

  disp=new Fl_Text_Display(0, y, w, h);
  disp->buffer(new Fl_Text_Buffer(256));
  std::cerr <<"HERE: "<<disp->buffer()->text()<<std::endl;
  disp->buffer()->text("foo");

Segfaults on the text(char*). You could substitute an append("foo") on the last line and watch it segfault there too.

Revision history for this message
pbeeson (pbeeson) wrote : Re: [Bug 363128] [NEW] Fl_Text_Buffer().append() (or text(char*) causes segmentation fault

I just noted that it works with Dapper's 1.1.7 but not with 1.1.8
pre-built Ubuntu and that the 1.1.9-x don't work (hardy, intrepid, and
jaunty).

ldd did show that my libfltk.so.1.1 has many fewer dependencies, so this
may be the culprit. I don't have lots of time to track this down, but I
found it strange that 1) this was really easy to fix by compiling my own
version and 2) that no one else has reported such a bug previously.

Patrick Beeson
http://www.cs.utexas.edu/~pbeeson

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.