[Important] Data Corruption Bug
-
Hello,
I think I found a bug which can lead to data corruption/loss in some situation.
Indeed, the field
link_text
of the tablewp_blc_instances
is set as a VARCHAR with a limit of 250 characters. It should be set as TEXT.Indeed, the problem is that if the inside content of a link is longer than 250 characters, it is saved truncated in this field!
Then, if the link is broken, editing it will lead to a corrupt link in the corresponding post. Indeed, the plugin uses the data saved in the
link_text
field to recreate the correct link and it then replace the old broken one with this new (broken too) one.Example:
If you have a link arround an image, such as this one (307 characters):
<img class="alignnone size-full wp-image-8794" src="https://www.conceptionlumiere.com/uploads/2015/03/Musée-de-la-Moto-–-Architecte-Krummenacher-–-Bureau-d’étude-Kayser-?-Concept-Light.jpg" alt="Musée de la Moto – Architecte Krummenacher – Bureau d’étude Kayser ? Concept Light" width="750" height="496" />
The
link_text
data will be truncated to (250 characters):<img class="alignnone size-full wp-image-8794" src="https://www.conceptionlumiere.com/uploads/2015/03/Musée-de-la-Moto-–-Architecte-Krummenacher-–-Bureau-d’étude-Kayser-?-Concept-Light.jpg" alt="Musée de la Moto – Architecte Krummenacher – Bureau d’é
So, the resulting link in the post will be:
<a href="https://www.conceptionlumiere.com"><img class="alignnone size-full wp-image-8794" src="https://www.conceptionlumiere.com/uploads/2015/03/Musée-de-la-Moto-–-Architecte-Krummenacher-–-Bureau-d’étude-Kayser-?-Concept-Light.jpg" alt="Musée de la Moto – Architecte Krummenacher – Bureau d’é</a>
I reproduced this bug with the latest BLC version and WordPress v4.2.1.
I installed a fresh WordPress, installed BLC and created a post with this the link shown above and bam!
Tristan
- The topic ‘[Important] Data Corruption Bug’ is closed to new replies.