Same as in patch patch-registry+source+registry.cxx
This part was just wrong. mkstemp does return a file descriptor, not a string. This could lead to crashes. MacOS will have the same problems.
This commit is contained in:
parent
98853485fa
commit
c163578692
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=78066
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
@ -0,0 +1,14 @@
|
||||
--- ../codemaker/source/codemaker/global.cxx.orig Fri Apr 4 00:14:50 2003
|
||||
+++ ../codemaker/source/codemaker/global.cxx Fri Apr 4 00:14:53 2003
|
||||
@@ -164,11 +164,7 @@
|
||||
strncat(tmpPattern, "/", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, pPrefix, sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
strncat(tmpPattern, "XXXXXX", sizeof(tmpPattern)-1-strlen(tmpPattern));
|
||||
-#if defined(FREEBSD) || defined(MACOSX)
|
||||
- pTmpName = mkstemp(tmpPattern);
|
||||
-#else
|
||||
pTmpName = mktemp(tmpPattern);
|
||||
-#endif
|
||||
#endif
|
||||
|
||||
return OString(pTmpName);
|
Loading…
Reference in New Issue
Block a user