Right around line 507 is the following code:

file = string(strchr(m_path + 7, '/'));

Problem is, this blows up if m_path is something like
"http://205.188.245.131:8038", since strchr is returning null and the string
constructor doesn't like that (on windows anyway).  I worked around it like
this:

const char* address = strchr(m_path + 7, '/');
file = (address ? address : "");

I'm at a loss as to why I didn't see this problem last week, when I was
doing the exact same thing (playing a stream).  Oh well..

Incidentally, I've been looking at the code because I want to see if it's
feasible to augment the stream-saving functionality so that songs will be
saved in separate files and directories according to artist and song title.
I don't even know yet if this is doable (if the server provides enough info)
but I figured I would take a look.

cheers,

Scott McCaskill


_______________________________________________
[EMAIL PROTECTED]
http://www.freeamp.org/mailman/listinfo/freeamp-dev

Reply via email to