more vfs logging for p4 tests

This commit is contained in:
peter
2015-09-01 10:32:26 +02:00
parent dcf77d0df1
commit f2dd324d9e
2 changed files with 6 additions and 1 deletions
@@ -17,6 +17,7 @@ package com.intellij.openapi.vfs.newvfs.impl;
import com.intellij.openapi.application.ApplicationAdapter;
import com.intellij.openapi.application.ApplicationManager;
import com.intellij.openapi.diagnostic.Logger;
import com.intellij.openapi.vfs.InvalidVirtualFileAccessException;
import com.intellij.openapi.vfs.newvfs.persistent.FSRecords;
import com.intellij.util.ArrayUtil;
@@ -73,6 +74,7 @@ import static com.intellij.util.ObjectUtils.assertNotNull;
* @author peter
*/
public class VfsData {
private static final Logger LOG = Logger.getInstance("#com.intellij.openapi.vfs.newvfs.impl.VfsData");
private static final int SEGMENT_BITS = 9;
private static final int SEGMENT_SIZE = 1 << SEGMENT_BITS;
private static final int OFFSET_MASK = SEGMENT_SIZE - 1;
@@ -223,6 +225,9 @@ public class VfsData {
}
void setFlag(int id, int mask, boolean value) {
if (LOG.isDebugEnabled()) {
LOG.debug("Set flag " + Integer.toHexString(mask) + "=" + value + " for id=" + id);
}
assert (mask & ~ALL_FLAGS_MASK) == 0 : "Unexpected flag";
int offset = getOffset(id) * 2 + 1;
while (true) {
@@ -1061,7 +1061,7 @@ public class PersistentFSImpl extends PersistentFS implements ApplicationCompone
else if (VirtualFile.PROP_WRITABLE.equals(propertyChangeEvent.getPropertyName())) {
executeSetWritable(file, ((Boolean)newValue).booleanValue());
if (LOG.isDebugEnabled()) {
LOG.debug("File " + file + " writable=" + file.isWritable());
LOG.debug("File " + file + " writable=" + file.isWritable() + " id=" + getFileId(file));
}
}
else if (VirtualFile.PROP_HIDDEN.equals(propertyChangeEvent.getPropertyName())) {