From bb40ef98fd570105354eea87f150472d205a82d0 Mon Sep 17 00:00:00 2001 From: "Nikolay.Rykunov" Date: Tue, 19 Mar 2019 19:33:41 +0300 Subject: [PATCH] [git] readFullDetailsForHashes should do nothing if empty list of hashes is received If we don't do this check, git provide full history, or error if repository has no commits --- plugins/git4idea/src/git4idea/history/GitLogUtil.java | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/git4idea/src/git4idea/history/GitLogUtil.java b/plugins/git4idea/src/git4idea/history/GitLogUtil.java index 2f5671cf1c54..82619dd8aa6b 100644 --- a/plugins/git4idea/src/git4idea/history/GitLogUtil.java +++ b/plugins/git4idea/src/git4idea/history/GitLogUtil.java @@ -373,6 +373,7 @@ public class GitLogUtil { boolean withFullMergeDiff, boolean preserveOrder, @NotNull DiffRenameLimit renameLimit) throws VcsException { + if (hashes.isEmpty()) return; GitLineHandler handler = createGitHandler(project, root, createConfigParameters(includeRootChanges, renameLimit), lowPriorityProcess); sendHashesToStdin(vcs, hashes, handler);