Fix C89_BUILD

This commit is contained in:
twinaphex 2017-04-22 09:37:36 +02:00
parent aa2c29ac8b
commit f12ea0e1e3
2 changed files with 9 additions and 4 deletions

View File

@ -282,7 +282,7 @@ static EGLDisplay get_egl_display(EGLenum platform, void *native)
return dpy;
}
}
#endif // defined(EGL_VERSION_1_5)
#endif /* defined(EGL_VERSION_1_5) */
#if defined(EGL_EXT_platform_base)
if (check_egl_client_extension("EGL_EXT_platform_base"))
@ -299,7 +299,7 @@ static EGLDisplay get_egl_display(EGLenum platform, void *native)
return dpy;
}
}
#endif // defined(EGL_EXT_platform_base)
#endif /* defined(EGL_EXT_platform_base) */
}
/* Either the caller didn't provide a platform type, or the EGL

View File

@ -118,8 +118,11 @@ static void fixup_filter_sub(struct scaler_filter *filter,
if (postsample > 0)
{
int16_t *base_filter = NULL;
filter->filter_pos[i] -= postsample;
int16_t *base_filter = filter->filter + i * filter->filter_stride;
base_filter = filter->filter + i * filter->filter_stride;
if (postsample > (int)filter->filter_len)
memset(base_filter, 0, filter->filter_len * sizeof(int16_t));
@ -133,8 +136,10 @@ static void fixup_filter_sub(struct scaler_filter *filter,
if (presample > 0)
{
int16_t *base_filter = NULL;
filter->filter_pos[i] += presample;
int16_t *base_filter = filter->filter + i * filter->filter_stride;
base_filter = filter->filter + i * filter->filter_stride;
if (presample > (int)filter->filter_len)
memset(base_filter, 0, filter->filter_len * sizeof(int16_t));