Re: netwatch bus error

2000-10-09 Thread Ben Collins
I've forwarded this as a bug against netdiag.

On Sat, Oct 07, 2000 at 03:44:51PM +1100, Anton Blanchard wrote:
> 
> > >It is probably doing an unaligned load or store.
> > How would I fix that?
> 
> Try this patch. Ben can this be added to the deb?
> 
> Anton
> 
> 
> --- netdiag-0.7.orig/netwatch/netwatch.c  Wed Jul  7 23:31:26 1999
> +++ netdiag-0.7/netwatch/netwatch.c   Sat Oct  7 15:41:10 2000
> @@ -2366,13 +2366,12 @@
>  }
>  
>  void
> -/*  handle_ip (struct ip *argbuf, int length) */
> -  handle_ip (struct ip *buf, int length)
> +  handle_ip (struct ip *argbuf, int length)
>  {
>int wlen;
> -/*  struct ip bufstruct, *buf = &bufstruct;
> +  struct ip bufstruct, *buf = &bufstruct;
>  
> -  memcpy(buf, argbuf, sizeof(struct ip));*/  /* to fix unaligned accesses */
> +  memcpy(buf, argbuf, sizeof(struct ip));/* to fix unaligned accesses */
>new = time (0);
>wlen = ntohs (buf->tot_len);
>selprob = 40;
> 
> 
> --  
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
> 

-- 
 ---===-=-==-=---==-=--
/  Ben Collins  --  ...on that fantastic voyage...  --  Debian GNU/Linux   \
`  [EMAIL PROTECTED]  --  [EMAIL PROTECTED]  --  [EMAIL PROTECTED]  '
 `---=--===-=-=-=-===-==---=--=---'



Re: netwatch bus error

2000-10-06 Thread Anton Blanchard

> >It is probably doing an unaligned load or store.
> How would I fix that?

Try this patch. Ben can this be added to the deb?

Anton


--- netdiag-0.7.orig/netwatch/netwatch.cWed Jul  7 23:31:26 1999
+++ netdiag-0.7/netwatch/netwatch.c Sat Oct  7 15:41:10 2000
@@ -2366,13 +2366,12 @@
 }
 
 void
-/*  handle_ip (struct ip *argbuf, int length) */
-  handle_ip (struct ip *buf, int length)
+  handle_ip (struct ip *argbuf, int length)
 {
   int wlen;
-/*  struct ip bufstruct, *buf = &bufstruct;
+  struct ip bufstruct, *buf = &bufstruct;
 
-  memcpy(buf, argbuf, sizeof(struct ip));*//* to fix unaligned accesses */
+  memcpy(buf, argbuf, sizeof(struct ip));  /* to fix unaligned accesses */
   new = time (0);
   wlen = ntohs (buf->tot_len);
   selprob = 40;



Re: netwatch bus error

2000-10-02 Thread Onno Benschop

At 00:55 30/09/00 +1100, Anton Blanchard wrote:


> Any ideas why I'd be getting a bus error while running netwatch? Seems to
> die when it gets a packet :-(

It is probably doing an unaligned load or store.


How would I fix that?
--
()/)/)()..ASCII for Onno..
|>>?  ..EBCDIC for Onno..
--- -. -. ---   ..Morse for Onno..

ITmaze   -   ABN: 56 178 057 063   -  ph: 04 1219    -   [EMAIL PROTECTED]



Re: netwatch bus error

2000-09-30 Thread Anton Blanchard

> Any ideas why I'd be getting a bus error while running netwatch? Seems to 
> die when it gets a packet :-(

It is probably doing an unaligned load or store.

Anton