Close repository in ref-updated listener

onGitReferenceUpdated() created two MetaDataUpdate instances per
refs/meta/config update and never closed them, leaking the underlying
Repository reference on every project config change. Found by the
repository-leak tracking of the acceptance test framework when the
first test for this plugin was added.

Use a single MetaDataUpdate in try-with-resources for both the old
and the new revision read.

Change-Id: I6d3a91e04c85f2b7a1c9e8f5063d2b74915ac0e8
1 file changed
tree: 0e454398bb9c6ee67f794cadc8e3b45f6dbd1316
  1. .settings/
  2. src/
  3. .gitignore
  4. BUILD
  5. LICENSE