1. libgd
  2. Untitled project
  3. gd-libgd

Pull requests

#12 Merged
Repository
suetanvil
Branch
suetanvil
Repository
libgd
Branch
master

Fixed memory overrun bug in gdImageScaleTwoPass

Author
  1. Chris Reuter
Reviewers
Description

_gdContributionsCalc() would compute a window size and then adjust the left and right positions of the window to make a window within that size. However, it was storing the values in the struct before it made the adjustment, causing the rescale operation to read past the end of the array of weights. This change fixes that.

  • Learn about pull requests

Comments (2)

  1. Pierre Joye

    Hi!

    Good catch and thanks for the PR!

    I'm on the road but I think we are good for a 2.1.1 soonish. I will do it as soon as I get back home (should be on Friday).