From f99744f35d85bd0e42171143e84c8717c7675d53 Mon Sep 17 00:00:00 2001 From: Kirill Likhodedov Date: Mon, 26 Dec 2016 19:01:44 +0300 Subject: [PATCH] git: remove unneeded volatiles Message start marker, message end marker, the files are all received from the same thread (either stdout or stderr) => although the listener is listening to different threads, in fact only one thread is important during the command execution. Follow-up to 712a158 --- .../src/git4idea/commands/GitMessageWithFilesDetector.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/git4idea/src/git4idea/commands/GitMessageWithFilesDetector.java b/plugins/git4idea/src/git4idea/commands/GitMessageWithFilesDetector.java index 15dc16210dfe..00bb30663e85 100644 --- a/plugins/git4idea/src/git4idea/commands/GitMessageWithFilesDetector.java +++ b/plugins/git4idea/src/git4idea/commands/GitMessageWithFilesDetector.java @@ -42,8 +42,8 @@ public class GitMessageWithFilesDetector implements GitLineHandlerListener { @NotNull private final VirtualFile myRoot; @NotNull protected final Set myAffectedFiles = new HashSet<>(); - protected volatile boolean myMessageDetected; - @Nullable private volatile Key myMessageOutputType; + protected boolean myMessageDetected; + @Nullable private Key myMessageOutputType; public GitMessageWithFilesDetector(@NotNull Event event, @NotNull VirtualFile root) { myEvent = event;