iowatcher: Fix a label overflow in plot_io
authorAndrew Price <anprice@redhat.com>
Thu, 5 Sep 2013 16:35:04 +0000 (17:35 +0100)
committerChris Mason <clm@fb.com>
Wed, 24 Sep 2014 19:02:08 +0000 (12:02 -0700)
commit9d382df04ccc0f145e7f13a23757b3d0ba5a9524
tree353c9df0bdc448430c0e540710de713bd8e64c25
parent7a51b395a7cf1218d2ad55008d5a64cd7721a057
iowatcher: Fix a label overflow in plot_io

The length of the label option wasn't being checked before strcpy()ing
it into a char[256]. Use strncpy instead.

Signed-off-by: Andrew Price <anprice@redhat.com>
iowatcher/main.c