Bug 691546

Summary: buffer overflow and asserts in imagesmooth
Product: MuPDF Reporter: Tor Andersson <tor.andersson>
Component: fitzAssignee: Robin Watts <robin.watts>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P4    
Version: unspecified   
Hardware: All   
OS: All   
Customer: Word Size: ---
Attachments: 10.1.1.30.8066.pdf
10.1.1.42.7749.pdf
patch.txt

Description Tor Andersson 2010-08-11 12:13:18 UTC
Created attachment 6640 [details]
10.1.1.30.8066.pdf

Some problems in the imagesmooth code:

draw/imagesmooth.c:569: fz_smoothscalepixmap: Assertion `max_row < src->h' failed.
draw/imagesmooth.c:308: add_weight: Assertion `weights->count == j-1' failed.

==1840== Invalid write of size 4
==1840==    at 0x41D6BB: reorder_weights (imagesmooth.c:391)
==1840==    by 0x41D922: make_weights (imagesmooth.c:463)
==1840==    by 0x41DC3B: fz_smoothscalepixmap (imagesmooth.c:541)
Comment 1 Tor Andersson 2010-08-11 12:13:57 UTC
Created attachment 6641 [details]
10.1.1.42.7749.pdf
Comment 2 Robin Watts 2010-09-01 11:44:35 UTC
Created attachment 6685 [details]
patch.txt

Patch that fixes this bug. Sent to Tor for his consideration.