annotate blk_parsemotd.c @ 2:fba0b6e6cdc7

Added tag ALPHA for changeset ff5e05767bd3
author darius@midget.dons.net.au
date Tue, 23 Oct 2007 10:09:09 +0930
parents ff5e05767bd3
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
1 /* $Id: blk_parsemotd.c,v 1.1.1.1 1997/12/06 05:41:28 darius Exp $ */
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
2
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
3 /*
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
4 *
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
5 */
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
6
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
7 #include <string.h>
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
8 #include "Wlib.h"
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
9 #include "defs.h"
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
10 #include "struct.h"
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
11 #include "data.h"
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
12 #include "proto.h"
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
13
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
14 void
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
15 blk_parsemotd(line)
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
16 char *line;
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
17 {
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
18 /*
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
19 Verify it's our line.
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
20 */
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
21
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
22 if (strncmp("BLK: ", line, 5) != 0)
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
23 return;
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
24
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
25 /*
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
26 See if it's a refit string.
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
27 */
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
28
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
29 if (strncmp(&line[5], "REFIT", 5) == 0) {
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
30 strncpy(blk_refitstring, &line[10], 79);
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
31 blk_refitstring[79] = '\0';
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
32 }
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
33 /*
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
34 Check to see if it's a borgish feature being enabled.
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
35 */
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
36 else if (strncmp(&line[5], "BORGISH ", 8) == 0) {
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
37 if (strncmp(&line[13], "FRCLOAK", 7) == 0)
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
38 blk_friendlycloak = 1;
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
39 }
ff5e05767bd3 Empty changelog
darius
parents:
diff changeset
40 }