]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC r258426: libexecinfo: Include terminating null in byte count
authoremaste <emaste@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 25 Nov 2013 15:54:18 +0000 (15:54 +0000)
committeremaste <emaste@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 25 Nov 2013 15:54:18 +0000 (15:54 +0000)
commit4f651f3aa7b635540ebd061c7b01dd6c153b4596
tree837c967036574a6d50d6fda1d3d8104091dd6aff
parentc30ba8873b9340e0c3fcc406eed52db8e159d946
MFC r258426: libexecinfo: Include terminating null in byte count

  Otherwise, a formatted string with a strlen equal to the remaining
  buffer space would have the last character omitted (because vsnprintf
  always null-terminates), and later the assert in backtrace_symbols_fmt
  would fail.

Sponsored by: DARPA, AFRL
Approved by: re (gjb)

git-svn-id: svn://svn.freebsd.org/base/stable/10@258558 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
contrib/libexecinfo/backtrace.c