fix valgrind ioctl warning.
Initialize local variable to avoid syscall ioctl warning. Change-Id: Ibad5b86cd799f147c71f182d654e61318e2ac15e Origin-Change-Id: Iedf5b128ae1743f633d2821ac3e402942ad6642b Signed-off-by: Jin Wei <wei.a.jin@intel.com> Signed-off-by: Jian Luo <jian.luo@intel.com> Signed-off-by: Bruce Beare <bruce.j.beare@intel.com> Signed-off-by: Jack Ren <jack.ren@intel.com> Author-tracking-BZ: 62797
This commit is contained in:
parent
db71324a4f
commit
b815701247
|
@ -48,7 +48,7 @@ int ashmem_create_region(const char *name, size_t size)
|
|||
return fd;
|
||||
|
||||
if (name) {
|
||||
char buf[ASHMEM_NAME_LEN];
|
||||
char buf[ASHMEM_NAME_LEN] = {0};
|
||||
|
||||
strlcpy(buf, name, sizeof(buf));
|
||||
ret = ioctl(fd, ASHMEM_SET_NAME, buf);
|
||||
|
|
Loading…
Reference in New Issue