[quagga-dev 3648] Re: 0.98.4 bug report: files ospf_opaque.c, ospf_vty.c and ospf6_asbr.c

Hasso Tepper hasso at estpak.ee
Fri Sep 16 08:20:57 BST 2005


Andrew J. Schorr wrote:
> Are you referring to this code?
> 
>    void
>    ospf_opaque_lsa_refresh_schedule (struct ospf_lsa *lsa0)
>    {
>      struct ospf *ospf = ospf;
> 
> and
> 
>    void
>    ospf_opaque_lsa_flush_schedule (struct ospf_lsa *lsa0)
>    {
>      struct ospf *ospf = ospf;
> 
> I must admit that I cannot see any valid reason for doing
> that.  I also do not understand why gcc does not issue
> a warning.

I'm not sure about gcc, but it's probably leftover from messy days when
part of code used list of ospf structures under ospf master, but part of
code single ospf structure in this list directly. Anyway, ack for fix.

> If so, this looks like a bug.  On the other hand, the
> ospf_external_lsa_flush function does not seem to use the value
> of the final argument (the only code that referenced it is
> commented out).  I'm not sure what the proper fix is
> here.  Given the existing code, it might make sense to drop
> the final argument to the function...

ACK. It's the old code.

> > Suggest initialise local variables before first use.
> > 
> > 2.
> > 
> > ospf6_asbr.c(456): warning #175: subscript out of range
> > ospf6_asbr.c(759): warning #175: subscript out of range
> > ospf6_asbr.c(762): warning #175: subscript out of range
> > ospf6_asbr.c(798): warning #175: subscript out of range
> > ospf6_asbr.c(803): warning #175: subscript out of range
> > ospf6_asbr.c(1208): warning #175: subscript out of range
> > 
> > There is a bug in the ZROUTE_NAME macro.
> 
> Perhaps I'm being dense, but I'm not seeing this.

I don't see it either.

It reminds me one thing though. Every time new (routing) protocol is
added, bugs related to this will pop up. Every daemon has own zroute_name
array etc. This should be in lib IMHO.


-- 
Hasso Tepper
Elion Enterprises Ltd.
WAN administrator



More information about the Quagga-dev mailing list