[insert project logo here (125x200px max)]

Navigator

Mailinglists

Please report any errors or ommissions you find to our `Help' mailinglist, or post a message in the Forums.

Copyright and Licensing Information

Snap is (c) Jonathan T. Moore, 1999-2002 and licensed under the GNU General Public License (GPL).

All other parts of Splash are (c) Willem de Bruijn, 2002-2003 and licensed under the BSD Open Source License.

All sourcecode is made publicly available.

Acknowledgement

Splash and the Splash website are hosted by SourceForge.net

SourceForge.net Logo

osi-open source certified logo

Splash - Documentation

SNMP Plus a Lightweight API for SNAP Handling

Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals  

snap-1.1-wjdb/lib/io.h

Go to the documentation of this file.
00001 /* $Id: io.h,v 1.1.1.1 2002/12/04 18:59:42 wdebruij Exp $ */
00002 
00003 
00004 #ifndef _SNAP_IO_H_
00005 #define _SNAP_IO_H_
00006 
00007 #ifdef __KERNEL__
00008 #include <linux/skbuff.h>
00009 #include <snap/bytecode.h>
00010 #include <snap/packet.h>
00011 #else
00012 #include "bytecode.h"
00013 #include "packet.h"
00014 #endif /* __KERNEL__ */
00015 
00016 typedef struct {
00017   int lenb;
00018   char *s;
00019 } buffer_t;
00020 
00021 #ifndef __KERNEL__
00022 
00023 extern packet_t *unmarshal_packet(char *buffer, int packet_lenb, int buf_lenb);
00024 extern int marshal_packet(packet_t *p, int stack_amt, buffer_t *bufstr);
00025 int file_to_str(int fd, buffer_t *buf);
00026 
00027 #else
00028 
00029 extern int unmarshal_packet(packet_t **p, struct sk_buff *skb);
00030 extern int marshal_packet(struct sk_buff **skbp, packet_t *p, unsigned
00031               int stack_amt);
00032 
00033 #endif /* __KERNEL__ */
00034 
00035 #endif /* !_SNAP_IO_H_ */
00036