mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Cleaning up --help.
-D and -Y/y were still listed, even though they had no effect anymore. Removing some dead code along with -D. BIT-1372 #closed
This commit is contained in:
parent
bd1191c60b
commit
1132470b05
3 changed files with 4 additions and 21 deletions
|
@ -7,8 +7,6 @@
|
|||
#include "EquivClass.h"
|
||||
#include "DFA.h"
|
||||
|
||||
int dfa_state_cache_size = 10000;
|
||||
|
||||
unsigned int DFA_State::transition_counter = 0;
|
||||
|
||||
DFA_State::DFA_State(int arg_state_num, const EquivClass* ec,
|
||||
|
@ -292,9 +290,8 @@ unsigned int DFA_State::Size()
|
|||
+ (centry ? padded_sizeof(CacheEntry) : 0);
|
||||
}
|
||||
|
||||
DFA_State_Cache::DFA_State_Cache(int arg_maxsize)
|
||||
DFA_State_Cache::DFA_State_Cache()
|
||||
{
|
||||
maxsize = arg_maxsize;
|
||||
hits = misses = 0;
|
||||
}
|
||||
|
||||
|
@ -402,7 +399,7 @@ DFA_Machine::DFA_Machine(NFA_Machine* n, EquivClass* arg_ec)
|
|||
|
||||
ec = arg_ec;
|
||||
|
||||
dfa_state_cache = new DFA_State_Cache(dfa_state_cache_size);
|
||||
dfa_state_cache = new DFA_State_Cache();
|
||||
|
||||
NFA_state_list* ns = new NFA_state_list;
|
||||
ns->append(n->FirstState());
|
||||
|
|
|
@ -15,8 +15,6 @@ class DFA_State;
|
|||
|
||||
#include "NFA.h"
|
||||
|
||||
extern int dfa_state_cache_size;
|
||||
|
||||
class DFA_Machine;
|
||||
class DFA_State;
|
||||
struct CacheEntry;
|
||||
|
@ -78,7 +76,7 @@ struct CacheEntry {
|
|||
|
||||
class DFA_State_Cache {
|
||||
public:
|
||||
DFA_State_Cache(int maxsize);
|
||||
DFA_State_Cache();
|
||||
~DFA_State_Cache();
|
||||
|
||||
// If the caller stores the handle, it has to call Ref() on it.
|
||||
|
@ -105,8 +103,6 @@ public:
|
|||
void GetStats(Stats* s);
|
||||
|
||||
private:
|
||||
int maxsize;
|
||||
|
||||
int hits; // Statistics
|
||||
int misses;
|
||||
|
||||
|
|
12
src/main.cc
12
src/main.cc
|
@ -178,8 +178,6 @@ void usage()
|
|||
fprintf(stderr, " -i|--iface <interface> | read from given interface\n");
|
||||
fprintf(stderr, " -p|--prefix <prefix> | add given prefix to policy file resolution\n");
|
||||
fprintf(stderr, " -r|--readfile <readfile> | read from given tcpdump file\n");
|
||||
fprintf(stderr, " -y|--flowfile <file>[=<ident>] | read from given flow file\n");
|
||||
fprintf(stderr, " -Y|--netflow <ip>:<prt>[=<id>] | read flow from socket\n");
|
||||
fprintf(stderr, " -s|--rulefile <rulefile> | read rules from given file\n");
|
||||
fprintf(stderr, " -t|--tracefile <tracefile> | activate execution tracing\n");
|
||||
fprintf(stderr, " -w|--writefile <writefile> | write to given tcpdump file\n");
|
||||
|
@ -190,7 +188,6 @@ void usage()
|
|||
fprintf(stderr, " -B|--debug <dbgstreams> | Enable debugging output for selected streams ('-B help' for help)\n");
|
||||
#endif
|
||||
fprintf(stderr, " -C|--no-checksums | ignore checksums\n");
|
||||
fprintf(stderr, " -D|--dfa-size <size> | DFA state cache size\n");
|
||||
fprintf(stderr, " -F|--force-dns | force DNS\n");
|
||||
fprintf(stderr, " -I|--print-id <ID name> | print out given ID\n");
|
||||
fprintf(stderr, " -K|--md5-hashkey <hashkey> | set key for MD5-keyed hashing\n");
|
||||
|
@ -486,8 +483,6 @@ int main(int argc, char** argv)
|
|||
{"broxygen", required_argument, 0, 'X'},
|
||||
{"prefix", required_argument, 0, 'p'},
|
||||
{"readfile", required_argument, 0, 'r'},
|
||||
{"flowfile", required_argument, 0, 'y'},
|
||||
{"netflow", required_argument, 0, 'Y'},
|
||||
{"rulefile", required_argument, 0, 's'},
|
||||
{"tracefile", required_argument, 0, 't'},
|
||||
{"writefile", required_argument, 0, 'w'},
|
||||
|
@ -495,7 +490,6 @@ int main(int argc, char** argv)
|
|||
{"print-state", required_argument, 0, 'x'},
|
||||
{"analyze", required_argument, 0, 'z'},
|
||||
{"no-checksums", no_argument, 0, 'C'},
|
||||
{"dfa-cache", required_argument, 0, 'D'},
|
||||
{"force-dns", no_argument, 0, 'F'},
|
||||
{"load-seeds", required_argument, 0, 'G'},
|
||||
{"save-seeds", required_argument, 0, 'H'},
|
||||
|
@ -554,7 +548,7 @@ int main(int argc, char** argv)
|
|||
opterr = 0;
|
||||
|
||||
char opts[256];
|
||||
safe_strncpy(opts, "B:D:e:f:I:i:K:l:n:p:R:r:s:T:t:U:w:x:X:z:CFGLNOPSWabdghvZQ",
|
||||
safe_strncpy(opts, "B:e:f:I:i:K:l:n:p:R:r:s:T:t:U:w:x:X:z:CFGLNOPSWabdghvZQ",
|
||||
sizeof(opts));
|
||||
|
||||
#ifdef USE_PERFTOOLS_DEBUG
|
||||
|
@ -628,10 +622,6 @@ int main(int argc, char** argv)
|
|||
override_ignore_checksums = 1;
|
||||
break;
|
||||
|
||||
case 'D':
|
||||
dfa_state_cache_size = atoi(optarg);
|
||||
break;
|
||||
|
||||
case 'E':
|
||||
pseudo_realtime = 1.0;
|
||||
if ( optarg )
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue