apply for pull request
This commit is contained in:
@@ -33,9 +33,10 @@ Options:
|
||||
-T Content-type, defaults to "text/html".
|
||||
-a Basic authentication, username:password.
|
||||
|
||||
-allow-insecure Allow bad/expired TLS/SSL certificates.
|
||||
-allow-insecure Allow bad/expired TLS/SSL certificates.
|
||||
-disable-compression Disable compression
|
||||
-disable-keepalive Disable keep-alive, prevents re-use of TCP connections between different HTTP requests
|
||||
|
||||
-cpus Number of used cpu cores (default for current machine is %d cores)
|
||||
~~~
|
||||
|
||||
|
||||
14
boom.go
14
boom.go
@@ -22,8 +22,8 @@ import (
|
||||
gourl "net/url"
|
||||
"os"
|
||||
"regexp"
|
||||
"strings"
|
||||
"runtime"
|
||||
"strings"
|
||||
|
||||
"github.com/miolini/boom/boomer"
|
||||
)
|
||||
@@ -38,11 +38,11 @@ var (
|
||||
flagOutput = flag.String("o", "", "")
|
||||
flagProxyAddr = flag.String("x", "", "")
|
||||
|
||||
flagC = flag.Int("c", 50, "")
|
||||
flagN = flag.Int("n", 200, "")
|
||||
flagQ = flag.Int("q", 0, "")
|
||||
flagT = flag.Int("t", 0, "")
|
||||
flagCpus = flag.Int("cpus", runtime.NumCPU(), "")
|
||||
flagC = flag.Int("c", 50, "")
|
||||
flagN = flag.Int("n", 200, "")
|
||||
flagQ = flag.Int("q", 0, "")
|
||||
flagT = flag.Int("t", 0, "")
|
||||
flagCpus = flag.Int("cpus", runtime.GOMAXPROCS(-1), "")
|
||||
|
||||
flagInsecure = flag.Bool("allow-insecure", false, "")
|
||||
flagDisableCompression = flag.Bool("disable-compression", false, "")
|
||||
@@ -93,7 +93,7 @@ func (*netDnsResolver) Lookup(domain string) (addr []string, err error) {
|
||||
|
||||
func main() {
|
||||
flag.Usage = func() {
|
||||
fmt.Fprintf(os.Stderr, usage, runtime.NumCPU())
|
||||
fmt.Fprintf(os.Stderr, usage, runtime.GOMAXPROCS(-1))
|
||||
}
|
||||
|
||||
flag.Parse()
|
||||
|
||||
@@ -70,7 +70,7 @@ type Boomer struct {
|
||||
// Option to allow insecure TLS/SSL certificates.
|
||||
AllowInsecure bool
|
||||
|
||||
// Option to disable decompress response
|
||||
// Option to disable compression in response
|
||||
DisableCompression bool
|
||||
|
||||
// Option to prevents re-use of TCP connections between different HTTP requests
|
||||
|
||||
Reference in New Issue
Block a user