[FFmpeg-devel] [PATCH] Stricter const prototypes for sws_scale_*
Wed Jan 20 14:58:35 CET 2010
On Wed, Jan 20, 2010 at 03:09:22AM -0500, David Conrad wrote:
> On Jan 19, 2010, at 8:17 AM, Alexis Ballier wrote:
> > Since src[x] isn't modified either, this doesn't harm and it is imho
> > cleaner to declare the functions with the strictest prototype
> > possible.
> > As a side effect (that you probably couldn't care less), this fixes
> > backward compatibilty for calling sws_scale from c++ as it doesn't
> > allow converting ** to const ** but wants const* const*
> Apparently C type conversion rules don't acknowledge that conversion from char ** to char const* const* is safe, and clang and gcc both happily warn about it. And gstreamer is apparently complaining that it breaks their build since they use -Werror and there was no API bump for them to #ifdef against.
> Anyway, here's even more const qualifiers and a minor version bump, I dunno if C spec bugs deserve a major version bump.
> commit 51f46c3724eacc4441808bf67f1c11414548548e
> Author: David Conrad <lessen42 at gmail.com>
> Date: Wed Jan 20 03:08:26 2010 -0500
> More const-correctness for sws_scale
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Awnsering whenever a program halts or runs forever is
On a turing machine, in general impossible (turings halting problem).
On any real computer, always possible as a real computer has a finite number
of states N, and will either halt in less than N cycles or never halt.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
More information about the ffmpeg-devel