]> granicus.if.org Git - zfs/commit
Fix strncpy in taskq_create
authorcandychencan <chen.can2@zte.com.cn>
Tue, 20 Sep 2016 18:27:15 +0000 (02:27 +0800)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Tue, 20 Sep 2016 18:27:15 +0000 (11:27 -0700)
commitd2a6f65cfb65ec3079f843542a156704264260be
tree1d86e553f6984c3e2642dfc08ca35b4ac9c2540b
parent792517389fad5c495a2738b61c2e9c65dedaaa9a
Fix strncpy in taskq_create

Assign the copy length to TASKQ_NAMELEN, so if the name length equals
'TASKQ_NAMELEN+1' , the final '\0' of tq->tq_name is preserved.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: candychencan <chen.can2@zte.com.cn>
Closes #5136
lib/libzpool/taskq.c