Catch any output to stdout/stderr in a buffer?

Hello,

we call CINT script functions from our C code via G__exec_text("CINT_function()");

Is it possible to previously redirect stdout/stderr of CINT to some memory buffer?

Thanks
      Andreas