[Home]

Summary:ASTERISK-07181: [patch] wav49 format issue
Reporter:Curt Moore (jcmoore)Labels:
Date Opened:2006-06-15 17:43:08Date Closed:2006-06-20 17:23:13
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/CodecInterface
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) format_wav_gsm.patch.txt
Description:It appears that the current trunk has issues correctly generating a wav49 (GSM compressed WAV) file.  While the WAV file which is generated will play without issue in Asterisk, it will not play in Windows Media Player.  When the file is played using the "play" command in Linux (FC5), the file will play but SoX gives the following error: "sox: invalid wav gsm frame size: 1 bytes".  

I came across this issue when saving voicemail messages in wav49 format and then having a user try to open the file as a result of having it emailed to them.  WMP complains about an unknown codec.

This functionality works without issue on the latest 1.2 trunk.

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

I've also duplicated this using the convert command line utility from within the Asterisk CLI. Example: "testbox*CLI> convert tt-weasels.gsm tt-weasels.WAV"  The resulting tt-weasels.WAV file will not play in WMP.

Comments:By: Curt Moore (jcmoore) 2006-06-20 12:40:35

I backported res_convert from trunk to 1.2 and after lots of combing through the binary wav49 files generated by convert in 1.2 vs those in trunk and analyzing them with od I believe I've found the culprit.  It appears that during the cleanup of format_wav_gsm.c, the data type of one of the variables was changed, causing some weirdness in the format of the resulting wav49 file. After making the change outlined in the patch, I am again able to play wav49 files in WMP. Yay.

By: Serge Vecher (serge-v) 2006-06-20 15:32:21

ha, nice catch

By: Tilghman Lesher (tilghman) 2006-06-20 17:23:13

Committed to trunk.