-
chapters.cpp: `delete` is a NOOP if the operand is NULL, if-check removed. chapters.{hpp,cpp}: introduced helper for `chapter_item_c::{Enter,Leave}` since they are extremely similar in their implementation. The helper makes use of <algorithm> and <functional> to make the code more error-proof, as a plus it is a little bit cleaner. Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
12a207b8