Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9952cddd authored by Steve Kondik's avatar Steve Kondik Committed by Gerrit Code Review
Browse files

Merge "FLAC: fix duration in media scanner" into gingerbread

parents be3fc10e 1555b75e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -115,7 +115,7 @@ static void flac_metadata(const FLAC__StreamDecoder *decoder, const FLAC__Stream
    MediaScannerClient *client = (MediaScannerClient *)client_data;

    if (metadata->type == FLAC__METADATA_TYPE_STREAMINFO) {
        FLAC__uint64 duration = metadata->data.stream_info.total_samples / metadata->data.stream_info.sample_rate;
        FLAC__uint64 duration = 1000 * metadata->data.stream_info.total_samples / metadata->data.stream_info.sample_rate;
        if (duration > 0) {
            char buffer[20];
            sprintf(buffer, "%lld", duration);