Fixed warnings for C99