diff options
| author | Tom Rini <[email protected]> | 2023-10-10 08:54:17 -0400 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2023-10-10 08:54:17 -0400 |
| commit | 833ff23047c50e4053fb1bda21f4e2c9f6a3aa6a (patch) | |
| tree | 422a1ac1688b75a6c4edcbaa2024346acbaddfb8 /common/stdio.c | |
| parent | d9bb6d779b69c2548891e568e5e2a23e1b7eedaa (diff) | |
| parent | 3f876cb7c57511174d1b6a3e089443ccbaf236ec (diff) | |
Merge branch '2023-10-09-assorted-fixes'
- Cleanup how we pick what to launch in SPL, a few test changes, some TI
K3 platform updates, top-level Makefile fixes and related cleanup,
correct a problem with LMB overlap, other assorted fixes.
Diffstat (limited to 'common/stdio.c')
| -rw-r--r-- | common/stdio.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/common/stdio.c b/common/stdio.c index 010bf576af0..e3354f092dc 100644 --- a/common/stdio.c +++ b/common/stdio.c @@ -259,7 +259,7 @@ int stdio_register(struct stdio_dev *dev) int stdio_deregister_dev(struct stdio_dev *dev, int force) { struct list_head *pos; - char temp_names[3][16]; + char temp_names[3][STDIO_NAME_LEN]; int i; /* get stdio devices (ListRemoveItem changes the dev list) */ @@ -272,8 +272,8 @@ int stdio_deregister_dev(struct stdio_dev *dev, int force) /* Device is assigned -> report error */ return -EBUSY; } - memcpy(&temp_names[i][0], stdio_devices[i]->name, - sizeof(temp_names[i])); + strlcpy(&temp_names[i][0], stdio_devices[i]->name, + sizeof(temp_names[i])); } list_del(&dev->list); |
