TGraphSmooth crashes in newest root version 5.15/01!

Dear Rooters

Since the creation of TGraphSmooth I have tested the corresponding tutorial "motorcycle.C"
with every root version that I have downloaded, and it worked w/o any problem in all root
versions including version 5.13/01.

Sorrowly, in the newest version 5.15/01 the tutorial finally crashes after the following line:
grout = gs->SmoothKern(grin,“normal”,2.0);

My own program crashes also at the following code:

   TGraph *grin, *grout;
   TGraphSmooth *gs = new TGraphSmooth("supsmu");
cout << "*gs = " << gs << endl;
   grin = new TGraph(nin, yin, xin); //reference xin as y array!
cout << "*grin = " << grin << endl;
   grout = gs->SmoothSuper(grin, "" ,bass, span);
cout << "*grout = " << grout << endl;

with the output:
*gs = 0x469d020
*grin = 0x4699ef0
root.exe(1046) malloc: *** error for object 0x4b60600: incorrect checksum for freed object - object was probably modified after being freed, break at szone_error to debug
root.exe(1046) malloc: *** set a breakpoint in szone_error to debug

Can someone tell me what has changed (TGraph?) in the newest root version, so that
TGraphSmooth no longer works although the code has not changed?

Best regards
Christian

P.S.: Here is the result of running the tutorial:
root [0] .x graphs/motorcycle.C

*** Break *** bus error
/Users/cs/ROOT/root/tutorials/251: No such file or directory.
Attaching to process 251.
Reading symbols for shared libraries . done
Reading symbols for shared libraries … done
0x90031aa4 in wait4 ()

========== STACKS OF ALL THREADS ==========

Thread 1 (process 251 thread 0xd03):
#0 0x90031aa4 in wait4 ()
#1 0x900521a8 in system ()
#2 0x0112ea40 in TUnixSystem::StackTrace ()
#3 0x01132a3c in TUnixSystem::DispatchSignals ()
#4
#5 0x01f97460 in TGraphSmooth::Smoothin ()
#6 0x01f9792c in TGraphSmooth::SmoothKern ()
#7 0x0208f158 in G__G__Graf2_284_0_4 ()
#8 0x003e24ac in Cint::G__ExceptionWrapper ()
#9 0x0048c888 in G__call_cppfunc ()
#10 0x00476e78 in G__interpret_func ()
#11 0x0046bfb4 in G__getfunction ()
#12 0x00503d48 in G__getstructmem ()
#13 0x004fc2d8 in G__getvariable ()
#14 0x0044706c in G__getitem ()
#15 0x0045157c in G__getexpr ()
#16 0x00450b30 in G__getexpr ()
#17 0x004ae02c in G__exec_statement ()
#18 0x004789e8 in G__interpret_func ()
#19 0x0046c6e0 in G__getfunction ()
#20 0x00447484 in G__getitem ()
#21 0x0045157c in G__getexpr ()
#22 0x00453ca8 in G__calc_internal ()
#23 0x004b7858 in G__process_cmd ()
#24 0x010d6f94 in TCint::ProcessLine ()
#25 0x0100f038 in TApplication::ProcessFile ()
#26 0x0100c430 in TApplication::ProcessLine ()
#27 0x00035904 in TRint::HandleTermInput ()
#28 0x01132d64 in TUnixSystem::CheckDescriptors ()
#29 0x01132fd0 in TUnixSystem::DispatchOneEvent ()
#30 0x01089f34 in TSystem::InnerLoop ()
#31 0x01089ea0 in TSystem::Run ()
#32 0x0100b78c in TApplication::Run ()
#33 0x00035dd0 in TRint::Run ()
#34 0x000029d8 in main ()
Root > Function motorcycle() busy flag cleared

Christian,

Thanks for reporting this problem. I simply forgot to check-in the data file motorcycle.dat required to run motorcycle.C.
Now in CVS.

Rene

Dear Rene

Thank you, however, this is NOT the problem!

Both, motorcycle.C AND my compiled program crash at the line:
grout = gs->SmoothSuper(grin, “” ,bass, span);
See my code-fragment.

There must be something broken.
The error seems to indicate that an object (TGraph?) is deleted twice?

Best regards
Christian

Christian,

I cannot reproduce this problem. I tried on Mac, Linux and Windows.

Rene

Dear Rene

