My program is printing a couple of random numbers and characters. It will be from some debugging code I've left hanging around. It's probably been indirectly switched on during something I've recently changed. I have no idea where it's coming from even after some quick greps through my libraries.
How can I easily track down the source of a print call?
(it will be one of printf
or cout <<
)
I'm assuming something similar to gdb
spitting out a stack trace for every write to stdout.
I'll definitely be taking a preventative approach from now on but just interested possible solutions.