Problems plotting RooSuperCategory

Dear Root/Roofit experts,

I am playing with RooSuperCategory and I have some problems that I hope you’ll be able to solve.
I am trying to implement everything like if this was a simple category, but this is not working.

here is the relevant part of my script

[code]RooWorkspace* ws = (RooWorkspace*) file->Get(“wsp”);

RooRealVar* B_Mass = ws->var(“B_Mass”);
RooAbsPdf* pdf = ws->pdf(“pdf”);
RooDataSet* data = (RooDataSet*) ws->data(“data”);
RooCategory* cat = ws->cat(“fitCat”);

RooPlot* frameUp = B_Mass->frame();
data->plotOn(fplusUp, Cut(“B_ID==B_ID::Bplus && cosThetaSign==cosThetaSign::Up”) );
pdf->plotOn(fplusUp, Slice(*cat,"{Bplus;Up}"), ProjWData(*data)); // it breaks here

TCanvas* c = new TCanvas(“c”,“c”,20,20,800,600);
frameUp->Draw();[/code]

fitCat is my supercategory (from the workspace) and B_ID (Plus or Minus) and CosThetaSign (Up or Down) are the subcategories. Its states are reported here.

Table fitCat : data
±--------------±------+
| {Bplus;Up} | 13641 |
| {Bminus;Up} | 13208 |
| {Bplus;Down} | 13360 |
| {Bminus;Down} | 13359 |
±--------------±------+

It breaks when I plot the pdf and this is the stack trace:

[code] *** Break *** segmentation violation

===========================================================
There was a crash.
This is the entire stack trace of all threads:

Thread 1 (process 41497):
#0 0x00007fff94a55168 in wait4 ()
#1 0x00007fff9abf05f5 in system ()
#2 0x000000010634eacf in TUnixSystem::StackTrace ()
#3 0x000000010634c8e7 in TUnixSystem::DispatchSignals ()
#4
#5 0x000000010759794f in cfit ()
#6 0x000000010759a8ae in G__cfit_C_ACLiC_dict__0_4430 ()
#7 0x0000000106b50fcf in Cint::G__ExceptionWrapper ()
#8 0x0000000106c00b5a in G__execute_call ()
#9 0x0000000106c0113b in G__call_cppfunc ()
#10 0x0000000106bd5633 in G__interpret_func ()
#11 0x0000000106bbf5af in G__getfunction ()
#12 0x0000000106bb396a in G__getitem ()
#13 0x0000000106bb2af6 in G__getexpr ()
#14 0x0000000106ba6596 in G__calc_internal ()
#15 0x0000000106c3b479 in G__process_cmd ()
#16 0x00000001063148d8 in TCint::ProcessLine ()
#17 0x0000000106314d69 in TCint::ProcessLineSynch ()
#18 0x000000010627f227 in TApplication::ExecuteFile ()
#19 0x000000010627e958 in TApplication::ProcessLine ()
#20 0x000000010727acea in TRint::HandleTermInput ()
#21 0x00000001072793a7 in TTermInputHandler::Notify ()
#22 0x000000010727b55d in TTermInputHandler::ReadNotify ()
#23 0x000000010634bdb6 in TUnixSystem::CheckDescriptors ()
#24 0x000000010634b601 in TUnixSystem::DispatchOneEvent ()
#25 0x00000001062d59aa in TSystem::InnerLoop ()
#26 0x00000001062d57dd in TSystem::Run ()
#27 0x000000010627f324 in TApplication::Run ()
#28 0x000000010727a6a0 in TRint::Run ()
#29 0x0000000106272a3f in main ()

The lines below might hint at the cause of the crash.
If they do not help you then please submit a bug report at
http://root.cern.ch/bugs. Please post the ENTIRE stack trace
from above as an attachment in addition to anything else
that might help us fixing this issue.

#5 0x000000010759794f in cfit ()

[/code]

Any idea on how to fix this ?