Patch #26157

Render all possible inline textile images

Added by Holger Just almost 5 years ago. Updated almost 5 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Jean-Philippe Lang% Done:


Category:Text formatting
Target version:3.4.0


In r15433, Redmine introduced a security measure to restrict embedding images to only those with valid schemes from Textile.

Now, if there are multiple images referenced on a page, with only one of them invalid, Redmine currently doesn't create <img> tags for any of them since it would return from the replacement method too soon.

This patch fixes this behavior in that it still allows to embed all valid images and only refuses to embed the invalid ones by skipping the rest of the current gsub iteration instead of the whole method. The patch was extracted from Planio

0001-Render-all-possible-inline-textile-images.patch Magnifier (1.24 KB) Holger Just, 2017-06-13 18:58

26157-expected.png (44.9 KB) Go MAEDA, 2017-06-14 05:38

26157-actual.png (7.21 KB) Go MAEDA, 2017-06-14 05:41

Associated revisions

Revision 16668
Added by Jean-Philippe Lang almost 5 years ago

Render all possible inline textile images even if an invalid one exists (#26157).

Patch by Holger Just.


#1 Updated by Go MAEDA almost 5 years ago

Confirmed the problem. Setting target version to 3.4.0.




Expected (with the patch applied):

Actual (without the patch):

#2 Updated by Jean-Philippe Lang almost 5 years ago

  • Status changed from New to Closed
  • Assignee set to Jean-Philippe Lang

Committed, thanks!

Also available in: Atom PDF