summaryrefslogtreecommitdiff
path: root/audio/daapd/patches/patch-af
blob: 06ee965c6197efa4d2a47f90bf915283e5108ecd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
$NetBSD: patch-af,v 1.1 2007/02/09 20:32:38 drochner Exp $

--- db.cc.orig	2007-02-09 16:49:38.000000000 +0100
+++ db.cc
@@ -325,7 +325,7 @@ void Database::addM4a( std::string& path
 			MP4TrackId trackId = MP4FindTrackId(mp4file, 0);
 			u32 timeScale = MP4GetTrackTimeScale(mp4file, trackId);
 			MP4Duration trackDuration = MP4GetTrackDuration(mp4file, trackId);
-			double msDuration = UINT64_TO_DOUBLE(MP4ConvertFromTrackDuration(mp4file, trackId, trackDuration, MP4_MSECS_TIME_SCALE));
+			double msDuration = (double)MP4ConvertFromTrackDuration(mp4file, trackId, trackDuration, MP4_MSECS_TIME_SCALE);
 			u32 avgBitRate = MP4GetTrackBitRate(mp4file, trackId);
 			song->time = (u32) (msDuration);
 			song->bitrate = (u16) ((avgBitRate + 500) / 1000);