Changed decoder chain pointer type.

Changed from unique_ptr to shared_ptr, since this is turning into a
small graph.