Strange problem

Hello! Until 4 days ago I was able to run the follwing application:

int main(int argc, char **argv) { // Main application starts here looping.

TApplication theApp("App", &argc, argv);
gMOOD=new TMMainFrame(gClient->GetRoot(), 700, 300);


At the moment I get this error: (probably because gClient=0)

*** Break *** segmentation violation
Generating stack trace…
0x011898b8 in TGClient::GetRoot() const + 0x6 from /opt/root/new/lib/
0x08078a44 in main + 0x46 from ./mood.executable
0x07206e23 in __libc_start_main + 0xd3 from /lib/tls/
0x080788b9 in TApplicationImp::ShowMembers(TMemberInspector&, char*) + 0x51 from ./mood.executable
/afs/ line 2: 1784 Aborted ./mood.executable

I am using SLC403 and root5.10. I recompiled root after rebooting the system recently because xorg got updated and thought that this wsa maybe causing this. Any ideas?


What is TMMainFrame ?, gMOOD ?


gMOOD is a pointer to TMMainFrame and TMMainFrame inherits from TGMainFrame. The strange thing is that gClient=0. Is this the expected behaviour after TApplication constructor? I didn’t check earlier but this worked with not any problem so I presume gClient was not 0 then.

Hello again! OK with the help of Bertrand Bellenot the problem is solved. The thing is that a few days ago I tried to use Qt as ROOT Gui by changing the corresponding entries in .rootrc from “native” to “qt”. Anw I thought that this is the only thing need (ROOT is compiled with qt support). However I dont see any difference on the normal root gui and apparenlty for some reason gClient=0 after TApplication on my current setup. Maybe I will investigate in the future if this remains the case provided that qt runs correctly on my machine. In the meantime, “native” works as usual and gClient!=0. Thanks,