]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Make the data returned by devinfo harder to overflow.
authorimp <imp@FreeBSD.org>
Thu, 31 May 2018 02:57:58 +0000 (02:57 +0000)
committerimp <imp@FreeBSD.org>
Thu, 31 May 2018 02:57:58 +0000 (02:57 +0000)
commit2b7196294014b02c72b061f17c6748ec5dc7296d
tree26d930bc1d54812180b328116ff4e1b4abd84d21
parentf1d9e42fb6d614ed96ec01a7de4dc58894d31125
Make the data returned by devinfo harder to overflow.

Rather than using fixed-length strings, pack them into a string table
to return. Also expand the buffer from ~300 charaters to 3k. This should
be enough, even for USB.

This fixes a problem where USB pnp info is truncated on return to
userland.

Differential Revision: https://reviews.freebsd.org/D15629
sys/kern/subr_bus.c
sys/sys/bus.h