Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

Commit

Permalink
Merge branch 'fix/#53-use-exclusive-lock-on-merged-config-write-race-…
Browse files Browse the repository at this point in the history
…condition-prevention'

Close #53
  • Loading branch information
Ocramius committed Feb 20, 2017
2 parents f22ec38 + 9287bd9 commit 2ab9a42
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ All notable changes to this project will be documented in this file, in reverse

### Fixed

- Nothing.
- [#53](https://github.com/zendframework/zend-modulemanager/pull/53) preventing race conditions
when writing cache files (merged configuration)

## 2.7.2 - 2016-05-16

Expand Down
2 changes: 1 addition & 1 deletion src/Listener/AbstractListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public function setOptions(ListenerOptions $options)
protected function writeArrayToFile($filePath, $array)
{
$content = "<?php\nreturn " . var_export($array, 1) . ';';
file_put_contents($filePath, $content);
file_put_contents($filePath, $content, LOCK_EX);
return $this;
}
}

0 comments on commit 2ab9a42

Please sign in to comment.