diff --git a/test/MainEvent.cxx b/test/MainEvent.cxx
index c5916453f3f123b5b74dd92ca611223ea6820720..9315a50879cd10aafbeaee46cd2533f137c296ed 100644
--- a/test/MainEvent.cxx
+++ b/test/MainEvent.cxx
@@ -1,4 +1,4 @@
-// @(#)root/test:$Name:  $:$Id: MainEvent.cxx,v 1.28 2005/01/12 07:50:02 brun Exp $
+// @(#)root/test:$Name:  $:$Id: MainEvent.cxx,v 1.29 2005/12/02 11:15:44 brun Exp $
 // Author: Rene Brun   19/01/97
 
 ////////////////////////////////////////////////////////////////////////
@@ -209,7 +209,7 @@ int main(int argc, char **argv)
       TTree::SetBranchStyle(branchStyle);
       TBranch *branch = tree->Branch("event", &event, bufsize,split);
       branch->SetAutoDelete(kFALSE);
-      tree->BranchRef();
+      if(split > 1) tree->BranchRef();
       Float_t ptmin = 1;
 
       for (ev = 0; ev < nevent; ev++) {