* Marcel Plch:

> Hello, Florian,
>
> I don't see any problem in this.
> Even if an extension function receives a pointer to a local variable,
> it should be fine as long as the variable is up the stack. Should it be
> downwards, it is undefined behavior anyways, linked or not.
> Maybe I have just misunderstood, can you please come up with a specific
> scenario, even better an example, where the problem occurs?

If you take the address of a local variable and pass the resulting
pointer to another function, the compiler will generate a call to
__stack_chk_fail, which lives in glibc.  At build time, linking against
glibc is required so that this symbol receives its proper version,
otherwise the resulting binary is invalid and may not be compatible with
future glibc versions.

Thanks,
Florian
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org

Reply via email to