remove cast

C99+TC3, 7.19.7.1p2: [...] the fgetc function obtains that character as
an unsigned char converted to an int [...]
don't convert function pointer to object pointer
remove const type qualifier

clang 3.5.0 with -Wextra produces a -Wignored-qualifiers diagnostic.
Merge pull request #2644 from cremno/mrdb-minor-changes

mrdb: minor changes