avoid warning cast
Merge branch 'cast-warnings'
don't change the function declaration