summaryrefslogtreecommitdiff
path: root/converters/mpack/patches/patch-ab
diff options
context:
space:
mode:
Diffstat (limited to 'converters/mpack/patches/patch-ab')
-rw-r--r--converters/mpack/patches/patch-ab28
1 files changed, 21 insertions, 7 deletions
diff --git a/converters/mpack/patches/patch-ab b/converters/mpack/patches/patch-ab
index 7ad142f7d07..f535bb9f339 100644
--- a/converters/mpack/patches/patch-ab
+++ b/converters/mpack/patches/patch-ab
@@ -1,8 +1,8 @@
-$NetBSD: patch-ab,v 1.6 2005/12/19 00:13:39 joerg Exp $
+$NetBSD: patch-ab,v 1.7 2009/02/15 20:12:18 dholland Exp $
---- unixos.c.orig 1995-02-16 21:39:50.000000000 +0000
-+++ unixos.c
-@@ -23,6 +23,7 @@
+--- unixos.c.orig 2003-07-21 16:54:05.000000000 -0400
++++ unixos.c 2009-02-15 14:56:48.000000000 -0500
+@@ -23,9 +23,11 @@
* SOFTWARE.
*/
#include <stdio.h>
@@ -10,7 +10,11 @@ $NetBSD: patch-ab,v 1.6 2005/12/19 00:13:39 joerg Exp $
#include <ctype.h>
#include <string.h>
#include <errno.h>
-@@ -36,10 +37,6 @@
++#include <time.h>
+ #include <sys/types.h>
+ #include <sys/param.h>
+ #include <netdb.h>
+@@ -38,10 +40,6 @@
#define MAXHOSTNAMELEN 64
#endif
@@ -21,14 +25,24 @@ $NetBSD: patch-ab,v 1.6 2005/12/19 00:13:39 joerg Exp $
int overwrite_files = 0;
int didchat;
-@@ -89,7 +86,11 @@ char *id;
+@@ -76,7 +74,7 @@ char *os_genid(void)
+ }
+
+ result = malloc(25+strlen(hostname));
+- sprintf(result, "%d.%d@%s", pid, curtime++, hostname);
++ sprintf(result, "%d.%lld@%s", pid, (long long) curtime++, hostname);
+ return result;
+ }
+
+@@ -90,7 +88,11 @@ char *os_idtodir(char *id)
strcpy(buf, getenv("TMPDIR"));
}
else {
+- strcpy(buf, "/usr/tmp");
+#if defined(P_tmpdir)
+ strcpy(buf, P_tmpdir);
+#else
- strcpy(buf, "/usr/tmp");
++ strcpy(buf, "/var/tmp");
+#endif
}
strcat(buf, "/m-prts-");