mirror of https://github.com/OISF/suricata
detect/ipv6: remove useless code
Remove useless allocation and free. Found by cppcheck as a potential issue: src/detect-engine-address-ipv6.c:385:12: warning: Either the condition 'tmp!=NULL' is redundant or there is possible null pointer dereference: tmp. [nullPointerRedundantCheck] memset(tmp,0,sizeof(DetectAddress)); ^ src/detect-engine-address-ipv6.c:525:13: note: Assuming that condition 'tmp!=NULL' is not redundant if (tmp != NULL) ^ src/detect-engine-address-ipv6.c:385:12: note: Null pointer dereference memset(tmp,0,sizeof(DetectAddress)); ^ But code turned out not to do anything, so removed. Bug: #5291.pull/7321/head
parent
ea2d0ecf08
commit
bad9005161
Loading…
Reference in New Issue