Re: solution but ... for [ROOT] G__unloadfile() in macro

From: Andreas Salzburger (Andreas.Salzburger@cern.ch)
Date: Thu Sep 19 2002 - 18:06:47 MEST


dear rene,

during preparing a running macro for you, i suddenly realized that this
macro does not fail. i write this mail to let the others participate of my
experience.
a small 'diff oldmacro.C newmacro.D' showed me one thing:
the only lines that were different (as i changed them) were those that
handled the file input output and the creation of the gif-files i create
for each fit.
in the old version i took the absolute path, so f.e.

theCanvas->SaveAs("/afs/cern.ch/user/s/salzburg/thisisthedirectory/keepcalm/theGif.gif");

in the version i wanted to create for you with the intention to place it
in my public directory, i replaced this by

theCanvas->SaveAs("keepwhatever/theGif.gif");

so i did for the files i opened/wrote by fstream.

suddenly the macro worked well!

a cross check by replacing the filenames in the oldversion with relative
links, such as

theCanvas->SaveAs("../../keepalive/theGif.gif");

let the G__unload() problem disappear in the oldversion as well.

so far, MY problem is solved (as it works just fine right now)
but probably there's something going wrong when declaring
/afs/-directories ...

best regards and keep rooting

andreas



On Thu, 19 Sep 2002, Rene Brun wrote:

> Hi Andreas,
> 
> Could you send a running macro that reproduces this problem?
> Which version of ROOT are you using? on which system?
> 
> Rene Brun
> 
> On Thu, 19 Sep 2002, Andreas Salzburger wrote:
> 
> > dear roottalker,
> > 
> > after some time when i tried to solve accuring problems by myself
> > (otherwise i usually tend to turn lazy by just sending requests to some
> > others), i really need to take the help of our root-talk-community.
> > 
> > I've written a macro which takes severall histograms, fits them and writes
> > the fitvalues into various asci-files via ofstream.
> > the macro works fine, datafiles are produced as i want them to be, but
> > when i try to quit root i get this
> > 
> > G__unloadfile() in macro  ... message.
> > 
> > I browsed the archive of ROOTTALK found some familiar problems, but not
> > such a similar one that i could get it out on my own ...
> > 
> > anyone a hint for me?
> > 
> > thanks,
> > andi
> > 
> 
> 



This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:51:10 MET