This repository has been archived on 2026-01-16. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.
zoo/zoo-2.10-tempfile.patch
cvsextras ccb8476a5b auto-import changelog data from zoo-2.10-0.fdr.2.rh90.src.rpm
2.10-0.fdr.2
Use debian source
2.10-0.fdr.1
Fedorization
Sat Dec 06 2003 Dag Wieers <dag@wieers.com> - 2.10-1
- Patch to build on RHFC1.
Sun Jan 26 2003 Dag Wieers <dag@wieers.com> - 2.10-0
- Initial package. (using DAR)
2004-11-08 05:36:41 +00:00

24 lines
565 B
Diff

--- zoo/zoopack.c.tempfile Thu Jul 11 21:08:04 1991
+++ zoo/zoopack.c Fri Jan 18 13:34:56 2002
@@ -171,8 +171,19 @@
} else {
strcpy (temp_file, xes);
}
-mktemp (temp_file); /* ... and make unique */
-new_file = zoocreate (temp_file);
+
+/* make unique name */
+/* my god, this coding style sucks */
+new_file = NOFILE;
+{
+ int fd;
+
+ if ((fd = mkstemp(temp_file)) >= 0) {
+ new_file = zoocreate (temp_file);
+ close(fd);
+ }
+}
+
if (new_file == NOFILE)
prterror ('f', "Could not create temporary file %s.\n", temp_file);