X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/f930e6a6429d8b95504c58cdee9e0f01db5be618..9ed663cdb641ed18d1b121017ea640df3daddfdc:/projects/stargazer/plugins/capture/ether_freebsd/ether_cap.cpp?ds=inline diff --git a/projects/stargazer/plugins/capture/ether_freebsd/ether_cap.cpp b/projects/stargazer/plugins/capture/ether_freebsd/ether_cap.cpp index 07e38577..20ca2480 100644 --- a/projects/stargazer/plugins/capture/ether_freebsd/ether_cap.cpp +++ b/projects/stargazer/plugins/capture/ether_freebsd/ether_cap.cpp @@ -48,44 +48,24 @@ $Author: faust $ #include #include -#include "ether_cap.h" #include "stg/common.h" #include "stg/raw_ip_packet.h" #include "stg/traffcounter.h" +#include "stg/plugin_creator.h" +#include "ether_cap.h" //#define CAP_DEBUG 1 -//----------------------------------------------------------------------------- - -//----------------------------------------------------------------------------- -class BPF_CAP_CREATOR { -private: - BPF_CAP * bpfc; - -public: - BPF_CAP_CREATOR() - : bpfc(new BPF_CAP()) - { - } - ~BPF_CAP_CREATOR() - { - delete bpfc; - } - BPF_CAP * GetCapturer() - { - return bpfc; - } -}; //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -BPF_CAP_CREATOR bcc; +PLUGIN_CREATOR bcc; //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- PLUGIN * GetPlugin() { -return bcc.GetCapturer(); +return bcc.GetPlugin(); } //----------------------------------------------------------------------------- //-----------------------------------------------------------------------------