in reply to Re: A sub to return the number of listeners on a Shoutcast server
in thread A sub to return the number of listeners on a Shoutcast server

I wouldn't use "die" on an error, since you're in a sub... the user would at least get a somewhat decent error.

I'd disagree; since all sorts of other things could go wrong, like problems in Net::HTTP, I'd vote for a "die" and using an eval {} block around it if you want to catch the errors and handle them in some specific way.

  • Comment on Re: Re: A sub to return the number of listeners on a Shoutcast server