mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 07:35:18 +00:00
Convert casts to unions, to fix alignment issues on Solaris
(closes issue #12932) Reported by: snuffy Patches: bug_12932_20080627.diff uploaded by snuffy (license 35) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@125386 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -114,7 +114,7 @@ static int ilbctolin_framein(struct ast_trans_pvt *pvt, struct ast_frame *f)
|
||||
/* Assuming there's space left, decode into the current buffer at
|
||||
the tail location. Read in as many frames as there are */
|
||||
int x,i;
|
||||
int16_t *dst = (int16_t *)pvt->outbuf;
|
||||
int16_t *dst = pvt->outbuf.i16;
|
||||
float tmpf[ILBC_SAMPLES];
|
||||
|
||||
if (f->datalen == 0) { /* native PLC, set fake f->datalen and clear plc_mode */
|
||||
@@ -174,7 +174,7 @@ static struct ast_frame *lintoilbc_frameout(struct ast_trans_pvt *pvt)
|
||||
/* Encode a frame of data */
|
||||
for (i = 0 ; i < ILBC_SAMPLES ; i++)
|
||||
tmpf[i] = tmp->buf[samples + i];
|
||||
iLBC_encode((unsigned char *) pvt->outbuf + datalen, tmpf, &tmp->enc);
|
||||
iLBC_encode( pvt->outbuf.uc + datalen, tmpf, &tmp->enc);
|
||||
|
||||
datalen += ILBC_FRAME_LEN;
|
||||
samples += ILBC_SAMPLES;
|
||||
|
Reference in New Issue
Block a user