Carl Jackson 11 years ago
parent
commit
28b9206791
2 changed files with 2 additions and 4 deletions
  1. +1
    -2
      web/cpool.go
  2. +1
    -2
      web/router.go

+ 1
- 2
web/cpool.go View File

@ -14,9 +14,8 @@ func (c *cPool) alloc() *cStack {
cs := (*sync.Pool)(c).Get()
if cs == nil {
return nil
} else {
return cs.(*cStack)
}
return cs.(*cStack)
}
func (c *cPool) release(cs *cStack) {


+ 1
- 2
web/router.go View File

@ -209,9 +209,8 @@ func (rm routeMachine) route(c *C, w http.ResponseWriter, r *http.Request) (meth
if matchRoute(rm.routes[si], m, &methods, r, c) {
rm.routes[si].handler.ServeHTTPC(*c, w, r)
return 0, true
} else {
i++
}
i++
} else if (match && sm&smJumpOnMatch != 0) ||
(!match && sm&smJumpOnMatch == 0) {


Loading…
Cancel
Save