aboutsummaryrefslogtreecommitdiffstats
path: root/epan/osi-utils.c
diff options
context:
space:
mode:
authorGilbert Ramirez <gram@alumni.rice.edu>2006-03-07 22:38:51 +0000
committerGilbert Ramirez <gram@alumni.rice.edu>2006-03-07 22:38:51 +0000
commit853b929df09a86fd18d580396bd8c6f72cdbd7f6 (patch)
treedb31134df0051d02090a764e6700e98bdb434426 /epan/osi-utils.c
parenta103501de28f0af88dc6912a49fcf78522f61d37 (diff)
Remove dead code. Due the to if() test that checks for specific
values of 'length', the code in question can never run. This fixes Coverity bug ID #1. svn path=/trunk/; revision=17514
Diffstat (limited to 'epan/osi-utils.c')
-rw-r--r--epan/osi-utils.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/epan/osi-utils.c b/epan/osi-utils.c
index f3045dea10..daca6afd21 100644
--- a/epan/osi-utils.c
+++ b/epan/osi-utils.c
@@ -168,10 +168,11 @@ print_area_buf(const guint8 *ad, int length, gchar *buf, int buf_len)
)
) { /* AFI is good and length is long enough */
- if ( length > RFC1237_FULLAREA_LEN + 1 ) { /* Special Case Designated IS */
- g_snprintf(buf, buf_len, "<Invalid length of AREA for DCC / GOSIP AFI>");
- return;
- }
+ /* there used to be a check for (length > RFC1237_FULLAREA_LEN + 1) here,
+ * in order to report an invalied length of AREA for DCC / GOSIP AFI,
+ * but that can *never* be the case because the if() test above explicitly
+ * tests for (length == RFC1237_FULLAREA_LEN) or (length == RFC1237_FULLAREA_LEN + 1)
+ */
cur += g_snprintf(cur, buf_len-(cur-buf), "[%02x|%02x:%02x][%02x|%02x:%02x:%02x|%02x:%02x]",
ad[0], ad[1], ad[2], ad[3], ad[4],