From 1a5e4fd8c5b99478b4e08a69261930bb12aa948b Mon Sep 17 00:00:00 2001 From: Alex Converse Date: Tue, 3 May 2011 11:19:31 -0700 Subject: Replace strncpy() with av_strlcpy(). --- ffmpeg.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'ffmpeg.c') diff --git a/ffmpeg.c b/ffmpeg.c index d728f140f0..c5868110f2 100644 --- a/ffmpeg.c +++ b/ffmpeg.c @@ -3695,8 +3695,7 @@ static int opt_streamid(const char *opt, const char *arg) char *p; char idx_str[16]; - strncpy(idx_str, arg, sizeof(idx_str)); - idx_str[sizeof(idx_str)-1] = '\0'; + av_strlcpy(idx_str, arg, sizeof(idx_str)); p = strchr(idx_str, ':'); if (!p) { fprintf(stderr, -- cgit v1.2.3