Skip to content

Commit

Permalink
Formatting and updating of docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Arnoud Vermeer committed Feb 28, 2019
1 parent b56dc83 commit 4f56a3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
A TFTP server that proxies request to an HTTP backend if a file is not found.

# How to build
go build tftp.go
go build main.go

# How to run
./tftp -url=http://example.com -dir=/var/lib/tftpboot &
6 changes: 3 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ import (
"flag"
"fmt"
"io"
"io/ioutil"
"net/http"
"os"
"path"
"time"
"path"
"io/ioutil"

"github.com/pin/tftp"
)
Expand Down Expand Up @@ -50,7 +50,7 @@ func readHandler(filename string, rf io.ReaderFrom) error {
defer resp.Body.Close()

if resp.StatusCode != 200 {
io.Copy(ioutil.Discard, resp.Body)
io.Copy(ioutil.Discard, resp.Body)
return fmt.Errorf("Received status code: %d", resp.StatusCode)
}

Expand Down

0 comments on commit 4f56a3c

Please sign in to comment.