HI
I have a logging application wherin I create a ofstream object say,
ofstream logger;
by doing this
logger.open(/* some path*/,ios_base:app);
and then i do some logging by writing to this ofstream object like this
logger << buffer << endl;
here buffer is some string object
now my problem is that how to accurately check for write failure ( for
example in case when disc is full)
I have tried something like this
logger.fail();
& also
logger.bad();
but both these do not return true in case of write failure.i am not
sure if i can use these with o/p stream.
I am sure theres got to be a way but I am a novice in c++ so I need
some help in getting around this problem
thanks
shyam