diff options
Diffstat (limited to 'syncCommand.cpp')
-rw-r--r-- | syncCommand.cpp | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/syncCommand.cpp b/syncCommand.cpp index d5bb8dc..12d32f8 100644 --- a/syncCommand.cpp +++ b/syncCommand.cpp @@ -1,16 +1,27 @@ #include "syncCommand.h" SyncCommand::SyncCommand(ConnectionList & cl ) -:cl_(cl) { + scc_ = new SyncConnectionCommand(cl); + src_ = new SyncRouteCommand(); } SyncCommand::SyncCommand(ConnectionList & cl, u_int16_t mux ) -:cl_(cl),mux_(mux) { + scc_ = new SyncConnectionCommand(cl,mux); + src_=NULL; } -u_int16_t SyncCommand::getMux() const +SyncCommand::SyncCommand(u_int16_t mux ) +{ + scc_ = NULL; + src_ = new SyncRouteCommand(mux); +} + +SyncCommand::~SyncCommand() { - return mux_; + if (scc_) + delete scc_; + if (src_) + delete src_; } |