mail icon indicating copy to clipboard operation
mail copied to clipboard

Backtrack limit was exhausted with base64 encoded image

Open dakorpar opened this issue 4 years ago • 2 comments

Version: 3.1.5

Bug Description

Whenever there is a bigger base64 encoded image in E-mail we get this exception: image

Steps To Reproduce

It's clear from bug description

Additional

I'm not sure how to even solve this, avoiding Regex if possible would maybe be best since we never know how big e-mail can be and with base64 encoded images this can become huge quickly... I know I can set bigger limit, but then again how much memory will it use and when will we hit it again... Probably only proper solution here would be to add image as attachment and not base64 encoded... I've managed to avoid issue in this particular mail since we're not using any images so I just set basePath as null so it doesn't go into this part of code, but obviously that's not a solution...

dakorpar avatar Dec 28 '20 10:12 dakorpar

As a workaround, don't pass second argument to setHtmlBody() to avoid regexp.

dg avatar Dec 28 '20 10:12 dg

Yeah I did that in this case... Last sentence

dakorpar avatar Dec 28 '20 11:12 dakorpar