Skip to content

Commit f8c1dd1

Browse files
committed
check holder is None on acquire
1 parent 862922b commit f8c1dd1

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

LockServ.v

+5-2
Original file line numberDiff line numberDiff line change
@@ -873,7 +873,10 @@ Section LockServ.
873873
| _ => trace_mutual_exclusion' holder tr'
874874
end
875875
| (n, (inl _)) :: tr' => trace_mutual_exclusion' holder tr'
876-
| (Client n, (inr [Locked])) :: tr' => trace_mutual_exclusion' (Some n) tr'
876+
| (Client n, (inr [Locked])) :: tr' => match holder with
877+
| None => trace_mutual_exclusion' (Some n) tr'
878+
| Some _ => False
879+
end
877880
| (_, (inr [])) :: tr' => trace_mutual_exclusion' holder tr'
878881
| (_, (inr _)) :: tr' => False
879882
end.
@@ -951,7 +954,7 @@ Section LockServ.
951954
trace_mutual_exclusion' h (tr ++ [(Client n, inr [Locked])]).
952955
Proof.
953956
induction tr; intros; simpl in *.
954-
- auto.
957+
- subst. auto.
955958
- simpl in *. repeat break_match; subst; intuition.
956959
Qed.
957960

0 commit comments

Comments
 (0)