This is a discussion on Re: pg_dump -Ft failed on Windows XP within the pgsql Hackers forums, part of the PostgreSQL category; --> > > I have repeated the problem with CVS head on XP SP2. It > *does* create > > ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| > > I have repeated the problem with CVS head on XP SP2. It > *does* create > > it there (or rather, it tries to). > > > tmpnam() returns a file in the current dir per documentation, but I > > see it generating one in the root instead. > > tempnam() uses TMP environment variable. > > > tmpfile() and tmpnam() both use the same function to generate the > > filename. > > Hm. I guess I concur with Peter's conclusion: the cleanest > fix is to put our own implementation of tmpfile() into src/port/. Ok. Should be easy enough once the code is fine - can you comment on the patch as sent, if the code itself looks right provided i wrap it up in a function in port/? //Magnus ---------------------------(end of broadcast)--------------------------- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq |
| ||||
| "Magnus Hagander" <mha@sollentuna.net> writes: > Ok. Should be easy enough once the code is fine - can you comment on the > patch as sent, if the code itself looks right provided i wrap it up in a > function in port/? Not sure if the error handling is adequate --- are there any cases besides EEXIST that should loop? A look at http://msdn.microsoft.com/library/de..._wtmpna m.asp suggests that tempnam() is also pretty fragile, esp. if you're passing NULLs. Apparently it won't work at all if TMP isn't set? regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 2: Don't 'kill -9' the postmaster |