Section Decomposition.
Context `{d : Decomposition}.
(* Fixpoint remove_one {A : Type} (A_eq_dec : forall x y : A, {x = y} + {x <> y}) a l := match l with | x :: xs => if A_eq_dec a x then xs else x :: remove_one A_eq_dec a xs | [] => [] end. *)
Definition packet_eq_dec :
forall p1 p2 : packet,
{p1 = p2} + {p1 <> p2}.

Lemma post_input_analyze_sent_packet :
forall h p ms l,
In p (map (fun m => mkPacket h (fst m) (snd m)) ms ++ l) ->
(In (pDst p, pBody p) ms /\ h = pSrc p) \/ In p l.