[M3devel] use of uninitialized local in PaintVBTtoVBT??

Jay K jay.krell at cornell.edu
Mon Oct 26 09:10:28 CET 2009


sorry I'm an idiot, the wordwrap confused me into seeing "VAR" where it wasn't.
Still, to is sometimes NIL.
 
 - Jay


----------------------------------------
> From: jay.krell at cornell.edu
> To: m3devel at elegosoft.com
> Date: Mon, 26 Oct 2009 08:03:06 +0000
> Subject: [M3devel] use of uninitialized local in PaintVBTtoVBT??
>
>
> Can anyone explain this?
>
> DblBufferVBT.m3
>
> PROCEDURE PaintVBTtoVBT(to: VBT.T; clip: Rect.T;
> from: VBT.T; delta := Point.Origin; wait := TRUE) =
> <* LL.sup < to *>
> VAR dummy: Region.T; pixmap: ScrnPixmap.T; BEGIN
> pixmap := VBT.Capture(from, Rect.Sub(clip, delta), (*OUT*) dummy);
>
> VBT.m3:
>
> PROCEDURE Capture (v: T; READONLY clip: Rect.T; VAR (*out*) br: Region.T):
> ScrnPixmap.T RAISES {} =
> VAR bad: Region.T;
> BEGIN
> LOCK v DO
>
> from is passed uninitialized to Capture.
> The code appears the same in head, 5.2.6, 3.6.
> I do hit the LOCK v in Capture if I run Juno sufficient times on NT.
> Maybe from should be Child() or ch?
> I'll try that.
>
>
> - Jay 		 	   		  


More information about the M3devel mailing list