Ethereal-dev: [Ethereal-dev] [Patch] plugins on Win32

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: "Gisle Vanem" <giva@xxxxxxxxx>
Date: Thu, 30 Oct 2003 01:12:44 +0100
Here's a small patch to make the plugin*.c files compile
on MingW and MSVC. filesystem.h is needed for the 
p_get_datafile_path variable.

--- plugins\plugin_api.h.orig        Wed Sep 24 19:35:08 2003
+++ plugins\plugin_api.h     Wed Oct 29 23:33:21 2003
@@ -57,6 +57,7 @@
 #include "asn1.h"
 #include "packet-per.h"
 #include "epan/except.h"
+#include "epan/filesystem.h"

 #include "plugin_table.h"


The following patch is needed since these typedefs are already 
in Xplugin_table.h generated by plugin_gen.py from:
 extern guint8 *tvb_get_string (tvbuff_t *, gint, gint);
 extern guint8 *tvb_get_stringz (tvbuff_t *, gint, gint *);

in xyzzy

--- plugins\plugin_table.h.orig      Fri Jul 18 04:01:35 2003
+++ plugins\plugin_table.h   Tue Aug 26 19:09:51 2003
@@ -31,12 +31,8 @@
    to those functions for the DLL plugin to use. */

 /* Typedefs to make our plugin_address_table_t struct look prettier */
-
 /* file generated by plugin_gen.py */
 #include "Xplugin_table.h"
-
-typedef guint8* (*addr_tvb_get_string)(tvbuff_t*, gint, gint);
-typedef guint8* (*addr_tvb_get_stringz)(tvbuff_t*, gint, gint*);

 typedef struct  {

-----

--gv