tor-dam

tor distributed announce mechanism (not a dht)
git clone https://git.parazyd.org/tor-dam
Log | Files | Refs | README | LICENSE

commit 4a23199db42dbac77d8b5fd443b053829bb97382
parent 7eca85f9f15beaa20754135aab516c595126ecb5
Author: parazyd <parazyd@dyne.org>
Date:   Thu,  7 Dec 2017 18:15:25 +0100

Use the new HTTPPost in dam.go

Diffstat:
Mgo/dam/dam.go | 6+-----
1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/go/dam/dam.go b/go/dam/dam.go @@ -3,11 +3,9 @@ package main // See LICENSE file for copyright and license details. import ( - "bytes" "encoding/base64" "encoding/json" "log" - "net/http" "os" "../lib" @@ -48,9 +46,7 @@ func main() { lib.CheckError(err) log.Println("Sending request") - resp, err := http.Post("http://localhost:8080/announce", "application/json", - bytes.NewBuffer(jsonVal)) - lib.CheckError(err) + resp := lib.HTTPPost("http://localhost:8080/announce", jsonVal) log.Println(resp) }