SVNews r322427

NOTE: This service is experimental and subject to change! Use at your own risk!

2017-08-12 15:18:17 - r322427 by kib (Konstantin Belousov)

Complete list of files affected by revision r322427:

(Note: At the moment, these links point to ViewVC on They are probably slow. Do not overuse.)

  History   Contents   Diff   MODIFY   /head/lib/libc/stdlib/set_constraint_handler_s.c  
  History   Contents   Diff   MODIFY   /head/lib/libc/string/memset_s.c  
  History   Contents   Diff   MODIFY   /head/lib/libc/tests/string/memset_s_test.c  

Commit message:

Improve standard compliance for memset_s() and abort_handler_s().

abort_handler_s() currently simply calls abort(), though the standard
specifies more: "Writes an implementation-defined message to stderr
which must include the string pointed to by msg and calls abort()."

memset_s() is missing error condition "n > smax", and does not invoke
the constraint handler after filling the buffer: "following errors are
detected at runtime and call the currently installed constraint
handler function after storing ch in every location of the destination
range [dest, dest+destsz) if dest and destsz are themselves valid",
one of the errors is "n > smax" itself.

Submitted by: Yuri Pankov <>
MFC after: 1 week
Differential revision:


Powered by Python FreeBSD support by secnetix GmbH & Co. KG

Page generated in 31 ms, 3 files printed. Current time is 2018-03-22 04:00:31. All times are in UTC/GMT.