Add sanity check to DetectAdressParse.

The function is only used at parsing time, this is not costly to add
a simple sanity check.
remotes/origin/master-1.1.x
Eric Leblond 14 years ago committed by Victor Julien
parent 7168e0aafc
commit 85e8d8e200

@ -1223,6 +1223,11 @@ int DetectAddressParse(DetectAddressHead *gh, char *str)
SCLogDebug("gh %p, str %s", gh, str);
if (str == NULL) {
SCLogDebug("DetectAddressParse can not be run with NULL address");
goto error;
}
DetectAddressHead *ghn = DetectAddressHeadInit();
if (ghn == NULL) {
SCLogDebug("DetectAddressHeadInit for ghn failed");

Loading…
Cancel
Save