diff options
author | Jingjing Duan <Jingjing.Duan@sun.com> | 2008-08-13 20:09:10 +0200 |
---|---|---|
committer | Paul Jakma <paul@quagga.net> | 2008-08-22 20:52:57 +0200 |
commit | 6a270cd93d02a88709e7292684db47552b630abf (patch) | |
tree | 8783ae29bef1f8e48e6278dcbe4360247316b029 /isisd/isis_pdu.c | |
parent | [isisd] Fix packet filtering with DLPI (diff) | |
download | frr-6a270cd93d02a88709e7292684db47552b630abf.tar.xz frr-6a270cd93d02a88709e7292684db47552b630abf.zip |
[ospfd/isisd] Switch to lib/ Fletcher checksum, fixing bug in isisd
2008-08-13 Jingjing Duan <Jingjing.Duan@sun.com>
* ospfd/: Remove the old checksum implementation and
use the consolidated version.
* isisd/: ditto, thus fixing isisd checksuming on big-endian.
Signed-off-by: Paul Jakma <paul@quagga.net>
Diffstat (limited to 'isisd/isis_pdu.c')
-rw-r--r-- | isisd/isis_pdu.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/isisd/isis_pdu.c b/isisd/isis_pdu.c index 6fcc5ed5e..4311a9057 100644 --- a/isisd/isis_pdu.c +++ b/isisd/isis_pdu.c @@ -32,6 +32,7 @@ #include "hash.c" #include "prefix.h" #include "if.h" +#include "checksum.h" #include "isisd/dict.h" #include "isisd/include-netbsd/iso.h" @@ -1121,7 +1122,7 @@ dontcheckadj: if (isis->debugs & DEBUG_UPDATE_PACKETS) zlog_debug ("LSP LEN: %d", ntohs (lsp->lsp_header->pdu_len)); - iso_csum_create (STREAM_DATA (lsp->pdu) + 12, + fletcher_checksum (STREAM_DATA (lsp->pdu) + 12, ntohs (lsp->lsp_header->pdu_len) - 12, 12); ISIS_FLAGS_SET_ALL (lsp->SRMflags); if (isis->debugs & DEBUG_UPDATE_PACKETS) @@ -1164,7 +1165,7 @@ dontcheckadj: /* 7.3.16.1 */ lsp->lsp_header->seq_num = htonl (ntohl (hdr->seq_num) + 1); - iso_csum_create (STREAM_DATA (lsp->pdu) + 12, + fletcher_checksum (STREAM_DATA (lsp->pdu) + 12, ntohs (lsp->lsp_header->pdu_len) - 12, 12); ISIS_FLAGS_SET_ALL (lsp->SRMflags); |