ANDROID: binder: remove extra declaration left after backport

When backporting commit 1a7c3d9bb7a9 ("binder: create
userspace-to-binder-buffer copy function"), an extra "int target_fd;"
was left in the code. This resulted in the possibility of accessing
an uninitialized variable which was flagged by gcc.

Bug: 67668716
Change-Id: I787ed89579e9d40e8530d79be67cc663ec755e54
Signed-off-by: Todd Kjos <tkjos@google.com>
This commit is contained in:
Todd Kjos 2019-03-27 16:12:31 -07:00
parent c1a289854b
commit e7d41267ad

View file

@ -2781,7 +2781,7 @@ static int binder_translate_fd_array(struct binder_fd_array_object *fda,
}
for (fdi = 0; fdi < fda->num_fds; fdi++) {
u32 fd;
int target_fd;
binder_size_t offset = fda_offset + fdi * sizeof(fd);
binder_alloc_copy_from_buffer(&target_proc->alloc,