Skip to content

Commit

Permalink
Forced UTC to avoid trouble when changing timezone (CET vs CEST)
Browse files Browse the repository at this point in the history
  • Loading branch information
SimoneLazzaris committed Oct 30, 2017
1 parent 241e707 commit e3b4f03
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions polka.go
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ func handleRequest(conn net.Conn, db *sql.DB) {
}
}
db.Ping()
db.Exec("set time_zone='+00:00'") // timezone UTC
db.Exec("set session TRANSACTION ISOLATION LEVEL REPEATABLE READ")
resp:=policy_verify(xdata, db)
conn.Write([]byte(fmt.Sprintf("action=%s\n\n",resp)))
Expand Down

0 comments on commit e3b4f03

Please sign in to comment.