Skip to content

Commit

Permalink
ProjectPreferences: mt hardening
Browse files Browse the repository at this point in the history
volatile members
  • Loading branch information
jukzi committed Jan 24, 2025
1 parent dba97fe commit 2c956b3
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,24 +75,24 @@ public class ProjectPreferences extends EclipsePreferences {
*/
private static final Set<String> loadedNodes = ConcurrentHashMap.newKeySet();
private IFile file;
private boolean initialized = false;
private volatile boolean initialized;
/**
* Flag indicating that this node is currently reading values from disk,
* to avoid flushing during a read.
*/
private boolean isReading;
private volatile boolean isReading;
/**
* Flag indicating that this node is currently writing values to disk,
* to avoid re-reading after the write completes.
*/
private boolean isWriting;
private volatile boolean isWriting;
private IEclipsePreferences loadLevel;
private final IProject project;
private final String qualifier;

// cache
private final int segmentCount;
private Workspace workspace;
private volatile Workspace workspace;

static void deleted(IFile file) throws CoreException {
IPath path = file.getFullPath();
Expand Down

0 comments on commit 2c956b3

Please sign in to comment.