From: pulvir Date: Wed, 1 Dec 2010 17:27:23 +0000 (+0000) Subject: Bugfix: function SetEvent() in AliRsnTarget needs to be virtual, since it is overload... X-Git-Url: http://git.uio.no/git/?a=commitdiff_plain;h=928bbcdb4af2efe8020fac58f44d7155d7555f56;p=u%2Fmrichter%2FAliRoot.git Bugfix: function SetEvent() in AliRsnTarget needs to be virtual, since it is overloaded in some of the heir classes --- diff --git a/PWG2/RESONANCES/AliRsnCut.h b/PWG2/RESONANCES/AliRsnCut.h index 740925c9569..c9771938122 100644 --- a/PWG2/RESONANCES/AliRsnCut.h +++ b/PWG2/RESONANCES/AliRsnCut.h @@ -29,7 +29,7 @@ class AliRsnCut : public AliRsnTarget AliRsnCut(const char *name, RSNTARGET target, Double_t dmin, Double_t dmax=0., Int_t imin=0 , Int_t imax=0 ); AliRsnCut(const AliRsnCut& copy); AliRsnCut& operator=(const AliRsnCut& copy); - virtual ~AliRsnCut() { fEvent = 0x0; }; + virtual ~AliRsnCut() { }; Int_t GetMinI() {return fMinI;} Int_t GetMaxI() {return fMaxI;} diff --git a/PWG2/RESONANCES/AliRsnTarget.cxx b/PWG2/RESONANCES/AliRsnTarget.cxx index 978a1b78e78..cc61c273ad3 100644 --- a/PWG2/RESONANCES/AliRsnTarget.cxx +++ b/PWG2/RESONANCES/AliRsnTarget.cxx @@ -9,6 +9,8 @@ // that the object being processed corresponds to what is expected. // +#include "AliLog.h" + #include "AliRsnEvent.h" #include "AliRsnDaughter.h" #include "AliRsnMother.h" @@ -98,3 +100,14 @@ const char* AliRsnTarget::GetTargetTypeName() const default: return "Undefined"; } } + +//______________________________________________________________________________ +void AliRsnTarget::SetEvent(AliRsnEvent *event) +{ +// +// +// + + AliDebug(AliLog::kDebug + 3, "Using implementation of mother class"); + fEvent = event; +} diff --git a/PWG2/RESONANCES/AliRsnTarget.h b/PWG2/RESONANCES/AliRsnTarget.h index 0f7c2fb26c2..85147e4ee7e 100644 --- a/PWG2/RESONANCES/AliRsnTarget.h +++ b/PWG2/RESONANCES/AliRsnTarget.h @@ -42,7 +42,7 @@ class AliRsnTarget : public TNamed Bool_t TargetOK(TObject *object); AliRsnEvent* GetEvent() {return fEvent;} - void SetEvent(AliRsnEvent *event) {fEvent = event;} + virtual void SetEvent(AliRsnEvent *event); protected: