Make Dialyzer happy

These changes lead to no errors/warning in Dialyzer output except some related to unused functions in `mock_http_server`. I guess these functions might be used someday, so didn't remove them.

Especially https://github.com/lavrin/wsecli/commit/b4603f5f74d44c48726dc875bc7b1019fda2c102 is important, because it (temporarily, I guess) fixes the problem I reported in https://github.com/madtrick/wsecli/issues/15.

My master branch contains a Makefile with Dialyzer setup I used.