[asterisk-bugs] [Asterisk 0012674]: [branch] revert ast_queue_hangup and create ast_queue_hangup_with_cause

noreply at bugs.digium.com noreply at bugs.digium.com
Thu May 22 11:24:03 CDT 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=12674 
====================================================================== 
Reported By:                mvanbaak
Assigned To:                mvanbaak
====================================================================== 
Project:                    Asterisk
Issue ID:                   12674
Category:                   General
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     ready for testing
Asterisk Version:           SVN 
SVN Branch (only for SVN checkouts, not tarball releases):  trunk 
SVN Revision (number only!): 117135 
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             05-17-2008 08:05 CDT
Last Modified:              05-22-2008 11:24 CDT
====================================================================== 
Summary:                    [branch] revert ast_queue_hangup and create
ast_queue_hangup_with_cause
Description: 
Recently, ast_queue_hangup got an extra parameter to set the hangupcause.
Some people told me that was not ok and there should be an
ast_queue_hangup_with_cause.
The second thing in this commit that was not ok, was the use of
ast_frame.seqno for the hangupcause.
I addressed that in this patch as well.
====================================================================== 

---------------------------------------------------------------------- 
 svnbot - 05-22-08 11:24  
---------------------------------------------------------------------- 
Repository: asterisk
Revision: 117802

U   trunk/apps/app_alarmreceiver.c
U   trunk/apps/app_chanspy.c
U   trunk/apps/app_dial.c
U   trunk/apps/app_disa.c
U   trunk/apps/app_externalivr.c
U   trunk/apps/app_festival.c
U   trunk/apps/app_followme.c
U   trunk/apps/app_ices.c
U   trunk/apps/app_meetme.c
U   trunk/apps/app_milliwatt.c
U   trunk/apps/app_mp3.c
U   trunk/apps/app_nbscat.c
U   trunk/apps/app_queue.c
U   trunk/apps/app_sms.c
U   trunk/apps/app_speech_utils.c
U   trunk/apps/app_test.c
U   trunk/apps/app_zapbarge.c
U   trunk/apps/app_zapscan.c
U   trunk/channels/chan_alsa.c
U   trunk/channels/chan_console.c
U   trunk/channels/chan_gtalk.c
U   trunk/channels/chan_h323.c
U   trunk/channels/chan_iax2.c
U   trunk/channels/chan_jingle.c
U   trunk/channels/chan_local.c
U   trunk/channels/chan_mgcp.c
U   trunk/channels/chan_misdn.c
U   trunk/channels/chan_oss.c
U   trunk/channels/chan_phone.c
U   trunk/channels/chan_sip.c
U   trunk/channels/chan_skinny.c
U   trunk/channels/chan_unistim.c
U   trunk/channels/chan_zap.c
U   trunk/channels/iax2-parser.c
U   trunk/codecs/codec_a_mu.c
U   trunk/codecs/codec_adpcm.c
U   trunk/codecs/codec_alaw.c
U   trunk/codecs/codec_g722.c
U   trunk/codecs/codec_g726.c
U   trunk/codecs/codec_gsm.c
U   trunk/codecs/codec_lpc10.c
U   trunk/codecs/codec_resample.c
U   trunk/codecs/codec_ulaw.c
U   trunk/codecs/codec_zap.c
U   trunk/formats/format_g723.c
U   trunk/formats/format_g726.c
U   trunk/formats/format_g729.c
U   trunk/formats/format_gsm.c
U   trunk/formats/format_h263.c
U   trunk/formats/format_h264.c
U   trunk/formats/format_ilbc.c
U   trunk/formats/format_jpeg.c
U   trunk/formats/format_pcm.c
U   trunk/formats/format_sln.c
U   trunk/formats/format_sln16.c
U   trunk/formats/format_vox.c
U   trunk/formats/format_wav.c
U   trunk/formats/format_wav_gsm.c
U   trunk/include/asterisk/channel.h
U   trunk/include/asterisk/frame.h
U   trunk/main/abstract_jb.c
U   trunk/main/app.c
U   trunk/main/audiohook.c
U   trunk/main/channel.c
U   trunk/main/dsp.c
U   trunk/main/features.c
U   trunk/main/file.c
U   trunk/main/frame.c
U   trunk/main/indications.c
U   trunk/main/rtp.c
U   trunk/main/slinfactory.c
U   trunk/main/translate.c
U   trunk/main/udptl.c
U   trunk/res/res_adsi.c
U   trunk/res/res_agi.c
U   trunk/res/res_musiconhold.c

------------------------------------------------------------------------
r117802 | mvanbaak | 2008-05-22 11:23:57 -0500 (Thu, 22 May 2008) | 21
lines

- revert change to ast_queue_hangup and create ast_queue_hangup_with_cause
- make data member of the ast_frame struct a named union instead of a void

Recently the ast_queue_hangup function got a new parameter, the
hangupcause
Feedback came in that this is no good and that instead a new function
should be created.
This I did.

The hangupcause was stored in the seqno member of the ast_frame struct.
This is not very
elegant, and since there's already a data member that one should be used.
Problem is, this member was a void *.
Now it's a named union so it can hold a pointer, an uint32 and there's a
padding in case someone
wants to store another type in there in the future.

This commit is so massive, because all ast_frame.data uses have to be
altered to ast_frame.data.data

Thanks russellb and kpfleming for the feedback.

(closes issue http://bugs.digium.com/view.php?id=12674)
Reported by: mvanbaak

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=117802 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
05-22-08 11:24  svnbot         Note Added: 0087211                          
======================================================================




More information about the asterisk-bugs mailing list