How to invoke gSystem.RedirectOutput(0)

I need to call gSystem.RedirectOutput(0)
root.cern.ch/root/html532/TSyste … rectOutput

[quote]Redirect standard output (stdout, stderr) to the specified file.
If the file argument is 0 the output is set again to stderr, stdout.[/quote]

I got:
the direct invocation of

gSystem.RedirectOutput(0) ends up with

< Int_t TUnixSystem::RedirectOutput(const char* name, const char* mode = "a", RedirectHandle_t* h = 0) => could not convert argument 1 (expected string or Unicode object, int found) >

the statement gSystem.RedirectOutput(string_at(0)) crashes the application with seg.fault

Please, advise ](*,)

             Thank you.

Hi,

that’s not going to work (only non-const char*'s are enabled to work as byte buffers from python). Simply let the C++ side handle this re-interpretation of NULL as a const char*: ROOT.gROOT.ProcessLine("gSystem->RedirectOutput(0);")
Cheers,
Wim

Great :bulb: =D> Thank you :smiley: