1. Ping Derek: Eight potential bugs in win32lib

Derek,
None of these are known to cause any bugs, but I've noticed 8 cases
where atoms are assigned to integers. Either the rhs is an atom so
that it can hold 32 bits and therefore the lhs should be too, or the
rhs should be wrapped in floor().

I'm posting this list for review/info only, in the hope of avoiding
grief for you or one of your users at some future date.

I'm pretty sure the first one cannot possibly cause a problem, whereas
in contrast I'm pretty sure 25680 is a bug waiting to happen.

w32support
897:		lMemSize = lPreSize + pSize + 4 + vSafetyBuffer

w32file
168:		lID = pHDC

win32lib
11695:	vStreamCBPosn = lEnd + 1
16634:	bgControl = pOwner
23738:	lStart = lNextElem
23852:	lTextPrinted = lNextElem
25680:	offset = address
30377:	origpos = pos

Regards,
Pete

new topic     » topic index » view message » categorize

2. Re: Ping Derek: Eight potential bugs in win32lib

Pete Lomax wrote:
> 
> Derek,
> None of these are known to cause any bugs, but I've noticed 8 cases
> where atoms are assigned to integers. Either the rhs is an atom so
> that it can hold 32 bits and therefore the lhs should be too, or the
> rhs should be wrapped in floor().
> 
> I'm posting this list for review/info only, in the hope of avoiding
> grief for you or one of your users at some future date.
> 
> I'm pretty sure the first one cannot possibly cause a problem, whereas
> in contrast I'm pretty sure 25680 is a bug waiting to happen.
> 

Good catch. Fixing as we speak blink

> w32file
> 168:		lID = pHDC

Except that this one is in w32gdi.ew and it doesn't matter anyhow as it
is validated prior to the assignment.

-- 
Derek Parnell
Melbourne, Australia

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu