]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/shorten.c
h264: (trivial) remove unneeded macro argument in x86/cabac.h
[ffmpeg] / libavcodec / shorten.c
index ef58aaa6aaeeaeb0c7713b8d4198aa207b01818d..ece651d15927736215177c7a5baa9d7660f058f8 100644 (file)
@@ -141,7 +141,8 @@ static int allocate_buffers(ShortenContext *s)
             return AVERROR(ENOMEM);
         s->offset[chan] = tmp_ptr;
 
-        tmp_ptr = av_realloc(s->decoded_base[chan], sizeof(int32_t)*(s->blocksize + s->nwrap));
+        tmp_ptr = av_realloc(s->decoded_base[chan], (s->blocksize + s->nwrap) *
+                             sizeof(s->decoded_base[0][0]));
         if (!tmp_ptr)
             return AVERROR(ENOMEM);
         s->decoded_base[chan] = tmp_ptr;
@@ -190,7 +191,7 @@ static int init_offset(ShortenContext *s)
             mean = 0;
             break;
         default:
-            av_log(s->avctx, AV_LOG_ERROR, "unknown audio type");
+            av_log(s->avctx, AV_LOG_ERROR, "unknown audio type\n");
             return AVERROR_INVALIDDATA;
     }
 
@@ -637,5 +638,5 @@ AVCodec ff_shorten_decoder = {
     .close          = shorten_decode_close,
     .decode         = shorten_decode_frame,
     .capabilities   = CODEC_CAP_DELAY | CODEC_CAP_DR1,
-    .long_name= NULL_IF_CONFIG_SMALL("Shorten"),
+    .long_name      = NULL_IF_CONFIG_SMALL("Shorten"),
 };