Successful copy attempt.
Copy attempt failes with a list of warnings and an COM_TEMPLATES_OVERRIDE_FAILED error
JFile: :copy(/html/components/[...].php, /html/templates/[...].php): copy(/html//templates/[...].php): failed to open stream: No such file or directory
Please note the double slash between "html" and "templates" on the "output" side.
Einstellung | Wert |
---|---|
PHP erstellt für | Linux s1051 2.6.32.63-kvm-32cpu-04 #4 SMP Mon Oct 6 11:56:55 CEST 2014 x86_64 |
Datenbankversion | 5.6.20 |
Datenbankzeichensatz | utf8_general_ci |
PHP-Version | 5.6.2 |
Webserver | Apache |
PHP-Interface für den Webserver | cgi-fcgi |
Joomla!-Version | Joomla! 3.4.3 Stable [ Ember ] 2-July-2015 16:00 GMT |
Joomla!-Plattform-Version | Joomla Platform 13.1.0 Stable [ Curiosity ] 24-Apr-2013 00:00 GMT |
Browsererkennung | Mozilla/5.0 (Windows NT 6.1; WOW64; rv:39.0) Gecko/20100101 Firefox/39.0 |
JStream::_getFilename (line 1391 and str_1401) does a simple str_replace on $filename to eliminate JPATH_ROOT thus removing all parts of $filename which resemble JPATH_ROOT.
$filename = str_replace(JPATH_ROOT, '', $filename);
should be replaced with something like this:
$pos = strpos($filename, JPATH_ROOT);
if ($pos !== false) {
$filename = substr_replace($filename, '', $pos, strlen(JPATH_ROOT));
}
so that only the first occurrence gets replaced. This error probably affects any file system operation such as module updates, too.
As we have a fix created for the upstream library I am going to close this here.
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2015-07-29 08:34:27 |
Closed_By | ⇒ | brianteeman |
I confirmed this issue by writing a unit test.
Proposed fix fixes the problem. Checkout following url for reference
https://github.com/joomla-framework/filesystem/pull/14/files
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/7558.