[vlc-devel] [PATCH 1/2] compat: Workaround sendmsg bug on some ArmV8 Android devices
hugo at beauzee.fr
Thu Apr 4 14:21:30 CEST 2019
On Thu, Apr 4, 2019, at 2:07 PM, Rémi Denis-Courmont wrote:
> I can only think of three ways to solve this:
> 1) Custom headers pretending that return type is int (will potentially
> break non-buggy devices tough).
> 2) Interposed wrappers for all affected calls.
> 3) Replacement (asm) implementation for all affected calls.
> It can't be done in VLC build system as the problem affects contribs too.
> Le 4 avril 2019 14:45:53 GMT+03:00, "Hugo Beauzée-Luyssen"
> <hugo at beauzee.fr> a écrit : On Thu, Apr 4, 2019, at 1:42 PM, Rémi
> Denis-Courmont wrote:
> >> Hi all,
> >> 5 minutes git archeology through bionic repo leads to this:
> >> https://android.googlesource.com/platform/bionic.git/+/3d19a8319b9c27af8aa5cfbf495da0fe7fa62d3e
> >> The bug affect basically all system call wrappers with a signed 64-bits
> >> return value type (including ssize_t).
> >> Clearly this patch ain't going to work.
> >> Le 4 avril 2019 10:54:44 GMT+03:00, "Hugo Beauzée-Luyssen"
> >> <hugo at beauzee.fr> a écrit : On Wed, Apr 3, 2019, at 9:24 PM, Rémi
> >> Denis-Courmont wrote:
> >>>> I don't know what you did or did not imply. When somebody states that a patch
> >>>> is ugly, I tend to assume that they dislike the form rather than the essence.
> >>>> My chief concerns are that, on the one hand, other system calls may also
> >>>> exhibit the bug, and on the other hand, contribs may be affected as well. In
> >>>> other words, I am concerned not that the patch is ugly, but that does not
> >>>> solve the problem(s).
> >>> It solves the observed problem, but it doesn't solve problems I don't know about indeed.
> > Hi,
> > Let aside the passive aggressiveness of the reply, this is exactly what I was hoping for by submitting the patch, that someone who knows libc/kernel more than I do figures out what the problem is.
> > I looked at the syscall wrapper but did not check the __set_errno it called, that's my bad.
> > Thanks for finding the actual error.
I think it can be solved in the same way we use libwinstorecompat to remove forbidden calls on WinRT, including in the contribs.
I'll try to take a look at this sometime soon
hugo at beauzee.fr
More information about the vlc-devel