]> git.baikalelectronics.ru Git - kernel.git/commit
net: off by one in inet6_pton()
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 13 Apr 2017 19:42:31 +0000 (22:42 +0300)
committerJens Axboe <axboe@fb.com>
Fri, 14 Apr 2017 20:08:54 +0000 (14:08 -0600)
commit83deaba305b389f14e5666be039452d65cfd91fd
tree3d4a3827e09b99da4c0a55b2a4d3d3b65aaebbd0
parent7287b4143d0026e0bc821a51078b53ec8f11130f
net: off by one in inet6_pton()

If "scope_len" is sizeof(scope_id) then we would put the NUL terminator
one space beyond the end of the buffer.

Fixes: 88b07fc90a7f ("net/utils: generic inet_pton_with_scope helper")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
net/core/utils.c