ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/include/motd.h
Revision: 65
Committed: Mon Oct 3 23:33:16 2005 UTC (20 years, 10 months ago) by adx
Content type: text/x-chdr
File size: 1869 byte(s)
Log Message:
- removed external references from libio/misc
- imported s_misc.c to libio, moved CurrentTime there

File Contents

# User Rev Content
1 adx 30 /*
2     * ircd-hybrid: an advanced Internet Relay Chat Daemon(ircd).
3     * motd.h: A header for the MOTD functions.
4     *
5     * Copyright (C) 2002 by the past and present ircd coders, and others.
6     *
7     * This program is free software; you can redistribute it and/or modify
8     * it under the terms of the GNU General Public License as published by
9     * the Free Software Foundation; either version 2 of the License, or
10     * (at your option) any later version.
11     *
12     * This program is distributed in the hope that it will be useful,
13     * but WITHOUT ANY WARRANTY; without even the implied warranty of
14     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15     * GNU General Public License for more details.
16     *
17     * You should have received a copy of the GNU General Public License
18     * along with this program; if not, write to the Free Software
19     * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
20     * USA
21     *
22 knight 31 * $Id$
23 adx 30 */
24    
25     #ifndef INCLUDED_motd_h
26     #define INCLUDED_motd_h
27 adx 65
28 adx 30 #include "ircd_defs.h"
29 adx 65 #include "s_misc.h"
30 adx 30
31     #define MESSAGELINELEN 256
32    
33     struct MessageFileLine
34     {
35     char line[MESSAGELINELEN + 1];
36     struct MessageFileLine *next;
37     };
38    
39     typedef struct MessageFileLine MessageFileLine;
40    
41     typedef enum {
42     USER_MOTD,
43     USER_LINKS,
44     OPER_MOTD,
45     ISSUPPORT
46     } MotdType;
47    
48     struct MessageFile
49     {
50     MotdType motdType;
51     MessageFileLine *contentsOfFile;
52     char fileName[PATH_MAX + 1];
53     char lastChangedDate[MAX_DATE_STRING + 1];
54     };
55    
56     typedef struct MessageFile MessageFile;
57    
58     struct Client;
59    
60     extern void init_message_file(MotdType, const char *, struct MessageFile *);
61     extern int send_message_file(struct Client *, struct MessageFile *);
62     extern int read_message_file(MessageFile *);
63     extern MessageFile *init_MessageLine(void);
64     extern void addto_MessageLine(MessageFile *, const char *);
65     extern void destroy_MessageLine(MessageFile *);
66    
67     #endif /* INCLUDED_motd_h */

Properties

Name Value
svn:eol-style native
svn:keywords Id Revision