You are not checking return value of os.Remove in https://github.com/eikenb/pipeat/blob/master/pipeat.go#L51. That will fail on windows.
You can take look at https://github.com/calebcase/tmpfile, which works on Windows. + Egon On Friday, 3 January 2020 19:50:20 UTC+2, drakk...@gmail.com wrote: > > Hi, > > I'm going to use this library https://github.com/eikenb/pipeat/ > > it reads/writes from/to an unlinked temporary file, as you can see here: > > https://github.com/eikenb/pipeat/blob/master/pipeat.go#L51 > > the temporary file is removed and then used for I/O operations. > > I ran the test cases on Windows and they work there too. > > Is it really safe to assume that an unliked file will work on all > supported OS? I was really surprised that this work on Windows, > > Thanks! > -- 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/b85b3d8b-7b22-4b60-b22e-41bb36ded85c%40googlegroups.com.