Not to drag on the debate about the galaxy/forming star. I think the idea that it's a forming star is a pretty good explanation for it. But I thought I'd share this excerpt from the script by Lawrence Kasdan and Leigh Brackett:
Luke wriggles his fingers, makes a fist, and relaxes it. His hand is completely functional. He gets up and walks over to Leia. There is a new bond between them, a new understanding. Leia is thinking about Han; Luke is thinking about his uncertain and newly complicated future. Together they stand at the large window of the medical center looking out on the Rebel Star Cruiser and a dense, luminous galaxy swirling in space. Luke puts his arm around Leia. The droids stand next to them, and Threepio moves closer to Artoo putting his arm on him. The group watches as the Millennium Falcon moves into view, makes a turn, and zooms away into space.
EXTERIOR: SPACE -- REBEL STAR CRUISER
While Luke, Leia, and the droids stand, looking out the window of the star cruiser, two escort fighters join the large ship. Slowly, the cruiser turns and moves away into space.
DISSOLVE TO:
EXTERIOR: GALAXY -- SPACE
END CREDITS FADE IN AND OUT OVER BACKGROUND
THE END
The script was published in 1980 in a book titled The Empire Strikes Back Notebook and includes this storyboard with it:
I think the problem extends from the fact that originally the falcon was supposed to just shrink into the distance but ILM ended up changing it so it veers off screen.