[Home]

Summary:ASTERISK-01332: [patch] musiconhold url streaming bug
Reporter:Ernani José Camargo Azevedo (azevedo)Labels:
Date Opened:2004-04-02 15:23:39.000-0600Date Closed:2011-06-07 14:05:22
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) asterisk-musiconhold.diff
( 1) res_musiconhold.c.diff
Description:The function spawn_mp3 of the resource file res_musiconhold.c doesn't respect anymore if the parameter passed is a URL (using or not the "httpmp3" prefix).

****** ADDITIONAL INFORMATION ******

Following is a patch to detect if there's any "http://" string into the parameter passed. If the string was found, it doesn't try to open it as a local filesystem file (resulting in error and exiting the function without playing) and adds it as a parameter to mpg123.
Comments:By: bw (bw) 2004-04-07 04:36:45

Another thing to consider is that music from a stream won't start for a while if mpg123 is buffering (2MB by default, ala "-b 2048").

By: Tilghman Lesher (tilghman) 2004-04-10 15:03:37

Please change your patch format to unified (i.e. the -u flag).

By: twisted (twisted) 2004-04-18 00:56:21

Please update this patch and file disclaimer ASAP if you are serious about seeing this inlcluded.

By: Ernani José Camargo Azevedo (azevedo) 2004-04-18 01:54:09

Patch in unified format (sorry for the old patch).
I've also changed the buffering flag to not be used when playing a URL stream.

By: twisted (twisted) 2004-04-18 10:48:26

I will try to put the anvil down on this patch tonight.  I want to see if it works against current cvs-head and cvs-stable, and if there's any way I can force it to break.

If anyone else wants to test this with me, or before me, go right ahead.   I just want to see how well this patch will handle current revisions, odd and/or malformed url's.  I know obviously with malformed urls, we can't get a stream from them, but hopefully it won't bring down the channel or cause a crash.

azevedo: do you have a disclaimer on file with digium?

By: Ernani José Camargo Azevedo (azevedo) 2004-04-18 12:31:07

Twisted: I'll send the disclaimer on monday (I don't have a fax machine at home).

By: Ernani José Camargo Azevedo (azevedo) 2004-04-19 15:27:50

The fax was sent. If need any other information, please contact me.

By: twisted (twisted) 2004-04-29 23:17:39

Lets get this updated to latest CVS and pushed out.. I like it.

By: Brian West (bkw918) 2004-05-01 16:51:25

I think a similar fix was already added if this isn't the case let me know.

bkw