Versió
4.0-514
Branca
master
Data
Fa 7 anys, 4 mesos
Windows x64 Windows x86 Ubuntu 13.04 Mac OS X
Contribució
eaacf10f7141caaff9f34221bee3a8e5ede636cb
Autor del canvi
comex
Descripció del canvi
Fix an idiotic race condition when starting games in multiple Dolphin instances at the same time on Unix.

MemArena mmaps the emulated memory from a file in order to get the same
mapping at multiple addresses.  A file which, formerly, was located at a
static filename: it was unlinked after creation, but the open did not
use O_EXCL, so if two instances started up on the same system at just
the right time, they would get the same memory.  Naturally, this caused
extremely mysterious crashes, but only in Netplay, where the game is
automatically started when the client receives a broadcast from the
server, so races are actually quite likely.

And switch to shm_open, because it fits the bill better and avoids any
issues with using /tmp.