change the signature that asn2wrs generates for functions to marm all parameters...
[obnox/wireshark/wip.git] / epan / tpg.c
1 /* tpg.c
2  * helper functions for TPG
3  *
4  *  (c) 2005, Luis E. Garcia Ontanon <luis.ontanon@gmail.com>
5  * 
6  * $Id$
7  *
8  * Wireshark - Network traffic analyzer
9  * By Gerald Combs <gerald@wireshark.org>
10  * Copyright 1998 Gerald Combs
11  *
12  * This program is free software; you can redistribute it and/or
13  * modify it under the terms of the GNU General Public License
14  * as published by the Free Software Foundation; either version 2
15  * of the License, or (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
20  * GNU General Public License for more details.
21  *
22  * You should have received a copy of the GNU General Public License
23  * along with this program; if not, write to the Free Software
24  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
25  */
26
27
28 #ifdef HAVE_CONFIG_H
29 # include "config.h"
30 #endif
31
32 #include "tpg.h"
33 #include <epan/emem.h>
34 #include <epan/packet.h>
35
36 extern guint32 tpg_ipv4(tvbparse_elem_t* e _U_) {    
37     /* XXX TO DO */
38     return 0;
39 }
40
41 extern guint8* tpg_ipv6(tvbparse_elem_t* e _U_) {
42     /* XXX TO DO */
43     return NULL;
44 }
45
46 extern tpg_parser_data_t* tpg_start(proto_tree* root_tree,
47                                     tvbuff_t* tvb,
48                                     int offset,
49                                     int len,
50                                     tvbparse_wanted_t* ignore,
51                                     void* private_data) {
52     tpg_parser_data_t* tpg = ep_alloc(sizeof(tpg_parser_data_t));
53     tpg->private_data = private_data;
54     tpg->tt = tvbparse_init(tvb,offset,len,tpg,ignore);
55
56     tpg->stack = ep_stack_new();
57     ep_stack_push(tpg->stack,root_tree);
58     
59     return tpg;
60 }
61