Subject: lib/17612: libcdk, newCDKRadio needs better param checking - segvs
To: None <>
From: None <>
List: netbsd-bugs
Date: 07/17/2002 12:23:21
>Number:         17612
>Category:       lib
>Synopsis:       libcdk, CDKRADIO allows improper params, resulting in segv.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    lib-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jul 16 09:19:00 PDT 2002
>Originator:     Tyler Retzlaff
>Release:        NetBSD 1.6D
	Wasabi Systems
System: NetBSD elysium 1.6D NetBSD 1.6D (elysium) #0: Mon Jul 15 06:43:10 EST 2002 rtr@elysium:/usr/src/sys/arch/i386/compile/elysium i386
Architecture: i386
Machine: i386
	newCDKRadio() does not properly check parameters to ensure they aren't


	radio = newCDKRadio(scr, CENTER, CENTER, NONE, 1, 6, "", items, 1, 'X',

	Attempting to call activateCDKRadio() on this radio will result in
	a segv as long as parameter 5 is < 4.

	I assume the problem occurs because newCDKRadio does not properly
	calculate the height of the box lines + title + shadow + elements.

	No time to fix, so no suggestions.  If this PR lingers I'l come back
	to and try to fix it.  

	I would however suggest doing some magic on the value passed in
	so that passing values > 0 don't cause a fault.