Remove useless casts as recommended by Måns Rullgård.