SMOLNET PORTAL home about changes
#define KEYWORD_SIZE 25     /* number of chars in keyword field */
#define FIELD_SIZE 2        /* number of chars in field identifier */
#define ID_SIZE 8           /* number of chars in entity identifier */
#define IDX_RECORD_SIZE (KEYWORD_SIZE + FIELD_SIZE + ID_SIZE)
#define IDX_KEY_SIZE    (KEYWORD_SIZE + FIELD_SIZE + ID_SIZE)

#define SEQ_SIZE 2              /* number of chars in sequence number field */
#define ATTR_SIZE 1             /* number of characters in attribute field */
#define DATA_SIZE 120           /* maximum number of chars in data field */
#define DAT_RECORD_SIZE (ID_SIZE + FIELD_SIZE + SEQ_SIZE + ATTR_SIZE + DATA_SIZE)
#define DAT_KEY_SIZE    (ID_SIZE + FIELD_SIZE + SEQ_SIZE)

#define MAX_FIELD 100           /* 10 ** FIELD_SIZE */

#define MIN_KEYWORD 2           /* set to 2 to exclude initials in index */
                                /* set to 1 to index initials */
                                /* set to 0 to include blank records */

#define MAX_RECORDS 20          /* don't display more than this many records */

/* field numbers hardcoded into build and qi */

#define NAME_FIELD "01"         /* 'name' field */
#define ALIAS_FIELD "02"        /* 'alias' field */
#define NICKNAME_FIELD "03"     /* 'nickname' field */
#define EMAIL_FIELD "04"        /* email address field */
#define SOUNDEX_FIELD "05"      /* soundex value field */
#define TYPE_FIELD "90"         /* entry type field */
#define PASSWORD_FIELD "93"     /* login password field */

#define MAX_INPUT 256           /* max size of protocol command */

#define SITEINFO_NAME "CSO_SITEINFO" /* logical name for siteinfo file */
#define CONFIG_NAME "CSO_CONFIG"     /* logical name for config file */
#define INDEX_NAME "CSO_INDEX"       /* logical name for index file */
#define DATA_NAME "CSO_DATA"         /* logical name for data file */
#define LOG_NAME "CSO_LOG"           /* logical name for log file */

typedef struct {
    char *number;
    char *name;
    char *desc;
    long attrib;                /* maximum of <bits in long> attributes */
} Fields;

#define ATTR_INDEXED 1
#define ATTR_LOOKUP 2
#define ATTR_PUBLIC 4
#define ATTR_FORCEPUB 8
#define ATTR_DEFAULT 16
#define ATTR_UNIQUE 32

struct attr_struct {
    char *name;
    int value;
} attributes[] = {{"Indexed", ATTR_INDEXED},
                  {"Lookup", ATTR_LOOKUP},
                  {"Public", ATTR_PUBLIC},
                  {"ForcePub", ATTR_FORCEPUB},
                  {"Default", ATTR_DEFAULT},
                  {"Unique", ATTR_UNIQUE}};

#define MAX_ATTRIBUTES (sizeof(attributes) / sizeof(struct attr_struct))

#define EXACT_MODE 1
#define DEBUG_MODE 2

struct mode_struct {
    char *name;
    int value;
} modes[] = {{"exact", EXACT_MODE},
             {"debug", DEBUG_MODE}};

#define MAX_MODES (sizeof(modes) / sizeof(struct mode_struct))

#define DEFAULT_MODE 0
#define DEBUG (mode & DEBUG_MODE)
#define EXACT (mode & EXACT_MODE)

/* single data record attributes (encoded) in data record */
#define ATTR_SUPPRESS 1       /* don't print this record */

#define True 1
#define False 0

#define SOUNDEX_SIZE 4  /* only 4 characters may generate too many matches */

typedef struct astruct {
    int type;
    char *name;
    int field;
    char *value;
    struct astruct *prev;
    struct astruct *next;
} Arg;

/* arg type field definitions */
#define TYPE_NAME 1
#define TYPE_VALUE 2
#define TYPE_EQUAL 4
#define TYPE_RETURN 8
#define TYPE_ON 16
#define TYPE_OFF 32
#define TYPE_MASK (TYPE_ON + TYPE_OFF)

#define NAME_HACK 1  /* mangle names a bit: (1) compress out apostrophes */
                     /* (2) index both parts of a hyphenated name, */
                     /* i.e. cartwright-chickenwood is indexed as cartwright */
                     /* and chickenwood, but not the hyphenated name */

#define MAX_BAD 10   /* number of bad or blank commands to cause a shutdown */

/* modes defined for login_mode */
#define MODE_ANONYMOUS 1  /* anonymous mode (default) */
#define MODE_LOGIN 2      /* logged in to an alias */
#define MODE_PASSWORD 4   /* waiting for response to challenge */

#define CHALLENGE_SIZE 40 /* size of challenge string */

#define VERSION "VMS qi V2.0"

.
Response: text/plain
Original URLgopher://bitreich.org/9/gopher2007/2007-gopher-mirror/gop...
Content-Typetext/plain; charset=utf-8