can auto grow 00 and 01 replication volumes

This commit is contained in:
Chris Lu
2012-09-16 17:31:15 -07:00
parent e7c4ee1c64
commit 9b99240584
18 changed files with 364 additions and 188 deletions

View File

@@ -7,17 +7,17 @@ import (
"net/url"
)
func Post(url string, values url.Values) []byte {
func Post(url string, values url.Values) ([]byte, error) {
r, err := http.PostForm(url, values)
if err != nil {
log.Println("post:", err)
return nil
return nil, err
}
defer r.Body.Close()
b, err := ioutil.ReadAll(r.Body)
if err != nil {
log.Println("post:", err)
return nil
return nil, err
}
return b
return b, nil
}