It's a bit hacky, but ATM I can't see any better way for glibc >= 2.28. Signed-off-by: Luka Blaskovic <lblasc@tvbeat.com>