The C++11 language standard says it is a race condition and all race conditions are undefined.