Polish MemoryIntArray

1. Add close guard
2. Adopt instead of clone the ahsmem fd to fix a dangling fd
3. Clear only the return flag when writing fd to parcel
4. Immediately destroy remote MemoryIntArray if stale
5. Throw Java exception if someone closed the fd under us

Change-Id: I85533fec336c40e3380e10d5448e18c9616ec341
4 files changed