summaryrefslogtreecommitdiff
path: root/mbone/imm/patches/patch-ae
blob: 4018261904bc9604dd9869954840d034fbca3913 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
--- utils.c.orig	2003-10-08 16:18:08.000000000 +1000
+++ utils.c	2003-10-08 16:18:18.000000000 +1000
@@ -20,7 +20,7 @@
  * These notices must be retained in any copies of any part of this software.
  ******************************************************************************/
 #include <stdio.h>
-#include <varargs.h>
+#include <stdarg.h>
 #include <stdlib.h>
 #include <string.h>
 #ifdef __NetBSD__
@@ -40,14 +40,12 @@
 
 /*----------------------------------------------------------------------------*/
 
-void warn( va_alist )
-va_dcl
+void
+warn(const char *fmt, ...)
 {
     va_list args;
-    char *fmt;
 
-    va_start( args );
-    fmt = va_arg( args, char * );
+    va_start(args, fmt);
     fprintf( stderr, "Warning: " );
     vfprintf( stderr, fmt, args );
     va_end( args );
@@ -55,14 +53,12 @@
 
 /*----------------------------------------------------------------------------*/
 
-void die( va_alist )
-va_dcl
+void
+die(const char *fmt, ...)
 {
     va_list args;
-    char *fmt;
 
-    va_start( args );
-    fmt = va_arg( args, char * );
+    va_start(args, fmt);
     fprintf( stderr, "Error: " );
     vfprintf( stderr, fmt, args );
     exit( 1 );
@@ -70,14 +66,12 @@
 
 /*----------------------------------------------------------------------------*/
 
-void fatal( va_alist )
-va_dcl
+void
+fatal(const char *fmt, ...)
 {
     va_list args;
-    char *fmt;
 
-    va_start( args );
-    fmt = va_arg( args, char * );
+    va_start(args, fmt);
     fprintf( stderr, "Internal Error: " );
     vfprintf( stderr, fmt, args );
     exit( 2 );
@@ -142,18 +136,16 @@
     
 /*----------------------------------------------------------------------------*/
 
-void mailmessage( va_alist )
-va_dcl
+void
+mailmessage(const char *fmt, ...)
 {
     va_list args;
-    char *fmt;
     FILE *popen(), *fp;
     char cmdline[80];
      if (whome == NULL) whome = getlogin();
 	sprintf(cmdline,"%s %s",mailprog,whome);
 	fp = popen(cmdline,"w");
-    va_start( args );
-    fmt = va_arg( args, char * );
+    va_start(args, fmt);
     fprintf( fp, "MNM Warning: " );
     vfprintf( fp, fmt, args );
     va_end( args );