diff options
author | Hanoh Haim <hhaim@cisco.com> | 2016-02-15 14:19:03 +0200 |
---|---|---|
committer | Hanoh Haim <hhaim@cisco.com> | 2016-02-15 14:19:03 +0200 |
commit | f6901ca1f2cca419eeba2e1a35a38fe06a6650be (patch) | |
tree | aa998cd7f1005cc3efa192cc88c38b7d5dfcb650 /src/main.cpp | |
parent | 1f60016f591ebd2e260e501c8c5da10c11d0c7ad (diff) |
add support for dp mac replace mode-golden were changed
Diffstat (limited to 'src/main.cpp')
-rwxr-xr-x | src/main.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index a2d06067..6ee3a03d 100755 --- a/src/main.cpp +++ b/src/main.cpp @@ -238,6 +238,15 @@ static int parse_options(int argc, return 0; } +void set_default_mac_addr(){ + + int i; + for (i=0; i<4; i++) { + memset(CGlobalInfo::m_options.get_dst_src_mac_addr(i),((i+1)<<4),6); + memset(CGlobalInfo::m_options.get_src_mac_addr(i),((i+1)<<4)+8,6); + } +} + int main(int argc , char * argv[]){ @@ -246,6 +255,7 @@ int main(int argc , char * argv[]){ if ( parse_options(argc, argv, &CGlobalInfo::m_options , params) != 0) { exit(-1); } + set_default_mac_addr(); opt_type_e type = (opt_type_e) params["type"]; |