6 * Dick Gooris <gooris@lucent.com>
7 * Ulf Lamping <ulf.lamping@web.de>
9 * Wireshark - Network traffic analyzer
10 * By Gerald Combs <gerald@wireshark.org>
11 * Copyright 1998 Gerald Combs
13 * This program is free software; you can redistribute it and/or
14 * modify it under the terms of the GNU General Public License
15 * as published by the Free Software Foundation; either version 2
16 * of the License, or (at your option) any later version.
18 * This program is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU General Public License for more details.
23 * You should have received a copy of the GNU General Public License
24 * along with this program; if not, write to the Free Software
25 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
33 /* XXX where's the best place for these? */
34 #define MAX_SCTP_PORT 65535
35 #define MAX_TCP_PORT 65535
36 #define MAX_UDP_PORT 65535
37 #define MAX_DCCP_PORT 65535
39 typedef struct range_admin_tag {
44 typedef struct range {
45 /* user specified range(s) */
46 guint nranges; /* number of entries in ranges */
47 range_admin_t ranges[1]; /* variable-length array */
51 * Return value from range_convert_str().
59 extern range_t *range_empty(void);
61 extern convert_ret_t range_convert_str(range_t **range, const gchar *es,
64 extern gboolean value_is_in_range(range_t *range, guint32 val);
66 extern gboolean ranges_are_equal(range_t *a, range_t *b);
68 extern void range_foreach(range_t *range, void (*callback)(guint32 val));
70 extern char *range_convert_range(range_t *range);
72 extern range_t *range_copy(range_t *src);
74 #endif /* __RANGE_H__ */