I have just downloaded root again from cvs and compiled it on my new MacBook Pro.
Sorrowly, I get still the same error when running motorcycle.C.

In the following there are the outputs from “.x graphs/motorcycle.C” on:
1, my Mac
2, HP Laptop running FC4

ad 1, Mac:
root [0] .x graphs/motorcycle.C

*** Break *** bus error
/Volumes/CoreData/ROOT/root/tutorials/460: No such file or directory.
Attaching to process 460.
Reading symbols for shared libraries . done
Reading symbols for shared libraries … done
0x90029a67 in wait4 ()

========== STACKS OF ALL THREADS ==========

Thread 1 (process 460 thread 0xd03):
#0 0x90029a67 in wait4 ()
#1 0x90046d9b in system ()
#2 0x011196c1 in TUnixSystem::StackTrace ()
#3 0x0111cc2d in TUnixSystem::DispatchSignals ()
#4 0x0111cd61 in SigHandler ()
#5
#6 0x00484373 in TGraphSmooth::Smoothin ()
#7 0x0048488a in TGraphSmooth::SmoothKern ()
#8 0x005b77c7 in G__G__Graf2_284_0_4 ()
#9 0x01c0f88b in Cint::G__ExceptionWrapper ()
#10 0x01d0434e in G__call_cppfunc ()
#11 0x01cea7df in G__interpret_func ()
#12 0x01cdbca0 in G__getfunction ()
#13 0x01d9ae2e in G__getstructmem ()
#14 0x01d922c2 in G__getvariable ()
#15 0x01c8e66c in G__getitem ()
#16 0x01c91888 in G__getexpr ()
#17 0x01c9f0ca in G__getexpr ()
#18 0x01d2b5b6 in G__exec_statement ()
#19 0x01ceb78a in G__interpret_func ()
#20 0x01cdbf84 in G__getfunction ()
#21 0x01c8e7c8 in G__getitem ()
#22 0x01c91888 in G__getexpr ()
#23 0x01caaa10 in G__calc_internal ()
#24 0x01d3bba3 in G__process_cmd ()
#25 0x010c6c9e in TCint::ProcessLine ()
#26 0x0100ff02 in TApplication::ProcessFile ()
#27 0x0100ce25 in TApplication::ProcessLine ()
#28 0x00036134 in TRint::HandleTermInput ()
#29 0x0003591b in TTermInputHandler::Notify ()
#30 0x0004ed62 in TTermInputHandler::ReadNotify ()
#31 0x0111cf60 in TUnixSystem::CheckDescriptors ()
#32 0x0111d690 in TUnixSystem::DispatchOneEvent ()
#33 0x010811c9 in TSystem::InnerLoop ()
#34 0x0108116d in TSystem::Run ()
#35 0x0100c210 in TApplication::Run ()
#36 0x00036607 in TRint::Run ()
#37 0x00002c1f in main ()
Root > Function motorcycle() busy flag cleared

ad 2, FC4:
root [0] .x graphs/motorcycle.C

