From 2b3bcfb6e0097c5467c53cd8882bca9f10bf90f4 Mon Sep 17 00:00:00 2001 From: Mark Haverkamp Date: Mon, 27 Jun 2005 21:33:30 +0000 Subject: [PATCH] saEvtEventAttributesSet needs to check that the priority value passed in is valid. git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@712 fd59a12c-fef9-0310-b244-a6a79926bd2f --- lib/evt.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/evt.c b/lib/evt.c index 33328b2f..9604745b 100644 --- a/lib/evt.c +++ b/lib/evt.c @@ -1392,6 +1392,11 @@ saEvtEventAttributesSet( struct event_data_instance *edi; int i; + if (priority < SA_EVT_HIGHEST_PRIORITY || + priority > SA_EVT_LOWEST_PRIORITY) { + return SA_AIS_ERR_INVALID_PARAM; + } + error = saHandleInstanceGet(&event_handle_db, eventHandle, (void*)&edi); if (error != SA_AIS_OK) {