Microsoft recommends changing this, so we need to know whether existing
apps rely on it:

On Windows (but not elsewhere) this fails with a "sharing violation":

path := "rename-after-open"
fd, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE, 0600)
if err != nil { ... }
err = os.Rename(path_a, path_b)            // or os.Remove(path)
if err != nil { ... }                      // sharing violation
fd.Close()


Do you know of Windows apps that expect this error, which is undocumented
in package "os" ?

Microsoft has suggested that Go on Windows should switch to Unix-like
behavior:
https://github.com/golang/go/issues/32088

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CAKvHMgSWehzEATg5L_w6mCngnm1q1LkVyQ8PpE1T1R9%3D5QQ-gw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to