dont apply callback wrapper when fopen failed

This commit is contained in:
Robin Appelman 2015-05-13 14:07:18 +02:00
parent 1270c6800d
commit 2d63fd77de
1 changed files with 1 additions and 1 deletions

View File

@ -988,7 +988,7 @@ class View {
$this->updater->update($path, $extraParam);
}
if ($operation === 'fopen') {
if ($operation === 'fopen' and $result) {
$result = CallbackWrapper::wrap($result, null, null, function () use ($hooks, $path) {
if (in_array('write', $hooks)) {
$this->unlockFile($path, ILockingProvider::LOCK_EXCLUSIVE);