The function below should copy histograms h_vec to f_vec and then f_vec will be modified. I’m familiar with Clone() function by I’d like to try Copy() function to see the diference. The code compiles under Root but segmintation violation ocures when running. Could someone help me to understand why?
Solved with help of my colleagues. Copy() gets the reference to corresponding object and cannot work with null-pointer. And also the direction in the function is reverse. Thus the correct code is