diff options
author | xue <> | 2006-08-05 21:34:30 +0000 |
---|---|---|
committer | xue <> | 2006-08-05 21:34:30 +0000 |
commit | b7f95ce37ae577e95a81e64aa2aaf3e2e698109d (patch) | |
tree | 85c6b9961ebbd4c9283fbd9b841703f9e4c47307 /framework/I18N/core | |
parent | 550ba06593b467b643862d41a00ca2dd12ee704b (diff) |
merge from 3.0 branch till 1329.
Diffstat (limited to 'framework/I18N/core')
-rw-r--r-- | framework/I18N/core/Gettext/MO.php | 1 | ||||
-rw-r--r-- | framework/I18N/core/Gettext/PO.php | 1 | ||||
-rw-r--r-- | framework/I18N/core/MessageSource_XLIFF.php | 7 | ||||
-rw-r--r-- | framework/I18N/core/MessageSource_gettext.php | 6 |
4 files changed, 13 insertions, 2 deletions
diff --git a/framework/I18N/core/Gettext/MO.php b/framework/I18N/core/Gettext/MO.php index 5ee0057f..9f2d5799 100644 --- a/framework/I18N/core/Gettext/MO.php +++ b/framework/I18N/core/Gettext/MO.php @@ -349,6 +349,7 @@ class TGettext_MO extends TGettext // done
@flock($this->_handle, LOCK_UN);
@fclose($this->_handle);
+ chmod($file,0777);
return true;
}
}
diff --git a/framework/I18N/core/Gettext/PO.php b/framework/I18N/core/Gettext/PO.php index 015747a0..3a5fda04 100644 --- a/framework/I18N/core/Gettext/PO.php +++ b/framework/I18N/core/Gettext/PO.php @@ -154,6 +154,7 @@ class TGettext_PO extends TGettext //done
@flock($fh, LOCK_UN);
@fclose($fh);
+ chmod($file,0777);
return true;
}
}
diff --git a/framework/I18N/core/MessageSource_XLIFF.php b/framework/I18N/core/MessageSource_XLIFF.php index 2194ca41..7f2f27c5 100644 --- a/framework/I18N/core/MessageSource_XLIFF.php +++ b/framework/I18N/core/MessageSource_XLIFF.php @@ -473,10 +473,15 @@ class MessageSource_XLIFF extends MessageSource $variant = array_shift($variants);
$file = $this->getSource($variant);
$dir = dirname($file);
- if(!is_dir($dir)) @mkdir($dir);
+ if(!is_dir($dir))
+ {
+ @mkdir($dir);
+ @chmod($dir,0777);
+ }
if(!is_dir($dir))
throw new TException("Unable to create directory $dir");
file_put_contents($file, $this->getTemplate($catalogue));
+ chmod($file, 0777);
return array($variant, $file);
}
diff --git a/framework/I18N/core/MessageSource_gettext.php b/framework/I18N/core/MessageSource_gettext.php index 78fa5259..c92577d4 100644 --- a/framework/I18N/core/MessageSource_gettext.php +++ b/framework/I18N/core/MessageSource_gettext.php @@ -431,7 +431,11 @@ class MessageSource_gettext extends MessageSource $po_file = $this->getPOFile($mo_file);
$dir = dirname($mo_file);
- if(!is_dir($dir)) @mkdir($dir);
+ if(!is_dir($dir))
+ {
+ @mkdir($dir);
+ @chmod($dir,0777);
+ }
if(!is_dir($dir))
throw new TException("Unable to create directory $dir");
|