summaryrefslogtreecommitdiff
path: root/include/linux/ti_wilink_st.h
diff options
context:
space:
mode:
authorLee Jones <lee.jones@linaro.org>2014-08-28 14:14:09 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-09-23 23:14:28 -0700
commitffdbb715fa0c53203b1ea2a6ecc54bdcc8951612 (patch)
treedeaf176903bb7cfb7856c68f7cc56cbb717821e1 /include/linux/ti_wilink_st.h
parente4ebe5fe2d507a4c228bf90dea7dd4de57cbce92 (diff)
misc: st_kim: Increase size of dev_name buffer to incorporate termination
Calling strncpy with a maximum size argument of 32 bytes on destination array kim_gdata->dev_name of size 32 bytes might leave the destination string unterminated. Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/ti_wilink_st.h')
-rw-r--r--include/linux/ti_wilink_st.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/ti_wilink_st.h b/include/linux/ti_wilink_st.h
index 932b76392248..884d6263e962 100644
--- a/include/linux/ti_wilink_st.h
+++ b/include/linux/ti_wilink_st.h
@@ -268,7 +268,7 @@ struct kim_data_s {
struct st_data_s *core_data;
struct chip_version version;
unsigned char ldisc_install;
- unsigned char dev_name[UART_DEV_NAME_LEN];
+ unsigned char dev_name[UART_DEV_NAME_LEN + 1];
unsigned char flow_cntrl;
unsigned long baud_rate;
};