Tracking down an error that only occurs on certain older handsets running specific versions of Android leads to an obscure bug in a standard library routine.
https://news.realm.io/news/when-memmove-fails
An interesting read, but I was disappointed not to get down to the root cause: there’s a buggy memmove somewhere, and they were able to replace it - but what was the bug? It must have been very subtle.
The linked Android issue talks about the bug - the gcc intrinsic has some instructions in the wrong order.