shithub: opus

Download patch

ref: c0387ff23739cb450eb41acd078763dd7ab9ec94
parent: 3e4afc6fd2b03616db34098d5131f7f1bd3c0e32
author: Jean-Marc Valin <[email protected]>
date: Mon Mar 5 14:19:59 EST 2012

More consistent types for 16-bit architectures

--- a/celt/celt.c
+++ b/celt/celt.c
@@ -2742,7 +2742,7 @@
       break;
       case CELT_GET_AND_CLEAR_ERROR_REQUEST:
       {
-         int *value = va_arg(ap, opus_int32*);
+         opus_int32 *value = va_arg(ap, opus_int32*);
          if (value==NULL)
             goto bad_arg;
          *value=st->error;
@@ -2751,7 +2751,7 @@
       break;
       case OPUS_GET_LOOKAHEAD_REQUEST:
       {
-         int *value = va_arg(ap, opus_int32*);
+         opus_int32 *value = va_arg(ap, opus_int32*);
          if (value==NULL)
             goto bad_arg;
          *value = st->overlap/st->downsample;
@@ -2774,7 +2774,7 @@
       break;
       case OPUS_GET_PITCH_REQUEST:
       {
-         int *value = va_arg(ap, opus_int32*);
+         opus_int32 *value = va_arg(ap, opus_int32*);
          if (value==NULL)
             goto bad_arg;
          *value = st->postfilter_period;
--- a/src/opus_decoder.c
+++ b/src/opus_decoder.c
@@ -830,7 +830,7 @@
    break;
    case OPUS_GET_PITCH_REQUEST:
    {
-      int *value = va_arg(ap, opus_int32*);
+      opus_int32 *value = va_arg(ap, opus_int32*);
       if (value==NULL)
       {
          ret = OPUS_BAD_ARG;
--- a/src/opus_private.h
+++ b/src/opus_private.h
@@ -81,6 +81,6 @@
     return (i+3)&-4;
 }
 
-int opus_repacketizer_out_range_impl(OpusRepacketizer *rp, int begin, int end, unsigned char *data, int maxlen, int self_delimited);
+int opus_repacketizer_out_range_impl(OpusRepacketizer *rp, int begin, int end, unsigned char *data, opus_int32 maxlen, int self_delimited);
 
 #endif /* OPUS_PRIVATE_H */