Skip to content

Commit 620b4ff

Browse files
committed
Update fw version string to expected size
changed the 64 byte buffer sent to switchtec_get_fw_version function to 32. Since we are expecting the version information to be at most 32 bytes there is no need to have the destination buffer set to 64 when strncpy is called in the switchtec_get_fw_version function within lib/platform/platform.c.
1 parent 19a570c commit 620b4ff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cli/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ static int print_dev_info(struct switchtec_dev *dev)
188188
{
189189
int ret;
190190
int device_id;
191-
char version[64];
191+
char version[32];
192192
enum switchtec_boot_phase phase;
193193
enum switchtec_rev hw_rev;
194194

0 commit comments

Comments
 (0)