1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-03 05:09:14 +00:00

Make nping and ncat fail (the way nmap does) when invalid nsock engines are supplied.

This commit is contained in:
henri
2012-10-29 10:22:32 +00:00
parent c0cf25dabd
commit 58418396a8
2 changed files with 4 additions and 3 deletions

View File

@@ -956,8 +956,8 @@ char errstr[256];
if( o.issetDisablePacketCapture() && o.disablePacketCapture()==true )
outError(QT_2, "Warning: There is no point on specifying a BPF filter if you disable packet capture. BPF filter will be ignored.");
} else if (optcmp(long_options[option_index].name, "nsock-engine") == 0){
nsock_set_default_engine(optarg);
if (nsock_set_default_engine(optarg) < 0)
outFatal(QT_3, "Unknown or non-available engine: %s", optarg);
/* Output Options */
} else if (optcmp(long_options[option_index].name, "quiet") == 0 ){
o.setVerbosity(-4);