diff --git a/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgPullAction.java b/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgPullAction.java index 11fa9d5ffc32..dda78c112676 100644 --- a/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgPullAction.java +++ b/plugins/hg4idea/src/org/zmlx/hg4idea/action/HgPullAction.java @@ -46,7 +46,7 @@ public class HgPullAction extends HgAbstractGlobalSingleRepoAction { private static void executePull(final Project project, final HgRepository hgRepository, final String source) { final HgPullCommand command = new HgPullCommand(project, hgRepository.getRoot()); command.setSource(source); - command.execute(); + command.executeInCurrentThread(); hgRepository.update(); } } diff --git a/plugins/hg4idea/src/org/zmlx/hg4idea/command/HgPullCommand.java b/plugins/hg4idea/src/org/zmlx/hg4idea/command/HgPullCommand.java index 9d3962c7d7c5..6df96dcbd324 100644 --- a/plugins/hg4idea/src/org/zmlx/hg4idea/command/HgPullCommand.java +++ b/plugins/hg4idea/src/org/zmlx/hg4idea/command/HgPullCommand.java @@ -58,7 +58,7 @@ public class HgPullCommand { this.source = source; } - public HgCommandExitCode execute() { + public HgCommandExitCode executeInCurrentThread() { List arguments = new LinkedList(); if (update) { arguments.add("--update"); diff --git a/plugins/hg4idea/src/org/zmlx/hg4idea/provider/update/HgRegularUpdater.java b/plugins/hg4idea/src/org/zmlx/hg4idea/provider/update/HgRegularUpdater.java index faa1fa0f0ebe..48fea381d869 100644 --- a/plugins/hg4idea/src/org/zmlx/hg4idea/provider/update/HgRegularUpdater.java +++ b/plugins/hg4idea/src/org/zmlx/hg4idea/provider/update/HgRegularUpdater.java @@ -265,7 +265,7 @@ public class HgRegularUpdater implements HgUpdater { HgPullCommand hgPullCommand = new HgPullCommand(project, repo); final String defaultPath = HgUtil.getRepositoryDefaultPath(project, repo); hgPullCommand.setSource(defaultPath); - return hgPullCommand.execute(); + return hgPullCommand.executeInCurrentThread(); } private void update(@NotNull VirtualFile repo, ProgressIndicator indicator, UpdatedFiles updatedFiles, List warnings) throws VcsException { diff --git a/plugins/hg4idea/testSrc/org/zmlx/hg4idea/test/HgUpdateTest.java b/plugins/hg4idea/testSrc/org/zmlx/hg4idea/test/HgUpdateTest.java index 6a8b50bbc3c8..52d176dc1d9a 100644 --- a/plugins/hg4idea/testSrc/org/zmlx/hg4idea/test/HgUpdateTest.java +++ b/plugins/hg4idea/testSrc/org/zmlx/hg4idea/test/HgUpdateTest.java @@ -62,7 +62,7 @@ public class HgUpdateTest extends HgCollaborativeTest { //do a simple pull without an update HgPullCommand pull = new HgPullCommand(myProject, projectRepoVirtualFile); pull.setSource(HgUtil.getRepositoryDefaultPath(myProject, projectRepoVirtualFile)); - pull.execute(); + pull.executeInCurrentThread(); assertEquals( determineNumberOfIncomingChanges( projectRepo ), 0, "The update operation should have pulled the incoming changes from the default repository." );