Browse Source

isp1704_charger: Correct length for storing model

Model should have room to accommodate the trailing null byte,
"isp170[4|7]\0".

Signed-off-by: Ameya Palande <ameya.palande@nokia.com>
Acked-by: Heikki Krogerus <heikki.krogerus@nokia.com>
Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
Ameya Palande 14 năm trước cách đây
mục cha
commit
746d8fb8c6
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      drivers/power/isp1704_charger.c

+ 1 - 1
drivers/power/isp1704_charger.c

@@ -59,7 +59,7 @@ struct isp1704_charger {
 	struct notifier_block	nb;
 	struct work_struct	work;
 
-	char			model[7];
+	char			model[8];
 	unsigned		present:1;
 };