diff options
author | Matt Keller <matthew.keller@spatialkey.com> | 2014-11-17 07:26:27 -0800 |
---|---|---|
committer | Matt Keller <matthew.keller@spatialkey.com> | 2014-11-17 07:26:27 -0800 |
commit | 468f1c37fcfc54d71d3902ecb172124aa5a206a3 (patch) | |
tree | 988654ef15616fc6e6e468ff59ca516e89bc4eea /ssllabs-scan.go | |
parent | 189e8ea12969616a54bf755fcc657779878fb0e9 (diff) | |
download | ssllabs-scan-468f1c37fcfc54d71d3902ecb172124aa5a206a3.zip ssllabs-scan-468f1c37fcfc54d71d3902ecb172124aa5a206a3.tar.gz ssllabs-scan-468f1c37fcfc54d71d3902ecb172124aa5a206a3.tar.bz2 |
This fixes ssllabs/ssllabs-scan#21 and pre-emptively fixes the next
error the user would have reported, as the result would not have been a
valid JSON array.
Diffstat (limited to 'ssllabs-scan.go')
-rw-r--r-- | ssllabs-scan.go | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/ssllabs-scan.go b/ssllabs-scan.go index 66ef586..b4fc9e4 100644 --- a/ssllabs-scan.go +++ b/ssllabs-scan.go @@ -816,7 +816,17 @@ func main() { } else if *conf_rawoutput { // Raw (non-Go-mangled) JSON output - fmt.Println(manager.results.responses) + + fmt.Println("[") + for i := range manager.results.responses { + results := manager.results.responses[i] + + if i>0 { + fmt.Println(",") + } + fmt.Println(results) + } + fmt.Println("]") } else { // Regular JSON output results, err = json.Marshal(manager.results.reports) |