The second method requires currentsong.length to be a long int (uint32_t), because the multiplication of
currentsong.frames by currentsong.samples_per_frame does not fit on an uint16_t. But with the first way, an uint16_t would be enough, since never will reach values over uint16_t limit. All other used variables are uint16_t.
I don't know what could be the problem. Maybe I'm missing something ?