Refactor how zygote forked processes acquire gids

Effectively no-op refactoring in preparation to associate apps with
pass_through mount mode with the media_rw gid. Minor changes:

1. Before, if either UserHandle#get[Shared|Cache]AppGid return ERR
we would replace with the value of the already existing getUserGid
Now, we don't duplicate the getUserGid in the final result
2. Before, if the externalstorageapp also has the android_writable
mount mode (which would not happen), we would only give it the
media_rw gid. Now it can have both media_rw and sdcard_rw.

Test: m
Bug: 144914977
Change-Id: I7a4ea5cda59ffc573e41982c4051ee00abf95802
1 file changed