|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [win-pv-devel] [PATCH] Squash a prefast warning
Prefast warns that following the Flink pointer of the EVTCHN context list
may be unsafe due to it being NULL. It should never be NULL so this patch
adds an ASSERTion and hence squashes the warning.
Signed-off-by: Paul Durrant <paul.durrant@xxxxxxxxxx>
---
src/xenbus/evtchn.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/xenbus/evtchn.c b/src/xenbus/evtchn.c
index 3bb8d18..499127a 100644
--- a/src/xenbus/evtchn.c
+++ b/src/xenbus/evtchn.c
@@ -995,6 +995,8 @@ EvtchnSuspendCallbackEarly(
ListEntry = ListEntry->Flink) {
PXENBUS_EVTCHN_CHANNEL Channel;
+ ASSERT(ListEntry->Flink != NULL);
+
Channel = CONTAINING_RECORD(ListEntry, XENBUS_EVTCHN_CHANNEL,
ListEntry);
ASSERT3U(Channel->Magic, ==, XENBUS_EVTCHN_CHANNEL_MAGIC);
--
2.1.1
_______________________________________________
win-pv-devel mailing list
win-pv-devel@xxxxxxxxxxxxxxxxxxxx
http://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |