FLTK logo

STR #2003

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 Home  |  Articles & FAQs  |  Bugs & Features  |  Documentation  |  Download  |  Screenshots  ]
 

Return to Bugs & Features | Roadmap 1.3 | SVN ⇄ GIT ]

STR #2003

Application:FLTK Library
Status:1 - Closed w/Resolution
Priority:2 - Low, e.g. a documentation error or undocumented side-effect
Scope:2 - Specific to an operating system
Subsystem:Core Library
Summary:2 broken_image checks in Fl_Help_View.cxx
Version:1.3-current
Created By:markcw
Assigned To:fabien
Fix Version:1.3-current
Update Notification:

Receive EMails Don't Receive EMails

Trouble Report Files:


Name/Time/Date Filename/Size  
 
#1 markcw
14:40 Jul 15, 2008
Fl_Help_View.cxx
86k
 
     

Trouble Report Comments:


Name/Time/Date Text  
 
#1 markcw
14:40 Jul 15, 2008
A couple of checks added to Fl_Help_View.cxx not by me but by Sebastian Hollington. The checks are to make sure an image is valid before freeing it otherwise it caused an XServer XFreePixmap crash.

The fixes are shown below and the modified Fl_Help_View.cxx is attached.

// Line 890 in Fl_Help_View::draw()

            if (img) {

              img->draw(xx + x() - leftline_,

                        yy + y() - fl_height() + fl_descent() + 2);

              //Seb was here - freeing broken_image causes an XServer XFreePixmap crash.

              if((void*)img!=&broken_image) img->release();

            }

// Line 2360 in Fl_Help_View::free_data()

          if (get_attr(attrs, "SRC", attr, sizeof(attr))) {

            // Release the image twice to free it from memory...

            img = get_image(attr, width, height);

                //Seb was here - freeing a broken_image causes an XFreePixmap crash.

                if((void*)img!=&broken_image){

                        img->release();

                    if(img->refcount() > 0) img->release();

                }

          }
 
 
#2 markcw
16:31 Jul 15, 2008
This has been reposted because of a few mistakes.

The new post is here.
http://www.fltk.org/str.php?L2004
 
 
#3 matt
08:16 Jul 18, 2008
Should be applied to 1.3 because 1.1.9 is final  
 
#4 fabien
02:42 Aug 30, 2008
Fixed in Subversion repository.

fixed w/resolution see str #2004
 
     

Return to Bugs & Features ]

 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.