[vlc-devel] [PATCH v2] package/win32: build.sh: trigger build errors on dubious pointer use

Rémi Denis-Courmont remi at remlab.net
Tue Mar 17 15:00:52 CET 2020


Le tiistaina 17. maaliskuuta 2020, 14.53.13 EET Steve Lhomme a écrit :
> On 2020-03-17 13:44, Rémi Denis-Courmont wrote:
> > Le tiistaina 17. maaliskuuta 2020, 14.08.18 EET Steve Lhomme a écrit :
> >> As 48442d3536edae578f1a384e73346d1e2a4c0061 proved, people don't read
> >> warnings.
> > 
> > If you don't read warnings, you're free to enable warning as error in YOUR
> > build.
> 
> I do but nobody is perfect. And some warnings are more important than
> others. Pointer safety is at the top of my priorities.

Then you don't need this patch at all.

> > There are plenty of cases were pointer type warnings are harmless, or
> > theoretically invalid but practically harmless (especially on Windows,
> > which institutionalized aliasing violations).
> 
> Again, this is at best theoretical. I have neither any of those issues
> with master for months with clang and gcc. So please provide an example
> where this would create an error when it shouldn't.

Again *almost* every COM instantiation in the VLC code base (and in many other 
code bases) is an invalid pointer conversion. And it's helplessly muted by an 
explicit but invalid cast to void **.

And that's just an example of a class.

-- 
Реми Дёни-Курмон
http://www.remlab.net/





More information about the vlc-devel mailing list