diff options
author | Tomas Kukosa <tomas.kukosa@siemens.com> | 2007-12-11 11:54:15 +0000 |
---|---|---|
committer | Tomas Kukosa <tomas.kukosa@siemens.com> | 2007-12-11 11:54:15 +0000 |
commit | 910c8f628197dbefadb5545ddf1a5943fa29567c (patch) | |
tree | d048dd37c707f4a892de4cf575acb1eb5dcc106f /plugins/easy_codec/codec-g722.c | |
parent | 2ce05b41ebe711d162540ba568243877552068d8 (diff) | |
download | wireshark-910c8f628197dbefadb5545ddf1a5943fa29567c.tar.gz |
From Ales Kocourek
example plugin updated
svn path=/trunk/; revision=23839
Diffstat (limited to 'plugins/easy_codec/codec-g722.c')
-rw-r--r-- | plugins/easy_codec/codec-g722.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/easy_codec/codec-g722.c b/plugins/easy_codec/codec-g722.c index 22a56f91ca..576d15a085 100644 --- a/plugins/easy_codec/codec-g722.c +++ b/plugins/easy_codec/codec-g722.c @@ -68,14 +68,14 @@ int codec_g722_decode(void *context, const void *input, int inputSizeBytes, void return 0; if (!output) - return (inputSizeBytes / L_G722_FRAME_COMPRESSED) * L_G722_FRAME * sizeof(short); + return (inputSizeBytes / L_G722_FRAME_COMPRESSED ) * L_G722_FRAME / 2 * sizeof(short) ; while ((inputSizeBytes >= L_G722_FRAME_COMPRESSED) && - ((*outputSizeBytes - decodedBytes) >= L_G722_FRAME * sizeof(short))) { + ((*outputSizeBytes - decodedBytes) >= L_G722_FRAME / 2 * sizeof(short))) { if (EasyG722_decoder(ctx->handle, (unsigned char*)bitstream, ctx->speach_buffer)) { int write_index = 0; - for(i = 0; i < L_G722_FRAME * sizeof(short); i+=2) { + for(i = 0; i < L_G722_FRAME; i+=2) { ctx->speach_buffer[write_index] = ctx->speach_buffer[i]; write_index++; } |