[vlc-devel] [vlc-commits] Remove libvlc_free

Steve Lhomme robux4 at ycbcr.xyz
Wed May 22 11:06:45 CEST 2019


On 2019-05-22 10:18, Rémi Denis-Courmont wrote:
> Hi
> 
> It was never possible not to care about the C runtime. Calling LibVLC 

It depends on what you call "care about". Yes a C runtime is used when 
loading libvlc. But I don't think it's ever propagated to the C# layer.

And on Windows it's possible mix C runtimes. For example you can link 
your an app with runtime with some debug features (msvcrtd.lib or 
msvcurtd.lib) that doesn't mean everything you load will also use the 
same runtime. For example advapi32.dll will still use msvcrt.dll and 
work as expected. There are limits to how you can mix MSVC runtimes 
(https://docs.microsoft.com/en-us/cpp/c-runtime-library/potential-errors-passing-crt-objects-across-dll-boundaries?view=vs-2019) 
it's used all the time as long as you respect certain rules, which we 
did so far.

> without a C runtime or with a mismatched one is and always was UB by 
> design of the OS NDKs. Your delusions are not a design criteria, and I 
> would appreciate if you refrained from posting incorrect information 
> that may be misconstrued as guidance for LibVLC app developers.
> 
> Le 21 mai 2019 23:51:28 GMT+03:00, Jeremy Vignelles 
> <jeremy.vignelles at dev3i.fr> a écrit :
> 
>     So, what did the technical comittee decided in this regard?
> 
>         That means libvlc users in other languages have to make a call
>         to the C
>         runtime by themselves ? Right now it was possible to just take the
>         libvlc DLL and never have to deal with C at all.
> 
> 
>     Indeed, this is what have been done so far with LibVLCSharp for strings returned from libvlc and marked as "you must free them". Since .net does not have any implementation for freeing things from the native side.
> 
>     One might argue that the module that does the allocation needs to free it. In other words, I find it quite logical that the memory allocated from libvlc returns to libvlc.
>     ------------------------------------------------------------------------
>     vlc-devel mailing list
>     To unsubscribe or modify your subscription options:
>     https://mailman.videolan.org/listinfo/vlc-devel
> 
> 
> -- 
> Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser 
> ma brièveté.
> 
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
> 


More information about the vlc-devel mailing list