openbsd-ports/plan9/wily/patches/patch-aa
brad 4bc0731f85 - upgrade to wily 0.13.41
- remove GNU_CONFIGURE and add USE_AUTOCONF
- use SEPARATE_BUILD
1999-05-11 21:21:59 +00:00

18 lines
405 B
Plaintext

--- wily/text2.c.orig Tue May 11 13:43:17 1999
+++ wily/text2.c Tue May 11 13:44:20 1999
@@ -136,11 +136,12 @@
int
text_fd(Text *t, Range sel)
{
- char *file = tmpnam(0);
+ char file[40];
int fd;
int input;
- if ((fd = open(file, O_WRONLY|O_CREAT, 0600)) < 0) {
+ sprintf(file, "ff.XXXXXXXX");
+ if ((fd = mkstemp(file)) < 0) {
perror("open temp file");
(void) unlink(file);
return(-1);