libmultipath: Fix buffer overflow in parse_vpd_pg80()
authorMartin Wilck <mwilck@suse.com>
Mon, 24 Jun 2019 09:27:41 +0000 (11:27 +0200)
committerChristophe Varoqui <christophe.varoqui@opensvc.com>
Wed, 3 Jul 2019 06:31:26 +0000 (08:31 +0200)
commitdbb1f92fbdec099c93faf3df0ed5bfa27b9f9791
tree6cbd877f0aa6953d5eeb198b28c5c13e9c99a6bc
parentfb400653a522a02a3f6b2b20c80fbf8a9a468536
libmultipath: Fix buffer overflow in parse_vpd_pg80()

We set out[len] = '\0' later, thus we should set len to no more then
out_len - 1.

Fixes: 756ef73b7197 "Separate out vpd parsing functions"
Signed-off-by: Martin Wilck <mwilck@suse.com>
libmultipath/discovery.c