Okay first it's not a good idea and not necessary to kill the dragon unless you're evil. You can just keep asking the demon why the dragon needs killing and it will admit you can just ask for the tear from the dragon. Did you pick up what the dragon had when you killed him, i.e. do you have the tear? If you try to leave without the tear it may not let you. If you do have the tear and still can't leave then I think it may be a bug.
------------------
Goddess and Sorceress of the HADB, and her sidekick Pink