Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update for weekly 2011-09-01

  • Loading branch information...
commit fac53a2fbc37ccbd97542c0446171d68ea48eb2a 1 parent f197deb
@hoisie authored
Showing with 9 additions and 9 deletions.
  1. +1 −7 Readme.md
  2. +8 −2 request.go
View
8 Readme.md
@@ -14,13 +14,7 @@ web.go should be familiar to people who've developed websites with higher-level
## Installation
-Make sure you have the a working Go environment. See the [install instructions](http://golang.org/doc/install.html). web.go targets the Go `weekly` release. Go is a fast-changing language, and it's easier to keep with the weekly branch than to maintain separate branches.
-
-To use web.go with Go's `weekly` branch:
-
-1. Run `hg update -r weekly`. If you're running an outdated version of Go, or the `release` version, it likely won't compile.
-2. git clone git://github.com/hoisie/web.go.git
-3. cd web.go && make install
+Make sure you have the a working Go environment. See the [install instructions](http://golang.org/doc/install.html). web.go targets the Go `release` branch. There is also a `weekly` that corresponds to the Go weekly branch. Go is a fast-changing language, so it's possible that you will have to update your application if the libraries change.
You can also install using `goinstall github.com/hoisie/web.go`, but if you do this, the import statement in your go programs will be `import github.com/hoisie/web.go` instead of just `import web`.
View
10 request.go
@@ -195,7 +195,10 @@ func (r *Request) parseParams() (err os.Error) {
r.Params = map[string]string{}
json.Unmarshal(b, r.Params)
case "multipart/form-data":
- _, params := mime.ParseMediaType(ct)
+ _, params, err := mime.ParseMediaType(ct)
+ if err != nil {
+ return err
+ }
boundary, ok := params["boundary"]
if !ok {
return os.NewError("Missing Boundary")
@@ -221,7 +224,10 @@ func (r *Request) parseParams() (err os.Error) {
continue
}
name := part.FormName()
- d, params := mime.ParseMediaType(v)
+ d, params, err := mime.ParseMediaType(v)
+ if err != nil {
+ return err
+ }
if d != "form-data" {
continue
}
Please sign in to comment.
Something went wrong with that request. Please try again.