# HG changeset patch # User Chris Cannam # Date 1456405366 0 # Node ID 52d088c24c5c96f75492e35a75685f1718e2dffd # Parent 7c4f4701b49fe6d0b3388788866933f03cc7849c Debug diff -r 7c4f4701b49f -r 52d088c24c5c data/fileio/MP3FileReader.cpp --- a/data/fileio/MP3FileReader.cpp Fri Jan 22 09:52:08 2016 +0000 +++ b/data/fileio/MP3FileReader.cpp Thu Feb 25 13:02:46 2016 +0000 @@ -32,7 +32,8 @@ #ifdef HAVE_ID3TAG #include #endif -//#define DEBUG_ID3TAG 1 + +#define DEBUG_ID3TAG 1 #include @@ -178,7 +179,7 @@ id3_tag *tag = id3_file_tag(file); if (!tag) { #ifdef DEBUG_ID3TAG - SVDEBUG << "MP3FileReader::loadTags: No ID3 tag found" << endl; + cerr << "MP3FileReader::loadTags: No ID3 tag found" << endl; #endif id3_file_close(file); return; @@ -201,7 +202,7 @@ #else #ifdef DEBUG_ID3TAG - SVDEBUG << "MP3FileReader::loadTags: ID3 tag support not compiled in" + cerr << "MP3FileReader::loadTags: ID3 tag support not compiled in" << endl; #endif #endif @@ -216,20 +217,20 @@ id3_frame *frame = id3_tag_findframe(tag, name, 0); if (!frame) { #ifdef DEBUG_ID3TAG - SVDEBUG << "MP3FileReader::loadTags: No \"" << name << "\" in ID3 tag" << endl; + cerr << "MP3FileReader::loadTags: No \"" << name << "\" in ID3 tag" << endl; #endif return ""; } if (frame->nfields < 2) { - SVDEBUG << "MP3FileReader::loadTags: WARNING: Not enough fields (" << frame->nfields << ") for \"" << name << "\" in ID3 tag" << endl; + cerr << "MP3FileReader::loadTags: WARNING: Not enough fields (" << frame->nfields << ") for \"" << name << "\" in ID3 tag" << endl; return ""; } unsigned int nstrings = id3_field_getnstrings(&frame->fields[1]); if (nstrings == 0) { #ifdef DEBUG_ID3TAG - SVDEBUG << "MP3FileReader::loadTags: No strings for \"" << name << "\" in ID3 tag" << endl; + cerr << "MP3FileReader::loadTags: No strings for \"" << name << "\" in ID3 tag" << endl; #endif return ""; } @@ -237,7 +238,7 @@ id3_ucs4_t const *ustr = id3_field_getstrings(&frame->fields[1], 0); if (!ustr) { #ifdef DEBUG_ID3TAG - SVDEBUG << "MP3FileReader::loadTags: Invalid or absent data for \"" << name << "\" in ID3 tag" << endl; + cerr << "MP3FileReader::loadTags: Invalid or absent data for \"" << name << "\" in ID3 tag" << endl; #endif return ""; } @@ -252,7 +253,7 @@ free(u8str); #ifdef DEBUG_ID3TAG - SVDEBUG << "MP3FileReader::loadTags: tag \"" << name << "\" -> \"" + cerr << "MP3FileReader::loadTags: tag \"" << name << "\" -> \"" << rv << "\"" << endl; #endif