diff mbox series

[FFmpeg-devel] avcodec/decode: remove unused AVCodecInternal compat_decode field

Message ID 20200309021955.9691-1-jamrial@gmail.com
State New
Headers show
Series [FFmpeg-devel] avcodec/decode: remove unused AVCodecInternal compat_decode field | expand

Checks

Context Check Description
andriy/ffmpeg-patchwork success Make fate finished

Commit Message

James Almer March 9, 2020, 2:19 a.m. UTC
Signed-off-by: James Almer <jamrial@gmail.com>
---
 libavcodec/decode.c   | 1 -
 libavcodec/internal.h | 1 -
 2 files changed, 2 deletions(-)

Comments

Hendrik Leppkes March 9, 2020, 9:09 a.m. UTC | #1
On Mon, Mar 9, 2020 at 3:20 AM James Almer <jamrial@gmail.com> wrote:
>
> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
>  libavcodec/decode.c   | 1 -
>  libavcodec/internal.h | 1 -
>  2 files changed, 2 deletions(-)
>
> diff --git a/libavcodec/decode.c b/libavcodec/decode.c
> index 03b9da25f9..0e3d7e17e4 100644
> --- a/libavcodec/decode.c
> +++ b/libavcodec/decode.c
> @@ -826,7 +826,6 @@ static int compat_decode(AVCodecContext *avctx, AVFrame *frame,
>      }
>
>      *got_frame = 0;
> -    avci->compat_decode = 1;
>
>      if (avci->compat_decode_partial_size > 0 &&
>          avci->compat_decode_partial_size != pkt->size) {
> diff --git a/libavcodec/internal.h b/libavcodec/internal.h
> index bccd9222d4..972e93bcfa 100644
> --- a/libavcodec/internal.h
> +++ b/libavcodec/internal.h
> @@ -208,7 +208,6 @@ typedef struct AVCodecInternal {
>      AVFrame *buffer_frame;
>      int draining_done;
>      /* set to 1 when the caller is using the old decoding API */
> -    int compat_decode;
>      int compat_decode_warned;
>      /* this variable is set by the decoder internals to signal to the old
>       * API compat wrappers the amount of data consumed from the last packet */

The comment above it seems to want to reference the removed field?

- Hendrik
James Almer March 9, 2020, 12:09 p.m. UTC | #2
On 3/9/2020 6:09 AM, Hendrik Leppkes wrote:
> On Mon, Mar 9, 2020 at 3:20 AM James Almer <jamrial@gmail.com> wrote:
>>
>> Signed-off-by: James Almer <jamrial@gmail.com>
>> ---
>>  libavcodec/decode.c   | 1 -
>>  libavcodec/internal.h | 1 -
>>  2 files changed, 2 deletions(-)
>>
>> diff --git a/libavcodec/decode.c b/libavcodec/decode.c
>> index 03b9da25f9..0e3d7e17e4 100644
>> --- a/libavcodec/decode.c
>> +++ b/libavcodec/decode.c
>> @@ -826,7 +826,6 @@ static int compat_decode(AVCodecContext *avctx, AVFrame *frame,
>>      }
>>
>>      *got_frame = 0;
>> -    avci->compat_decode = 1;
>>
>>      if (avci->compat_decode_partial_size > 0 &&
>>          avci->compat_decode_partial_size != pkt->size) {
>> diff --git a/libavcodec/internal.h b/libavcodec/internal.h
>> index bccd9222d4..972e93bcfa 100644
>> --- a/libavcodec/internal.h
>> +++ b/libavcodec/internal.h
>> @@ -208,7 +208,6 @@ typedef struct AVCodecInternal {
>>      AVFrame *buffer_frame;
>>      int draining_done;
>>      /* set to 1 when the caller is using the old decoding API */
>> -    int compat_decode;
>>      int compat_decode_warned;
>>      /* this variable is set by the decoder internals to signal to the old
>>       * API compat wrappers the amount of data consumed from the last packet */
> 
> The comment above it seems to want to reference the removed field?

Good catch. Removed locally.

> 
> - Hendrik
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
>
James Almer May 10, 2020, 12:03 a.m. UTC | #3
On 3/9/2020 9:09 AM, James Almer wrote:
> On 3/9/2020 6:09 AM, Hendrik Leppkes wrote:
>> On Mon, Mar 9, 2020 at 3:20 AM James Almer <jamrial@gmail.com> wrote:
>>>
>>> Signed-off-by: James Almer <jamrial@gmail.com>
>>> ---
>>>  libavcodec/decode.c   | 1 -
>>>  libavcodec/internal.h | 1 -
>>>  2 files changed, 2 deletions(-)
>>>
>>> diff --git a/libavcodec/decode.c b/libavcodec/decode.c
>>> index 03b9da25f9..0e3d7e17e4 100644
>>> --- a/libavcodec/decode.c
>>> +++ b/libavcodec/decode.c
>>> @@ -826,7 +826,6 @@ static int compat_decode(AVCodecContext *avctx, AVFrame *frame,
>>>      }
>>>
>>>      *got_frame = 0;
>>> -    avci->compat_decode = 1;
>>>
>>>      if (avci->compat_decode_partial_size > 0 &&
>>>          avci->compat_decode_partial_size != pkt->size) {
>>> diff --git a/libavcodec/internal.h b/libavcodec/internal.h
>>> index bccd9222d4..972e93bcfa 100644
>>> --- a/libavcodec/internal.h
>>> +++ b/libavcodec/internal.h
>>> @@ -208,7 +208,6 @@ typedef struct AVCodecInternal {
>>>      AVFrame *buffer_frame;
>>>      int draining_done;
>>>      /* set to 1 when the caller is using the old decoding API */
>>> -    int compat_decode;
>>>      int compat_decode_warned;
>>>      /* this variable is set by the decoder internals to signal to the old
>>>       * API compat wrappers the amount of data consumed from the last packet */
>>
>> The comment above it seems to want to reference the removed field?
> 
> Good catch. Removed locally.

Applied.
diff mbox series

Patch

diff --git a/libavcodec/decode.c b/libavcodec/decode.c
index 03b9da25f9..0e3d7e17e4 100644
--- a/libavcodec/decode.c
+++ b/libavcodec/decode.c
@@ -826,7 +826,6 @@  static int compat_decode(AVCodecContext *avctx, AVFrame *frame,
     }
 
     *got_frame = 0;
-    avci->compat_decode = 1;
 
     if (avci->compat_decode_partial_size > 0 &&
         avci->compat_decode_partial_size != pkt->size) {
diff --git a/libavcodec/internal.h b/libavcodec/internal.h
index bccd9222d4..972e93bcfa 100644
--- a/libavcodec/internal.h
+++ b/libavcodec/internal.h
@@ -208,7 +208,6 @@  typedef struct AVCodecInternal {
     AVFrame *buffer_frame;
     int draining_done;
     /* set to 1 when the caller is using the old decoding API */
-    int compat_decode;
     int compat_decode_warned;
     /* this variable is set by the decoder internals to signal to the old
      * API compat wrappers the amount of data consumed from the last packet */