Commit bbfeefc7 authored by John Koleszar's avatar John Koleszar
Browse files

gen_scalers: fix 64-bit integer promotion bug

i needs to be treated as signed to get the proper indexing on 64-bit
platforms. This behavior was accidentally reverted when fixing an
unsigned/signed comparison warning.

Change-Id: Ic306d609bdc8de94c8f8ba29c6e45c736101a82e
Showing with 3 additions and 2 deletions
...@@ -937,12 +937,13 @@ void vp8cx_vertical_band_2_1_scale_c(unsigned char *source, unsigned int src_pit ...@@ -937,12 +937,13 @@ void vp8cx_vertical_band_2_1_scale_c(unsigned char *source, unsigned int src_pit
void vp8cx_vertical_band_2_1_scale_i_c(unsigned char *source, unsigned int src_pitch, unsigned char *dest, unsigned int dest_pitch, unsigned int dest_width) void vp8cx_vertical_band_2_1_scale_i_c(unsigned char *source, unsigned int src_pitch, unsigned char *dest, unsigned int dest_pitch, unsigned int dest_width)
{ {
unsigned int i; int i;
int temp; int temp;
int width = dest_width;
(void) dest_pitch; (void) dest_pitch;
for (i = 0; i < dest_width; i++) for (i = 0; i < width; i++)
{ {
temp = 8; temp = 8;
temp += source[i-(int)src_pitch] * 3; temp += source[i-(int)src_pitch] * 3;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment