fixes for httpjson changes.
Also update to use new errgo path.
gofmt
Merge pull request #23 from rogpeppe/025-update-for-jsonhttp-changes

fixes for httpjson changes.