[quake3-commits] [ioquake/ioq3] 7d012f: Fix a race condition in the makedirs target

Mickaël Thomas mickael9 at gmail.com
Mon Oct 16 11:22:39 EDT 2017

  Branch: refs/heads/master
  Home:   https://github.com/ioquake/ioq3
  Commit: 7d012f229e4b04c21fd1adb9a053cad4f86f8742
  Author: Mickaël Thomas <mickael9 at gmail.com>
  Date:   2017-10-16 (Mon, 16 Oct 2017)

  Changed paths:
    M Makefile

  Log Message:
  Fix a race condition in the makedirs target

A race condition can happen when running "make all" with parallel jobs.

The issue is that the build directory can be created by another
concurrent job between the moment it was detected as missing and the
moment mkdir is called (which fails if the directory already exists).

This fixes the problem by always using `mkdir -p` which doesn't fail if
the directory already exists.

More information about the quake3-commits mailing list