Re: library for ebtales

Bart De Schuymer <[email protected]>
Newsgroups gmane.linux.network.bridge.ebtables.devel
Message-ID <[email protected]>
Op di, 05-04-2005 te 22:09 +0200, schreef Jens Götze:
> have you a 64 bit system running? if yes, can you maybe patch the
> library for 64 bit?

I don't have such a machine. Just use the sparc_cast from
communication.c, the only issue is handing pointers to the kernel.

> i have found two bugs and made a few changes. the next version of
> libebtc is a first real unstable version (v.0.1.0).

I suggest these 2 changes:
--- ebtc.c.old  2005-04-06 07:26:41.000000000 +0000
+++ ebtc.c      2005-04-06 07:33:58.000000000 +0000
@@ -150,7 +150,7 @@ struct ebtc_handle_st {

     int changed;

-    chain2id_t buildinchains[NF_BR_NUMHOOKS + 1];
+    chain2id_t builtinchains[NF_BR_NUMHOOKS + 1];

     struct {

@@ -255,7 +255,7 @@ static int check_entry (const ebt_entry_

 /* ---- CODE ---- */

-    if (!entry->bitmask & EBT_ENTRY_OR_ENTRIES)
+    if (!(entry->bitmask & EBT_ENTRY_OR_ENTRIES))
         return -1;

     /* Check offsets */


Any reason why you use the complicated gnu makefile generation?
autogen.sh returns errors that autoheader2.50 and autoconf2.50 is not
found and I therefore couldn't test your code. There is no need for your
code to be platform independent, ebtables only exists on Linux.

Apart from that, the only comment I have is that there is a lot of
duplicated code in ebtc.c.

Bart




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id396&op=click
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.