diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/core/wheelinfo.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lib/core/wheelinfo.c b/src/lib/core/wheelinfo.c index 76f2d92..fe426aa 100644 --- a/src/lib/core/wheelinfo.c +++ b/src/lib/core/wheelinfo.c @@ -21,8 +21,7 @@ struct WheelInfo *wheelinfo_get(const char *basepath, const char *name, char *to } char filename[NAME_MAX]; - strncpy(filename, rec->d_name, sizeof(filename) - 1); - filename[sizeof(filename) - 1] = '\0'; + safe_strncpy(filename, rec->d_name, sizeof(filename)); char *ext = strstr(filename, ".whl"); if (ext) { |
