Fix closing file descriptors on config updates

On config updates, statsd reads the config to verify if it has changed
at all from before. There is a bug in this code where we return the
success of reading before closing the file descriptor, which means the
fd never gets closed.

Test: manually pushed config updates and verified lsof -p $(pidof
statsd) showed no file descriptors of deleted files being held.
Bug: 176967529

Change-Id: Ifa66e2128cfff30298c65b6e0740ceefd26d66be
Merged-In: Ibb065d64be3775c699583215f7f376a1a5492ac1
1 file changed
tree: 8e1c740383981923b9b5d328bf6c78f402256067
  1. aidl/
  2. apex/
  3. bin/
  4. framework/
  5. lib/
  6. service/
  7. tests/
  8. .gitignore
  9. OWNERS