i am using LD_PRELOAD to capture write() system call in linux . I am successfully able to do this for write system call and make it work.
But when i call printf() that time it does not work. If we observe printf stack trace using strace i found that, at the end printf calls write() system call to write to console, but at that time my write() system call is not called before actually calling the the write() system call.
Anybody have any idea why is this happening ?