Prevent that an instance of PushCommand is reused

We checked if the command instance is called but missed to set the flag
tracking if it actually was used.

Change-Id: I0f9fb85c47945a4d91eab01ec5e1abc1ab83332a
This commit is contained in:
Thomas Wolf 2022-02-14 10:44:51 +01:00 committed by Matthias Sohn
parent db2d379c9c
commit c3fbd2cdf9
1 changed files with 1 additions and 0 deletions

View File

@ -98,6 +98,7 @@ public Iterable<PushResult> call() throws GitAPIException,
InvalidRemoteException,
org.eclipse.jgit.api.errors.TransportException {
checkCallable();
setCallable(false);
ArrayList<PushResult> pushResults = new ArrayList<>(3);