[BUGFIX] Correct check for extTables script

Existence of the script defined in TYPO3_extTableDef_script is
currently achieved by using file_exists(). This is insufficient
if TYPO3_extTableDef_script is defined, but empty, as
file_exists() will match "typo3conf/" and try to include it.

Resolves: #46161
Releases: 6.0, 6.1
Reviewed-on: https://review.typo3.org/18828
Reviewed-by: Francois Suter
Tested-by: Francois Suter
Change-Id: I9d6694228ca27cb2c446629a90e5c8636705e3e3
Reviewed-on: https://review.typo3.org/18829
[TASK] More descriptive error message on file upload failure

Provide the user with more accurate information about what might have
gone wrong.

Resolves: #46160
Releases: 6.0,6.1
Change-Id: I86123b904f36ff7f6db77f2dd13f97c0a01957c3
Reviewed-on: https://review.typo3.org/18840
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Handle symlink on extension update

If an extension is updated and the extension in the file
system is a symlink to a different directory, all
target directory contents is removed and the update fails.

Introduce a check for symlink and just remove the
symlink in this case.

Resolves: #46158
Releases: 6.1, 6.0
Change-Id: I112ae7192fb0edf77ebd703a61804dc09ca506a4
Reviewed-on: https://review.typo3.org/18842
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[TASK] Make the update-from-TER link more visible

Make the "update from TER"-action in the extension manager more
visible by showing a button for it, instead of a text link.

Also moved the rendering functionality of the update link from
a viewhelper to a partial, as partials tend to be more readable
and bug free.

Resolves: #46029
Releases: 6.1, 6.0
Change-Id: If447bba28bc0dee3e7de286e1a93e062ef59843c
Reviewed-on: https://review.typo3.org/18843
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[TASK] Show better error messages on failed TER update

This patch shows error messages in a flash message if the ajax request
for a TER-update fails, and resets the extension manager into a sane
state, instead of showing an ever spinning wheel.

Resolves: #46030
Releases: 6.1, 6.0
Change-Id: I1cc67460a11feb206c53c12a38ad0f6db482e04a
Reviewed-on: https://review.typo3.org/18844
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Old files of filelist extension are wrong

During the namespace change the old filelist extenion files
are not correctly set. Instead of "filelist" this was replaced
with "file_list".

Fixes: #46155
Related: #45143
Releases: 6.0

Change-Id: I33ebb12163dd30d35981f45dcd465f7340bf1f5a
Reviewed-on: https://review.typo3.org/18845
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[TASK] Raise submodule pointer

Change-Id: I3c75e82765a4903ca34a19e8fac1ac5e2fdd1635
Reviewed-on: https://review.typo3.org/18864
Reviewed-by: TYPO3 Release Team
Tested-by: TYPO3 Release Team
[BUGFIX] inject* methods in FAL inhibit use of Extbase object manager

The ResourceStorage class of FAL has two inject* methods which are seen
as dependency injectors by the Extbase object manager. Thus an exception
is thrown when a ResourceStorage object is created via Extbase.

This commit changes the two method's names and adjust all usages within
the core. These methods are internal and I don't expect them to be used
anywhere else, so we don't need a backwards compatibility layer.

Change-Id: I4b73445708cf8041b505b5ea8923dc595ddaadb0
Resolves: #45319
Releases: 6.1, 6.0
Reviewed-on: https://review.typo3.org/18882
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Exception when deleted file is in clipboard

When a file is deleted while it is part of a clipboard, an exception is
thrown when the clipboard is reconstituted. This exception has to be
catched, otherwise the file module will be unusable.

Change-Id: I8849644ffa7b78559c1797d85ce3cc6e01d03a74
Resolves: #43906
Releases: 6.1, 6.0
Reviewed-on: https://review.typo3.org/18884
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Translation of a form makes the form wizard unusable

