View Single Post
  #32   Spotlight this post!  
Unread 02-04-2010, 01:08 PM
jhersh jhersh is offline
National Instruments
AKA: Joe Hershberger
FRC #2468 (Appreciate)
Team Role: Mentor
 
Join Date: May 2008
Rookie Year: 1997
Location: Austin, TX
Posts: 1,006
jhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond reputejhersh has a reputation beyond repute
Re: ofstream (standard C++ file output) not working

Quote:
Originally Posted by slavik262 View Post
Right, so if it is called before fopen() in the same thread, why would there be a race condition?
You would not. The situation described above (or how I read it anyway) was that you were not calling Priv_SetWriteFileAllowed, and that it sometimes worked. I was suggesting that there are other tasks that may be calling it that would allow the write to work sometimes and not others.

If what you are saying is that you are calling it in the same task before the fopen and it still only works some of the time, then I don't have a good theory for you. Let me know if this is the case and I'll try to look into it a bit more.

-Joe

Last edited by jhersh : 02-04-2010 at 03:21 PM.
Reply With Quote