Home interception and processing of stdout
Reply: 0

interception and processing of stdout

Ivan
1#
Ivan Published in 2018-01-12 11:20:41Z

I have a task to make some kind of logger application and integrate it in source code of already existing programm on linux.
There are lots of std::cout in it. So, I need to intercept them, add information like name of function from which it was called and send all of this to log function. There are several threads already and I want to avoid creating another one.

Main question: "how can I bind cout call to log function call whithout changing all source code? I need to get final string from cout and send it to logger."

So I'll be glad to get any information, suggestion, ideas and advices. Thank you.

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.310711 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO