Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2a0ad308 authored by Android (Google) Code Review's avatar Android (Google) Code Review
Browse files

Merge change 23168 into eclair

* changes:
  EventHub: Fix file descriptor leak.
parents f0baeefc 07549f98
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -784,6 +784,7 @@ int EventHub::close_device(const char *deviceName)
            int count = mFDCount - i - 1;
            int index = (device->id&ID_MASK);
            mDevicesById[index].device = NULL;
            close(mFDs[i].fd);
            memmove(mDevices + i, mDevices + i + 1, sizeof(mDevices[0]) * count);
            memmove(mFDs + i, mFDs + i + 1, sizeof(mFDs[0]) * count);