As soon as the form-configuration for the form wizard gets
loaded, the leading "[Translate to XYZ:] " is stripped off to get the
wizard working (with the leading text, the form config could not
be serialized as needed and the wizard didn't show a single field).

The stripping is only done on localized records.

Change-Id: I0cab1d371abf5ae01b524c39acedcd1a3a5db9c4
Fixes: #39127
Releases: 4.7, 6.0, 6.1
Reviewed-on: https://review.typo3.org/18887
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Numeric translation keys aren't translated right in XML files

When working with the "old" XML based translation files,
numeric keys aren't translated properly.
The reason is, that LocallangXmlParser uses array_merge to combine the
translation arrays of the default language and the current language.
array_merge renumbers numeric keys. Therefore, numeric key in
translation files result in wrong translations in Frontend.

Fixes: #44626
Releases: 6.0, 6.1
Change-Id: I8fdff385f681428b4cb5a3e994828a4a29305c98
Reviewed-on: https://review.typo3.org/18211
Reviewed-by: Reinhard Führicht
Tested-by: Reinhard Führicht
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Toolbar items with separator: fix white-space

The toolbar function could output erroneous html is case
additional toolbar items do not bring additionalAttributes.

Additional attributes are defined based on ToolbarItemHookInterface.
But additionalAttributes can be an empty string:

Fix output <liclass="separator"> to <li class="separator">
by adding an extra white-space.

Change-Id: I09338d17848c8fc74b25e7c532d6ee329956321b
Fixes: #45795
Releases: 6.0, 6.1
Reviewed-on: https://review.typo3.org/18892
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Add .htaccess file to ext:extensionmanager/Resources/Private

Change-Id: I7ada1e5e40067cf1faed8b2b5d338a690e921cad
Fixes: #46264
Releases: 6.1, 6.0
Reviewed-on: https://review.typo3.org/18898
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Skip unreliable APC test on PHP versions below 5.3.4

APC has some slam protection that tries to prevent hammering of cache
entries. This can be disabled, but the option does not work at least
in native PHP 5.3.3 on debian squeeze. While it is no problem with
higher PHP version like the current one on travis-ci.org,
some tests are now just skipped on PHP environments knows for issues.

Change-Id: Ibbef201805b58041bb0b3e8aa16f0c1a2e366020
Resolves: #46267
Release: 6.1, 6.0
Reviewed-on: https://review.typo3.org/18902
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] LanguageController has "mixed" type annotations

The LanguageController of the lang sysext throws
exceptions if the rewritten property mapper is enabled.
The type annotation 'mixed' is unknown. The patch fixed
the annotation to the correct string value to make the
property mapper happy.

Change-Id: I57ebd268d2fe82c095ccf20b581e721703fb2868
Fixes: #44672
Releases: 6.1, 6.0
Reviewed-on: https://review.typo3.org/18920
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[TASK] Raise submodule pointer

Change-Id: I64d97afc42424a0f6233fe645453f48c863c671c
Reviewed-on: https://review.typo3.org/18932
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
Revert "[BUGFIX] Fix wrong column title in web>list for field colpos"

This reverts commit 765ebd0cd992b86f8002f932bb51b2a39c0ace99

The patch triggers warnings and errors in multiple extensions. Digging
into the details shows the implementation is neither finished nor
stable. See issue #25113 for a detailed analysis.

Change-Id: I1ff1ea11feb34c71d3ee42789c3deda130aa9a0e
Related: #25113
Fixes: #45833
Releases: 6.1, 6.0, 4.7, 4.6, 4.5
Reviewed-on: https://review.typo3.org/18942
Reviewed-by: Ernesto Baschny
Tested-by: Ernesto Baschny
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGIFX] Extra output block backend thumbnails

If some inclusion causes output when viewing image thumbnails
in the backend, the output will be broken. Adding a call to
ob_clean() ensures that this does not happen.

Resolves: #31953
Releases: 6.1, 6.0
Change-Id: I1d33bc3c5e8bbd1851f087c76564f8924f8dfe26
Reviewed-on: https://review.typo3.org/18959
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[BUGFIX] Importing extensions from repository fails

If importing the extension list from TER, an incoming XML extension
row has a field 'category' that contains either a string like
'plugin' or a category number.
The list is persisted to the 'extension' repository. In the
database, the category is stored as integer. There is a mapping
function in the extension model to get the integer category
index from given XML input. The method is faulty and returns
strings instead of an index if the given category is a string
itself. This results in database errors during insert.

The patch fixes the method, renames it along the way and adds
unit tests to document desired behavior.

Change-Id: I601b84d0829f3d20a4cdd25a3f7f37e8128dbce1
Fixes: #46115
Releases: 6.1, 6.0
Reviewed-on: https://review.typo3.org/18962
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
[TASK] Raise submodule pointer

Change-Id: Id68b495581b7ee0bff119031fd24dd01c4a1a5b8
Reviewed-on: https://review.typo3.org/18964
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn