fixed wrong redirection code processing bug in rewriting handler. fixed a bug of not setting the default port when no port is specfied in rewritten url address