*** Break *** segmentation violation
(no debugging symbols found)
Using host libthread_db library “/lib/libthread_db.so.1”.
Attaching to program: /proc/29705/exe, process 29705
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
[Thread debugging using libthread_db enabled]
[New Thread -1208493600 (LWP 29705)]
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
(no debugging symbols found)…done.
0x00a8d402 in ?? ()
#1 0x04de27c3 in __waitpid_nocancel () from /lib/libc.so.6
#2 0x04d8b09f in do_system () from /lib/libc.so.6
#3 0x007812f9 in system () from /lib/libpthread.so.0
#4 0x00d2a01f in TUnixSystem::Exec () from /home/Rabbitus/ROOT/root/lib/libCore.so
#5 0x00d31230 in TUnixSystem::StackTrace () from /home/Rabbitus/ROOT/root/lib/libCore.so
#6 0x00d3060d in TUnixSystem::DispatchSignals ()
from /home/Rabbitus/ROOT/root/lib/libCore.so
#7 0x00d3079b in SigHandler () from /home/Rabbitus/ROOT/root/lib/libCore.so
#8 0x00d2ae94 in sighandler () from /home/Rabbitus/ROOT/root/lib/libCore.so
#9
#10 0x008a04bf in TGraphSmooth::Smoothin () from /home/Rabbitus/ROOT/root/lib/libGraf.so
#11 0x008a091f in TGraphSmooth::SmoothKern () from /home/Rabbitus/ROOT/root/lib/libGraf.so
#12 0x00966940 in G__G__Graf2_284_0_4 () from /home/Rabbitus/ROOT/root/lib/libGraf.so
#13 0x0014acdb in Cint::G__ExceptionWrapper () from /home/Rabbitus/ROOT/root/lib/libCint.so
#14 0x002038d8 in G__call_cppfunc () from /home/Rabbitus/ROOT/root/lib/libCint.so
#15 0x001ee409 in G__interpret_func () from /home/Rabbitus/ROOT/root/lib/libCint.so
#16 0x001e3fc6 in G__getfunction () from /home/Rabbitus/ROOT/root/lib/libCint.so
#17 0x0026e029 in G__getstructmem () from /home/Rabbitus/ROOT/root/lib/libCint.so
#18 0x002660d5 in G__getvariable () from /home/Rabbitus/ROOT/root/lib/libCint.so
#19 0x001c47d9 in G__getitem () from /home/Rabbitus/ROOT/root/lib/libCint.so
#20 0x001cf577 in G__getexpr () from /home/Rabbitus/ROOT/root/lib/libCint.so
#21 0x001ceb22 in G__getexpr () from /home/Rabbitus/ROOT/root/lib/libCint.so
#22 0x00222d40 in G__exec_statement () from /home/Rabbitus/ROOT/root/lib/libCint.so
#23 0x001efcda in G__interpret_func () from /home/Rabbitus/ROOT/root/lib/libCint.so
#24 0x001e47ad in G__getfunction () from /home/Rabbitus/ROOT/root/lib/libCint.so
#25 0x001c4890 in G__getitem () from /home/Rabbitus/ROOT/root/lib/libCint.so
#26 0x001cf577 in G__getexpr () from /home/Rabbitus/ROOT/root/lib/libCint.so
#27 0x001d15fa in G__calc_internal () from /home/Rabbitus/ROOT/root/lib/libCint.so
#28 0x0022b6f8 in G__process_cmd () from /home/Rabbitus/ROOT/root/lib/libCint.so
#29 0x00c94562 in TCint::ProcessLine () from /home/Rabbitus/ROOT/root/lib/libCore.so
#30 0x00c9196d in TCint::ProcessLineSynch () from /home/Rabbitus/ROOT/root/lib/libCore.so
#31 0x00bc31d0 in TApplication::ProcessFile () from /home/Rabbitus/ROOT/root/lib/libCore.so
#32 0x00bc0608 in TApplication::ProcessLine () from /home/Rabbitus/ROOT/root/lib/libCore.so
#33 0x007271e9 in TRint::HandleTermInput () from /home/Rabbitus/ROOT/root/lib/libRint.so
#34 0x00726916 in TTermInputHandler::Notify () from /home/Rabbitus/ROOT/root/lib/libRint.so
#35 0x0072872c in TTermInputHandler::ReadNotify ()
from /home/Rabbitus/ROOT/root/lib/libRint.so
#36 0x00d308d1 in TUnixSystem::CheckDescriptors ()
from /home/Rabbitus/ROOT/root/lib/libCore.so
#37 0x00d30b58 in TUnixSystem::DispatchOneEvent ()
from /home/Rabbitus/ROOT/root/lib/libCore.so
#38 0x00c43f24 in TSystem::InnerLoop () from /home/Rabbitus/ROOT/root/lib/libCore.so
#39 0x00c43eca in TSystem::Run () from /home/Rabbitus/ROOT/root/lib/libCore.so
#40 0x00bbfa47 in TApplication::Run () from /home/Rabbitus/ROOT/root/lib/libCore.so
#41 0x00727671 in TRint::Run () from /home/Rabbitus/ROOT/root/lib/libRint.so
#42 0x08048d9c in main ()
Root > Function motorcycle() busy flag cleared

Best regards
Christian

You must run this tutorial in the graphs directory

Rene

Dear Rene

Thank you, now it works.
It is strange that the following tutorials work w/o changing the directory:

root [0] .x graphs/exclusiongraph.C
root [1] .x graphs/exclusiongraph2.C
root [2] .x graphs/graphpolar.C
root [3] .x graphics/basic3d.C
root [4] .q

Best regards
Christian

In the CVs version, I have modified this tutorial such that it can be executed from any directory.

Rene

Thank you
Christian