Bug 129326

Summary: x11-clocks/asclock dies due to buffer overrun at startup
Product: Ports & Packages Reporter: G. Paul Ziemba <p-fbsd-bugs>
Component: Individual Port(s)Assignee: Dirk Meyer <dinoex>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.txt none

Description G. Paul Ziemba 2008-12-01 08:30:01 UTC
asclock dies immediately with error "not enough free color cells"

Fix: "not enough free color cells" is erroneously printed for any error returned by XpmCreatePixmapFromData, e.g., corrupt xpm data.

The actual cause of the error in this case was a buffer overrun when constructing the LED pixmap data.

Attached patch addresses several things:
1 - buffer overrun
2 - simplified bizarre method of printing with format %04X
3 - error messages match actual errors from XpmCreatePixmapFromData
4 - missing error test for one call to XpmCreatePixmapFromData


Patch attached with submission follows:
How-To-Repeat: $ asclock
not enough free color cells
$
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2008-12-01 08:30:11 UTC
Responsible Changed
From-To: freebsd-ports-bugs->dinoex

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 dfilter service freebsd_committer freebsd_triage 2008-12-04 20:57:57 UTC
dinoex      2008-12-04 20:57:48 UTC

  FreeBSD ports repository

  Modified files:
    x11-clocks/asclock   Makefile 
  Added files:
    x11-clocks/asclock/files patch-color 
  Log:
  - fix buffer overrun at startup
  PR:             129326
  Submitted by:   G. Paul Ziemba
  
  Revision  Changes    Path
  1.23      +1 -1      ports/x11-clocks/asclock/Makefile
  1.1       +76 -0     ports/x11-clocks/asclock/files/patch-color (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 3 Dirk Meyer freebsd_committer freebsd_triage 2008-12-04 21:18:22 UTC
State Changed
From-To: open->closed

committed, thanks.