Proof using.
intros.
unfold apply_log.
rewrite fold_left_app.
reflexivity.
Qed.
Definition disk_correct dsk h st  :=
exists s (entries : list entry) (snap : data),
dsk Count = Some (serialize (length entries)) /\
dsk Log = Some s /\
IOStreamWriter.unwrap s = IOStreamWriter.unwrap (list_serialize_rec entry _ entries) /\
dsk Snapshot = Some (serialize snap) /\
log_num_entries st = length entries /\
(apply_log h snap entries = log_data st).

(* Specifications: *)
Lemma log_net_handlers_spec :
forall dst src m st ops out st' l dsk dsk',
disk_correct dsk dst st ->
log_net_handlers snapshot_interval dst src m st = (ops, out, st', l) ->
apply_ops dsk ops = dsk' ->
disk_correct dsk' dst st'.