Bug 115755

Summary: bin/cue filenames should be handled case-insesitiveely
Product: [Applications] k3b Reporter: shift
Component: generalAssignee: Sebastian Trueg <trueg>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:

Description shift 2005-11-06 02:53:48 UTC
Version:           0.12.7 (using KDE 3.4.3 Level "b" , SUSE 10.0 UNSUPPORTED)
Compiler:          Target: i586-suse-linux
OS:                Linux (i686) release 2.6.13-15-smp

When i get BIN/CUE pair to burn, 
it usually happens, that it was made under windows, 
and i have files names IMAGE.bin and IMAGE.cue, 
but inside the CUE file, i have a reference to IMAGE.BIN (or Image.bin -- any possible combination) 

Seems like the amarok itself understands it, (it attempts to calculate the checksum), but then the writing fails. manually fixing the .cue file helps
Comment 1 Sebastian Trueg 2005-11-06 21:05:28 UTC
SVN commit 478443 by trueg:

Also search for the datafile inoring case.

BUG: 115755


 M  +1 -0      ChangeLog  
 M  +5 -4      libk3b/projects/k3bcuefileparser.cpp  


--- branches/stable/extragear/multimedia/k3b/ChangeLog #478442:478443
@@ -1,6 +1,7 @@
 0.12.8
 ======
  * Load index0 value in audio project.
+ * Ignore case in cue files.
 
 0.12.7
 ======
--- branches/stable/extragear/multimedia/k3b/libk3b/projects/k3bcuefileparser.cpp #478442:478443
@@ -94,9 +94,9 @@
       // save last parsed track for which we do not have the proper length :(
       if( d->currentParsedTrack > 0 ) {
 	d->toc.append( K3bDevice::Track( d->currentDataPos, 
-					   d->currentDataPos,
-					   d->trackType,
-					   d->trackMode ) );
+					 d->currentDataPos,
+					 d->trackType,
+					 d->trackMode ) );
       }
       
       // debug the toc
@@ -207,7 +207,8 @@
       QStringList possibleImageFiles = parentDir.entryList( QDir::Files );
       int cnt = 0;
       for( QStringList::const_iterator it = possibleImageFiles.constBegin(); it != possibleImageFiles.constEnd(); ++it ) {
-	if( (*it).startsWith( filenamePrefix ) && !(*it).endsWith( "cue" ) ) {
+	if( (*it).lower() == dataFile.section( '/', -1 ).lower() ||
+	    (*it).startsWith( filenamePrefix ) && !(*it).endsWith( "cue" ) ) {
 	  ++cnt;
 	  setImageFilename( K3b::parentDir(filename()) + *it );
 	}