# HG changeset patch # User reimar # Date 1200761873 0 # Node ID ad419ff363d7aa73b4b01abd36179066a8b7b184 # Parent 15c5da485a77a69112c2a8995e1bdca1aea920cd Simplify and keep terminating end-of-line diff -r 15c5da485a77 -r ad419ff363d7 stream/stream_cddb.c --- a/stream/stream_cddb.c Sat Jan 19 16:49:01 2008 +0000 +++ b/stream/stream_cddb.c Sat Jan 19 16:57:53 2008 +0000 @@ -442,13 +442,13 @@ ptr = strdup(ptr); // Ok found the beginning of the file // look for the end - ptr2 = strstr(ptr, "\r\n.\r\n"); - if( ptr2==NULL ) { + ptr2 = strstr(ptr, "\n.\r\n"); + if (!ptr2) ptr2 = strstr(ptr, "\n.\n"); - if( ptr2==NULL ) { + if (ptr2) ptr2++; + else { mp_msg(MSGT_DEMUX, MSGL_FIXME, "Unable to find '.'\n"); ptr2=ptr+strlen(ptr); //return -1; - } } // Ok found the end // do a sanity check