[BUGFIX][Cache][PDO] Duplicate cache entry possible

An identifier must be unique in the database. If some entry is set(),
the PdoBackend removes any entry with a given identifier if the cache
entry exists already. The remove() call is encapsulated with has(),
but has() returns FALSE if a cache entry is expired, so entries with
expired lifetime are not removed properly.
This leads to a \PDOException because of duplicate identifier.

The patch removes the check to has(), so set() will also remove
expired cache entries with this identifier before creating a new one.

Change-Id: Ife4e35223394805fc6d9e0b820a5d42789133f7b
Fixes: #34129
Releases: 6.1, 6.0, 4.7, 4.6, 4.5
Reviewed-on: https://review.typo3.org/18102
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn