The previous patch was a mistake: As already indicated, the actual bug is that an error instead of just an informative warning is reported. I had falsely assumed that this was a compiler default (perhaps caused by the default -DFORTIFY_SOURCE=2) and had missed that for this particular file the compiler flag -Werror has been passed. Of course, this flag should only be used by developers and is broken in production code exactly for this reason: Informative messages are not bugs. So the correct bugfix is to stop using -Werror which is done by the attached patch.