fix an error that choose a wrong protocol

Should use http when there ware no -S option.
Merge pull request #89 from Tobyee/master

fix an error that choose a wrong protocol