Planning for the end of life is nobody's idea of a good time. But a little forethought can save your family some heartache.