Commit e98af919 authored by Andre Freyssinet's avatar Andre Freyssinet

Bug fix: JMQ-215, handling of CREATE after DELETE.

parent 042aacc6
......@@ -382,6 +382,11 @@ public final class NGTransaction extends AbstractTransaction implements NGTransa
else
op = Operation.alloc(Operation.SAVE, dirName, name, buf);
Operation old = (Operation) log.put(key, op);
// Bug fix: JMQ-215
if (first && (old != null) && (old.type == Operation.DELETE))
op.type = Operation.SAVE;
if (copy) {
if ((old != null) &&
(old.type == Operation.SAVE) &&
......
......@@ -364,6 +364,11 @@ public abstract class DBTransaction extends AbstractTransaction implements DBTra
else
op = DBOperation.alloc(Operation.SAVE, fname, buf);
DBOperation old = (DBOperation) log.put(fname, op);
// Bug fix: JMQ-215
if (first && (old != null) && (old.type == Operation.DELETE))
op.type = Operation.SAVE;
if (copy) {
if ((old != null) &&
(old.type == DBOperation.SAVE) &&
......
......@@ -490,6 +490,11 @@ public final class NTransaction extends AbstractTransaction implements NTransact
else
op = Operation.alloc(Operation.SAVE, dirName, name, buf);
Operation old = (Operation) log.put(key, op);
// Bug fix: JMQ-215
if (first && (old != null) && (old.type == Operation.DELETE))
op.type = Operation.SAVE;
if (copy) {
if ((old != null) &&
(old.type == Operation.SAVE) &&
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment