fix memory leak: apparently we must close contexts to release JGit related resources
[teamcity/git-plugin.git] / git-server-tc / src / jetbrains / buildServer / buildTriggers / vcs / git / GitClonesUpdater.java
index 8eb464d5c606f85763ee129101774692eb8e1374..004cf68c6c9d11289a6e0cc7b1704a754d5e68e6 100644 (file)
@@ -98,6 +98,8 @@ public class GitClonesUpdater {
         });
       } catch (VcsException e1) {
         Loggers.VCS.warnAndDebugDetails("Could not update local clone for: " + LogUtil.describe(root), e1);
+      } finally {
+        context.close();
       }
     }
   }