roken: Add memset_s implementation

Add an implementation of memset_s to roken.

Some optimising compilers may remove the memset() instruction when it
is used immediately before a free, which defeats its purpose if the
intention is to zero memory before returning it to the heap or stack.

C11 added memset_s, provide a fallback in roken so that memset_s can
be used on all platforms.
This commit is contained in:
Simon Wilkinson
2015-03-05 10:34:09 +00:00
parent 745eeb1252
commit 8485250989
5 changed files with 61 additions and 0 deletions

View File

@@ -351,6 +351,7 @@ AC_BROKEN([ \
localtime_r \
lstat \
memmove \
memset_s \
mkstemp \
putenv \
rcmd \