[FFmpeg-devel] [PATCH]lavc/opus_rc: Case a const pointer to uint8_t *
Carl Eugen Hoyos
ceffmpeg at gmail.com
Mon Dec 17 23:40:49 EET 2018
2018-12-17 22:37 GMT+01:00, Paul B Mahol <onemda at gmail.com>:
> On 12/17/18, Carl Eugen Hoyos <ceffmpeg at gmail.com> wrote:
>> 2018-12-17 22:29 GMT+01:00, Paul B Mahol <onemda at gmail.com>:
>>> On 12/17/18, Carl Eugen Hoyos <ceffmpeg at gmail.com> wrote:
>>>> 2018-12-17 22:26 GMT+01:00, Paul B Mahol <onemda at gmail.com>:
>>>>> On 12/17/18, Carl Eugen Hoyos <ceffmpeg at gmail.com> wrote:
>>>>>> 2018-12-17 2:47 GMT+01:00, Carl Eugen Hoyos <ceffmpeg at gmail.com>:
>>>>>>
>>>>>>> The Opus struct RawBitsContext is used in both the decoder and the
>>>>>>> encoder.
>>>>>>> The fact that *position is const avoids warnings in the decoder where
>>>>>>> it points into the bitstream. The encoder writes into the same
>>>>>>> pointer, attached cast silences the warning on targets where
>>>>>>> AV_WB32()
>>>>>>> does not internally cast the qualifier away.
>>>>>>
>>>>>> Ping.
>>>>>
>>>>> Anonymous unions are not accepted. NAK 2X!
>>>>
>>>> Again: There is no union in this patch.
>>>
>>> Use "grep union" on your patch.
>>
>> $ grep union 0001-lavc-opus_rc-Cast-a-const-pointer-to-uint8_t.patch
>> $
>
> Why you posted two variants of patch in single mail?
>
> This is extremely confusing.
Sorry: I posted a patch and I mentioned that the only alternative
that I saw is an ugly union (in case somebody doesn't like the
cast).
As explained in my original mail, the same definition is used
by two different parts of the code with different semantics, it
is not possible to simply drop the const.
Carl Eugen
More information about the ffmpeg-devel
mailing list