Buffer is accessed out of bounds.
Merge pull request #1288 from nghiaho12:haar