Merge branch 'thinxer-master'

This commit is contained in:
John Beisley 2015-03-07 08:50:21 +00:00
commit 2ed6e64917

View File

@ -20,6 +20,8 @@ import (
"net/http" "net/http"
"net/url" "net/url"
"golang.org/x/net/html/charset"
"github.com/huin/goupnp/httpu" "github.com/huin/goupnp/httpu"
"github.com/huin/goupnp/ssdp" "github.com/huin/goupnp/ssdp"
) )
@ -104,6 +106,7 @@ func requestXml(url string, defaultSpace string, doc interface{}) error {
decoder := xml.NewDecoder(resp.Body) decoder := xml.NewDecoder(resp.Body)
decoder.DefaultSpace = defaultSpace decoder.DefaultSpace = defaultSpace
decoder.CharsetReader = charset.NewReaderByName
return decoder.Decode(doc) return decoder.Decode(doc)
} }