diff options
author | Lee Jones <lee.jones@linaro.org> | 2014-08-28 09:14:09 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-09-24 02:14:28 -0400 |
commit | ffdbb715fa0c53203b1ea2a6ecc54bdcc8951612 (patch) | |
tree | deaf176903bb7cfb7856c68f7cc56cbb717821e1 | |
parent | e4ebe5fe2d507a4c228bf90dea7dd4de57cbce92 (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>
-rw-r--r-- | include/linux/ti_wilink_st.h | 2 |
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 { | |||
268 | struct st_data_s *core_data; | 268 | struct st_data_s *core_data; |
269 | struct chip_version version; | 269 | struct chip_version version; |
270 | unsigned char ldisc_install; | 270 | unsigned char ldisc_install; |
271 | unsigned char dev_name[UART_DEV_NAME_LEN]; | 271 | unsigned char dev_name[UART_DEV_NAME_LEN + 1]; |
272 | unsigned char flow_cntrl; | 272 | unsigned char flow_cntrl; |
273 | unsigned long baud_rate; | 273 | unsigned long baud_rate; |
274 | }; | 274 | }; |