patch-2.4.22 linux-2.4.22/net/sched/cls_rsvp.h
Next file: linux-2.4.22/net/sched/sch_atm.c
Previous file: linux-2.4.22/net/sched/Config.in
Back to the patch index
Back to the overall index
-  Lines: 25
-  Date:
2003-08-25 04:44:44.000000000 -0700
-  Orig file: 
linux-2.4.21/net/sched/cls_rsvp.h
-  Orig date: 
2003-06-13 07:51:39.000000000 -0700
diff -urN linux-2.4.21/net/sched/cls_rsvp.h linux-2.4.22/net/sched/cls_rsvp.h
@@ -518,7 +518,7 @@
 
 	for (sp = &data->ht[h1]; (s=*sp) != NULL; sp = &s->next) {
 		if (dst[RSVP_DST_LEN-1] == s->dst[RSVP_DST_LEN-1] &&
-		    pinfo->protocol == s->protocol &&
+		    pinfo && pinfo->protocol == s->protocol &&
 		    memcmp(&pinfo->dpi, &s->dpi, sizeof(s->dpi)) == 0
 #if RSVP_DST_LEN == 4
 		    && dst[0] == s->dst[0]
@@ -560,9 +560,12 @@
 		goto errout;
 	memset(s, 0, sizeof(*s));
 	memcpy(s->dst, dst, sizeof(s->dst));
-	s->dpi = pinfo->dpi;
-	s->protocol = pinfo->protocol;
-	s->tunnelid = pinfo->tunnelid;
+
+	if (pinfo) {
+		s->dpi = pinfo->dpi;
+		s->protocol = pinfo->protocol;
+		s->tunnelid = pinfo->tunnelid;
+	}
 	for (sp = &data->ht[h1]; *sp; sp = &(*sp)->next) {
 		if (((*sp)->dpi.mask&s->dpi.mask) != s->dpi.mask)
 			break;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)