Add xml inc svg as 'text' file extensions

To prevent situations like in
https://board.s9y.org/viewtopic.php?f=10&t=21591
where the following files were modified by FTP text transfer type but
not handled as such in serendipity_FTPChecksum()

bundled-libs/katzgrau/klogger/phpunit.xml
bundled-libs/simplepie/simplepie.inc
templates/2k11/admin/font/fontello.svg
templates/next/font/fontello.svg

All these *are* text files.

Maybe simplepie.inc should rather be renamed to simplepie.inc.php as well.
This commit is contained in:
Eike Rathke 2017-09-21 18:48:10 +02:00
parent e2a35c3694
commit be3df87b97

View File

@ -1136,6 +1136,9 @@ function serendipity_FTPChecksum($filename, $type = null) {
strcasecmp($ext, 'sh') &&
strcasecmp($ext, 'html') &&
strcasecmp($ext, 'htm') &&
strcasecmp($ext, 'xml') &&
strcasecmp($ext, 'inc') &&
strcasecmp($ext, 'svg') &&
!empty($ext)) {
if (!in_array($ext, array_keys($debug_exts))) {
$debug_exts[$ext] = $filename;