Optimise GPrivate by removing one malloc
Submitted by Allison (desrt)
Link to original bug (#737445)
Description
We could avoid an extra malloc() in the implementation of GPrivate on Linux. Here's some patches for that.
It may also be possible to implement GPrivate more efficiently for ourselves, but that is a story for later...
Note that the memcpy() calls in these patches are required to avoid breaking strict aliasing rules. Since the operation is being performed with a small constant size, it is optimised out by the compiler and replaced with a simple assignment.