History

pp: avoid overflow in w*h

Fixes CID700580 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>

Michael Niedermayer committed 14 years ago

Commit 3689ec31 parent c0f0bec1 file · +1 −1Browse files

Showing the changes to libpostproc (1 of 1 file). Show all

Unified · Split

libpostproc/postprocess_template.c+1−1
@@ -3225,7 +3225,7 @@ static void RENAME(postProcess)(const uint8_t src[], int srcStride, uint8_t dst[ · 3224 unmodified lines
3225 3225
3226 c.frameNum++;3226 c.frameNum++;
3227 // first frame is fscked so we ignore it3227 // first frame is fscked so we ignore it
3228 if(c.frameNum == 1) yHistogram[0]= width*height/64*15/256;3228 if(c.frameNum == 1) yHistogram[0]= width*(uint64_t)height/64*15/256;
3229 3229
3230 for(i=0; i<256; i++){3230 for(i=0; i<256; i++){
3231 sum+= yHistogram[i];3231 sum+= yHistogram[i];

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t