From: Yu Watanabe Date: Wed, 8 Aug 2018 06:52:46 +0000 (+0900) Subject: core: use memcpy_safe() X-Git-Tag: v240~846^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7e8d494b33cf593e332f3c710c9c26aee4b88dd9;p=platform%2Fupstream%2Fsystemd.git core: use memcpy_safe() Fixes #9738. --- diff --git a/src/core/execute.c b/src/core/execute.c index a35dbac..ecf0f7c 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -3216,7 +3216,7 @@ static int exec_child( } fds_with_exec_fd = newa(int, n_fds + 1); - memcpy(fds_with_exec_fd, fds, n_fds * sizeof(int)); + memcpy_safe(fds_with_exec_fd, fds, n_fds * sizeof(int)); fds_with_exec_fd[n_fds] = exec_fd; n_fds_with_exec_fd = n_fds + 1; } else {