Make this compile again. I should have tried to compile the patches myself, but ran out of time this morning.diff -r1.28 -r1.29 src/usr.sbin/sup/source/supcmain.c
(christos)
--- src/usr.sbin/sup/source/Attic/supcmain.c 2009/10/16 12:41:37 1.28
+++ src/usr.sbin/sup/source/Attic/supcmain.c 2009/10/16 22:45:18 1.29
@@ -1,14 +1,14 @@ | @@ -1,14 +1,14 @@ | |||
1 | /* $NetBSD: supcmain.c,v 1.28 2009/10/16 12:41:37 christos Exp $ */ | 1 | /* $NetBSD: supcmain.c,v 1.29 2009/10/16 22:45:18 christos Exp $ */ | |
2 | 2 | |||
3 | /* | 3 | /* | |
4 | * Copyright (c) 1992 Carnegie Mellon University | 4 | * Copyright (c) 1992 Carnegie Mellon University | |
5 | * All Rights Reserved. | 5 | * All Rights Reserved. | |
6 | * | 6 | * | |
7 | * Permission to use, copy, modify and distribute this software and its | 7 | * Permission to use, copy, modify and distribute this software and its | |
8 | * documentation is hereby granted, provided that both the copyright | 8 | * documentation is hereby granted, provided that both the copyright | |
9 | * notice and this permission notice appear in all copies of the | 9 | * notice and this permission notice appear in all copies of the | |
10 | * software, derivative works or modified versions, and any portions | 10 | * software, derivative works or modified versions, and any portions | |
11 | * thereof, and that both notices appear in supporting documentation. | 11 | * thereof, and that both notices appear in supporting documentation. | |
12 | * | 12 | * | |
13 | * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" | 13 | * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" | |
14 | * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR | 14 | * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR | |
@@ -589,27 +589,27 @@ doswitch(int *argc, char ***argv, TREE * | @@ -589,27 +589,27 @@ doswitch(int *argc, char ***argv, TREE * | |||
589 | *oflagsp &= ~aflags; | 589 | *oflagsp &= ~aflags; | |
590 | *aflagsp |= aflags; | 590 | *aflagsp |= aflags; | |
591 | *aflagsp &= ~oflags; | 591 | *aflagsp &= ~oflags; | |
592 | *argc -= optind; | 592 | *argc -= optind; | |
593 | *argv += optind; | 593 | *argv += optind; | |
594 | } | 594 | } | |
595 | 595 | |||
596 | static char * | 596 | static char * | |
597 | init(int argc, char **argv) | 597 | init(int argc, char **argv) | |
598 | { | 598 | { | |
599 | char buf[STRINGLENGTH], *p; | 599 | char buf[STRINGLENGTH], *p; | |
600 | const char *u; | 600 | const char *u; | |
601 | char username[STRINGLENGTH]; | 601 | char username[STRINGLENGTH]; | |
602 | char *supfname, **arg; | 602 | char *supfname, *arg; | |
603 | COLLECTION *c, *lastC; | 603 | COLLECTION *c, *lastC; | |
604 | FILE *f; | 604 | FILE *f; | |
605 | int bogus; | 605 | int bogus; | |
606 | struct passwd *pw; | 606 | struct passwd *pw; | |
607 | TREE *t; | 607 | TREE *t; | |
608 | TREE *collT; /* collections we are interested in */ | 608 | TREE *collT; /* collections we are interested in */ | |
609 | time_t timenow; /* startup time */ | 609 | time_t timenow; /* startup time */ | |
610 | int oflags, aflags; | 610 | int oflags, aflags; | |
611 | int cwant; | 611 | int cwant; | |
612 | #ifdef MACH | 612 | #ifdef MACH | |
613 | void (*oldsigsys) (); | 613 | void (*oldsigsys) (); | |
614 | #endif /* MACH */ | 614 | #endif /* MACH */ | |
615 | 615 |
--- src/usr.sbin/sup/source/Attic/supcmeat.c 2009/10/16 12:41:37 1.35
+++ src/usr.sbin/sup/source/Attic/supcmeat.c 2009/10/16 22:45:18 1.36
@@ -1,14 +1,14 @@ | @@ -1,14 +1,14 @@ | |||
1 | /* $NetBSD: supcmeat.c,v 1.35 2009/10/16 12:41:37 christos Exp $ */ | 1 | /* $NetBSD: supcmeat.c,v 1.36 2009/10/16 22:45:18 christos Exp $ */ | |
2 | 2 | |||
3 | /* | 3 | /* | |
4 | * Copyright (c) 1992 Carnegie Mellon University | 4 | * Copyright (c) 1992 Carnegie Mellon University | |
5 | * All Rights Reserved. | 5 | * All Rights Reserved. | |
6 | * | 6 | * | |
7 | * Permission to use, copy, modify and distribute this software and its | 7 | * Permission to use, copy, modify and distribute this software and its | |
8 | * documentation is hereby granted, provided that both the copyright | 8 | * documentation is hereby granted, provided that both the copyright | |
9 | * notice and this permission notice appear in all copies of the | 9 | * notice and this permission notice appear in all copies of the | |
10 | * software, derivative works or modified versions, and any portions | 10 | * software, derivative works or modified versions, and any portions | |
11 | * thereof, and that both notices appear in supporting documentation. | 11 | * thereof, and that both notices appear in supporting documentation. | |
12 | * | 12 | * | |
13 | * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" | 13 | * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" | |
14 | * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR | 14 | * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR | |
@@ -1473,27 +1473,27 @@ done(int value, const char *fmt, ...) | @@ -1473,27 +1473,27 @@ done(int value, const char *fmt, ...) | |||
1473 | free(goawayreason); | 1473 | free(goawayreason); | |
1474 | goawayreason = (fmt) ? estrdup(buf) : (char *) NULL; | 1474 | goawayreason = (fmt) ? estrdup(buf) : (char *) NULL; | |
1475 | (void) msggoaway(); | 1475 | (void) msggoaway(); | |
1476 | } else { | 1476 | } else { | |
1477 | doneack = value; | 1477 | doneack = value; | |
1478 | donereason = (fmt) ? buf : (char *) NULL; | 1478 | donereason = (fmt) ? buf : (char *) NULL; | |
1479 | (void) msgdone(); | 1479 | (void) msgdone(); | |
1480 | } | 1480 | } | |
1481 | if (!dontjump) | 1481 | if (!dontjump) | |
1482 | longjmp(sjbuf, TRUE); | 1482 | longjmp(sjbuf, TRUE); | |
1483 | } | 1483 | } | |
1484 | 1484 | |||
1485 | void | 1485 | void | |
1486 | goaway(char *fmt, ...) | 1486 | goaway(const char *fmt, ...) | |
1487 | { | 1487 | { | |
1488 | char buf[STRINGLENGTH]; | 1488 | char buf[STRINGLENGTH]; | |
1489 | va_list ap; | 1489 | va_list ap; | |
1490 | 1490 | |||
1491 | va_start(ap, fmt); | 1491 | va_start(ap, fmt); | |
1492 | 1492 | |||
1493 | (void) netcrypt((char *) NULL); | 1493 | (void) netcrypt((char *) NULL); | |
1494 | if (fmt) { | 1494 | if (fmt) { | |
1495 | vsnprintf(buf, sizeof(buf), fmt, ap); | 1495 | vsnprintf(buf, sizeof(buf), fmt, ap); | |
1496 | goawayreason = buf; | 1496 | goawayreason = buf; | |
1497 | } else | 1497 | } else | |
1498 | goawayreason = NULL; | 1498 | goawayreason = NULL; | |
1499 | va_end(ap); | 1499 | va_end(ap); |
--- src/usr.sbin/sup/source/Attic/supscan.c 2007/12/20 20:17:52 1.16
+++ src/usr.sbin/sup/source/Attic/supscan.c 2009/10/16 22:45:18 1.17
@@ -1,14 +1,14 @@ | @@ -1,14 +1,14 @@ | |||
1 | /* $NetBSD: supscan.c,v 1.16 2007/12/20 20:17:52 christos Exp $ */ | 1 | /* $NetBSD: supscan.c,v 1.17 2009/10/16 22:45:18 christos Exp $ */ | |
2 | 2 | |||
3 | /* | 3 | /* | |
4 | * Copyright (c) 1992 Carnegie Mellon University | 4 | * Copyright (c) 1992 Carnegie Mellon University | |
5 | * All Rights Reserved. | 5 | * All Rights Reserved. | |
6 | * | 6 | * | |
7 | * Permission to use, copy, modify and distribute this software and its | 7 | * Permission to use, copy, modify and distribute this software and its | |
8 | * documentation is hereby granted, provided that both the copyright | 8 | * documentation is hereby granted, provided that both the copyright | |
9 | * notice and this permission notice appear in all copies of the | 9 | * notice and this permission notice appear in all copies of the | |
10 | * software, derivative works or modified versions, and any portions | 10 | * software, derivative works or modified versions, and any portions | |
11 | * thereof, and that both notices appear in supporting documentation. | 11 | * thereof, and that both notices appear in supporting documentation. | |
12 | * | 12 | * | |
13 | * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" | 13 | * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" | |
14 | * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR | 14 | * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR | |
@@ -383,27 +383,27 @@ getscancoll(char *filename, char *collna | @@ -383,27 +383,27 @@ getscancoll(char *filename, char *collna | |||
383 | } | 383 | } | |
384 | (void) fclose(f); | 384 | (void) fclose(f); | |
385 | } | 385 | } | |
386 | if ((c = (SCAN_COLLECTION *) malloc(sizeof(SCAN_COLLECTION))) == NULL) | 386 | if ((c = (SCAN_COLLECTION *) malloc(sizeof(SCAN_COLLECTION))) == NULL) | |
387 | quit(1, "supscan: can't malloc collection structure\n"); | 387 | quit(1, "supscan: can't malloc collection structure\n"); | |
388 | c->Cname = collname; | 388 | c->Cname = collname; | |
389 | c->Cbase = basedir; | 389 | c->Cbase = basedir; | |
390 | c->Cprefix = prefix; | 390 | c->Cprefix = prefix; | |
391 | c->Cnext = NULL; | 391 | c->Cnext = NULL; | |
392 | return (c); | 392 | return (c); | |
393 | } | 393 | } | |
394 | 394 | |||
395 | void | 395 | void | |
396 | goaway(char *fmt, ...) | 396 | goaway(const char *fmt, ...) | |
397 | { | 397 | { | |
398 | va_list ap; | 398 | va_list ap; | |
399 | 399 | |||
400 | va_start(ap, fmt); | 400 | va_start(ap, fmt); | |
401 | vfprintf(stderr, fmt, ap); | 401 | vfprintf(stderr, fmt, ap); | |
402 | va_end(ap); | 402 | va_end(ap); | |
403 | (void) putc('\n', stderr); | 403 | (void) putc('\n', stderr); | |
404 | (void) fflush(stderr); | 404 | (void) fflush(stderr); | |
405 | longjmp(sjbuf, TRUE); | 405 | longjmp(sjbuf, TRUE); | |
406 | } | 406 | } | |
407 | 407 | |||
408 | int | 408 | int | |
409 | localhost(char *host) | 409 | localhost(char *host) |