Skip to content

Commit db0c289

Browse files
committed
Merge branch 'master' of git@github.com:hoisie/web.go
2 parents 2f7d97d + e35baf0 commit db0c289

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

Readme.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ You can point your browser to http://localhost:9999/world .
4343

4444
More documentation, including a tutorial and API docs, is available on [web.go's home page](http://www.getwebgo.com)
4545

46+
If you use web.go, I'd greatly appreciate a quick message about what you're building with it. This will help me get a sense of usage patterns, and helps me focus development effors on features that people will actually use.
47+
4648
## About
4749

4850
web.go was written by [Michael Hoisie](http://hoisie.com).

web.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ import (
1414
"time"
1515
)
1616

17+
var rgen = rand.New( rand.NewSource( time.Nanoseconds() ) )
18+
1719
type Conn interface {
1820
StartResponse(status int)
1921
SetHeader(hdr string, val string, unique bool)
@@ -64,7 +66,7 @@ func randomString(length int) string {
6466
var res bytes.Buffer
6567

6668
for i := 0; i < length; i++ {
67-
rnd := rand.Intn(len(pop))
69+
rnd := rgen.Intn(len(pop))
6870
res.WriteByte(pop[rnd])
6971
}
7072

0 commit comments

Comments
 (0)