Chewbacca was smashed by a moon because of a weird autistic spasm that Lucas had when the book was being written.
Han died to advance a critical character arc that's supposed to span another two films.
I don't really "like" either, but the latter is certainly more tasteful.