DouweM / shoutout

A Ruby library for easily getting metadata from Shoutcast-compatible audio streaming servers
MIT License
5 stars 2 forks source link

URI.path is empty giving errors from stream #6

Closed confact closed 1 year ago

confact commented 9 years ago

if sending in streams like this: http://208.85.242.52:8178 and using uri.path will give a empty string, causing problems when sending GET HTTP header.

A added a simple fix to my memory-leak-fix branch to fix this, like this:

path = uri.path
if path == nil || path == ""
    path = "/"
end

And use path instead.