diff options
| author | jcsjcs <jcsjcs@f01d2545-417e-4e96-918e-98f8d0dbbcb6> | 2005-11-12 13:58:50 +0000 |
|---|---|---|
| committer | jcsjcs <jcsjcs@f01d2545-417e-4e96-918e-98f8d0dbbcb6> | 2005-11-12 13:58:50 +0000 |
| commit | cb19662f27ee2bd5676827dc68364b5149650fda (patch) | |
| tree | 9ad39e368deb6c61c8474e9cc285d0038c4d0b9d /src | |
| parent | a4898420a12ed5b9940436dd717756250860c56a (diff) | |
| download | libgpod-cb19662f27ee2bd5676827dc68364b5149650fda.tar.gz libgpod-cb19662f27ee2bd5676827dc68364b5149650fda.tar.xz libgpod-cb19662f27ee2bd5676827dc68364b5149650fda.zip | |
* src/itdb_track.c: (itdb_track_set_defaults) only change unk208
(audio/video) if not already set to non-zero.
git-svn-id: https://gtkpod.svn.sf.net/svnroot/gtkpod/libgpod/trunk@1148 f01d2545-417e-4e96-918e-98f8d0dbbcb6
Diffstat (limited to 'src')
| -rw-r--r-- | src/itdb_track.c | 34 |
1 files changed, 20 insertions, 14 deletions
diff --git a/src/itdb_track.c b/src/itdb_track.c index d7ff6a4..cfce01f 100644 --- a/src/itdb_track.c +++ b/src/itdb_track.c @@ -1,4 +1,4 @@ -/* Time-stamp: <2005-10-12 01:04:36 jcs> +/* Time-stamp: <2005-11-12 22:57:11 jcs> | | Copyright (C) 2002-2005 Jorg Schuler <jcsjcs at users sourceforge net> | Part of the gtkpod project. @@ -138,21 +138,27 @@ static void itdb_track_set_defaults (Itdb_Track *tr) tr->unk144 = 0x00; /* default value */ } } - if (is_video_ipod (tr->itdb->device)) { - /* The unk208 field seems to denote whether the file is a video or not. - It seems that it must be set to 0x00000002 for video files. */ - /* Only doing that for iPod videos since it remains to be proven that - * setting unk208 to non-0 doesn't upset older ipod models + if (is_video_ipod (tr->itdb->device)) + { + /* The unk208 field seems to denote whether the file is a + video or not. It seems that it must be set to 0x00000002 + for video files. */ + /* Only doing that for iPod videos since it remains to be + * proven that setting unk208 to non-0 doesn't upset older + * ipod models */ - if (haystack (tr->filetype, m4v_desc)) - { - /* set type to video (0x00000002) */ - tr->unk208 = 0x00000002; - } - else + if (tr->unk208 == 0) { - /* set type to audio */ - tr->unk208 = 0x00000001; + if (haystack (tr->filetype, m4v_desc)) + { + /* set type to video (0x00000002) */ + tr->unk208 = 0x00000002; + } + else + { + /* set type to audio */ + tr->unk208 = 0x00000001; + } } } /* The sample rate of the song expressed as an IEEE 32 bit |
