Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion apply.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,8 @@ func Apply(update io.Reader, opts Options) error {
if err != nil {
return err
}

//don't call fp.Sync().system power off ,file will lost
fp.Sync()
// if we don't call fp.Close(), windows won't let us move the new executable
// because the file will still be "in use"
fp.Close()
Expand Down