Write only a single file for updates - fixes reboot loop issues.

Files with spaces and special characters were causing reboot loops.
pull/472/merge
Christopher Young 2016-08-24 10:25:27 -04:00
rodzic 84e3497da5
commit 0177402f00
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -311,7 +311,7 @@ func handleUpdatePostRequest(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(404)
return
}
updateFile := fmt.Sprintf("/root/%s", handler.Filename)
updateFile := fmt.Sprintf("/root/update-stratux-v.sh")
f, err := os.OpenFile(updateFile, os.O_WRONLY|os.O_CREATE, 0666)
if err != nil {
log.Printf("Update failed from %s (%s).\n", r.RemoteAddr, err.Error())