1*d44a5ed1SThomas Cort /* $NetBSD: msgdb.h,v 1.3 2012/03/06 16:26:01 mbalmer Exp $ */ 2*d44a5ed1SThomas Cort 3*d44a5ed1SThomas Cort /* 4*d44a5ed1SThomas Cort * Copyright 1997 Piermont Information Systems Inc. 5*d44a5ed1SThomas Cort * All rights reserved. 6*d44a5ed1SThomas Cort * 7*d44a5ed1SThomas Cort * Written by Philip A. Nelson for Piermont Information Systems Inc. 8*d44a5ed1SThomas Cort * 9*d44a5ed1SThomas Cort * Redistribution and use in source and binary forms, with or without 10*d44a5ed1SThomas Cort * modification, are permitted provided that the following conditions 11*d44a5ed1SThomas Cort * are met: 12*d44a5ed1SThomas Cort * 1. Redistributions of source code must retain the above copyright 13*d44a5ed1SThomas Cort * notice, this list of conditions and the following disclaimer. 14*d44a5ed1SThomas Cort * 2. Redistributions in binary form must reproduce the above copyright 15*d44a5ed1SThomas Cort * notice, this list of conditions and the following disclaimer in the 16*d44a5ed1SThomas Cort * documentation and/or other materials provided with the distribution. 17*d44a5ed1SThomas Cort * 3. The name of Piermont Information Systems Inc. may not be used to endorse 18*d44a5ed1SThomas Cort * or promote products derived from this software without specific prior 19*d44a5ed1SThomas Cort * written permission. 20*d44a5ed1SThomas Cort * 21*d44a5ed1SThomas Cort * THIS SOFTWARE IS PROVIDED BY PIERMONT INFORMATION SYSTEMS INC. ``AS IS'' 22*d44a5ed1SThomas Cort * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23*d44a5ed1SThomas Cort * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24*d44a5ed1SThomas Cort * ARE DISCLAIMED. IN NO EVENT SHALL PIERMONT INFORMATION SYSTEMS INC. BE 25*d44a5ed1SThomas Cort * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26*d44a5ed1SThomas Cort * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27*d44a5ed1SThomas Cort * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28*d44a5ed1SThomas Cort * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29*d44a5ed1SThomas Cort * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30*d44a5ed1SThomas Cort * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31*d44a5ed1SThomas Cort * THE POSSIBILITY OF SUCH DAMAGE. 32*d44a5ed1SThomas Cort 33*d44a5ed1SThomas Cort * 34*d44a5ed1SThomas Cort */ 35*d44a5ed1SThomas Cort 36*d44a5ed1SThomas Cort /* mdb.h - definitions for the msg database. */ 37*d44a5ed1SThomas Cort 38*d44a5ed1SThomas Cort #ifndef MSGDB_H 39*d44a5ed1SThomas Cort #define MSGDB_H 40*d44a5ed1SThomas Cort 41*d44a5ed1SThomas Cort /* Definition for a list of messages. */ 42*d44a5ed1SThomas Cort 43*d44a5ed1SThomas Cort typedef struct id_rec { 44*d44a5ed1SThomas Cort char *id; 45*d44a5ed1SThomas Cort 46*d44a5ed1SThomas Cort /* For the balanced tree. */ 47*d44a5ed1SThomas Cort short balance; 48*d44a5ed1SThomas Cort struct id_rec *left, *right; 49*d44a5ed1SThomas Cort 50*d44a5ed1SThomas Cort /* For the list of messages. */ 51*d44a5ed1SThomas Cort struct id_rec *next; 52*d44a5ed1SThomas Cort char *msg; 53*d44a5ed1SThomas Cort int msg_no; 54*d44a5ed1SThomas Cort } id_rec; 55*d44a5ed1SThomas Cort 56*d44a5ed1SThomas Cort #endif 57