Commit 6cecd31f authored by Arlo Breault's avatar Arlo Breault
Browse files

Log to TOR_PT_STATE_LOCATION

parent ac9d49b8
...@@ -9,6 +9,7 @@ import ( ...@@ -9,6 +9,7 @@ import (
"net" "net"
"os" "os"
"os/signal" "os/signal"
"path"
"sync" "sync"
"syscall" "syscall"
"time" "time"
...@@ -121,7 +122,11 @@ func copyLoop(a, b io.ReadWriter) { ...@@ -121,7 +122,11 @@ func copyLoop(a, b io.ReadWriter) {
func main() { func main() {
webrtc.SetLoggingVerbosity(1) webrtc.SetLoggingVerbosity(1)
logFile, err := os.OpenFile("snowflake.log", stateDir, err := pt.MakeStateDir()
if err != nil {
log.Fatal(err)
}
logFile, err := os.OpenFile(path.Join(stateDir, "snowflake.log"),
os.O_CREATE|os.O_APPEND|os.O_WRONLY, 0600) os.O_CREATE|os.O_APPEND|os.O_WRONLY, 0600)
if err != nil { if err != nil {
log.Fatal(err) log.Fatal(err)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment