libmodplug: simplify and fix read_packet() callback.