Revision: 1629
http://gtkpod.svn.sourceforge.net/gtkpod/?rev=1629&view=rev
Author: tiffman
Date: 2007-07-08 15:04:19 -0700 (Sun, 08 Jul 2007)
Log Message:
-----------
Modified mp3_read_lame_tag() to check the info tag crc and return the result
of the check. Changed the replaygain and gapless functions to check the
return value and only use tag data if the crc matched.
Modified Paths:
--------------
gtkpod/branches/gapless_playback/ChangeLog_detailed
gtkpod/branches/gapless_playback/src/mp3file.c
Modified: gtkpod/branches/gapless_playback/ChangeLog_detailed
===================================================================
--- gtkpod/branches/gapless_playback/ChangeLog_detailed 2007-07-08 15:04:43 UTC
(rev 1628)
+++ gtkpod/branches/gapless_playback/ChangeLog_detailed 2007-07-08 22:04:19 UTC
(rev 1629)
@@ -1,3 +1,10 @@
+2007-07-08 Michael Tiffany <tiffman at users.sourceforge.net>
+
+ * src/mp3file.c: modified mp3_read_lame_tag() to check the info tag
+ crc and return the result of the check. Changed the replaygain and
+ gapless functions to check the return value and only use tag data if
+ the crc matched.
+
2007-07-06 Michael Tiffany <tiffman at users.sourceforge.net>
* src/display.h
Modified: gtkpod/branches/gapless_playback/src/mp3file.c
===================================================================
--- gtkpod/branches/gapless_playback/src/mp3file.c 2007-07-08 15:04:43 UTC
(rev 1628)
+++ gtkpod/branches/gapless_playback/src/mp3file.c 2007-07-08 22:04:19 UTC
(rev 1629)
@@ -1917,7 +1917,8 @@
g_return_val_if_fail (path, FALSE);
LameTag lt;
- mp3_read_lame_tag (path, <);
+ if (!mp3_read_lame_tag (path, <))
+ goto rg_fail;
int gain_adjust = 0;
g_return_val_if_fail (gd, FALSE);
@@ -2344,7 +2345,7 @@
lt->calculated_info_tag_crc = crc_compute(full_info_tag,
INFO_TAG_CRC_SIZE, 0x0000);
- return TRUE;
+ return (lt->calculated_info_tag_crc == lt->info_tag_crc);
lt_fail:
return FALSE;
@@ -2474,9 +2475,7 @@
/* Try the LAME tag for pregap and postgap */
LameTag lt;
- mp3_read_lame_tag (path, <);
-
- if (lt.info_tag_crc == lt.calculated_info_tag_crc) {
+ if (mp3_read_lame_tag (path, <)) {
gd.pregap = lt.delay;
gd.postgap = lt.padding;
} else {
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
gtkpod-cvs2 mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2