Closed (fixed)
Project:
phpBB2Drupal
Version:
6.x-2.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Oct 2009 at 14:30 UTC
Updated:
17 Oct 2009 at 17:50 UTC
Hi,
Apply check for empty bbcode uid to prevent all : (colons) being removed.
Example:
// remove the bbcode_uid from post_text
$topic->post_text = preg_replace("/:$topic->bbcode_uid/", '', $topic->post_text);
If $topic->bbcode_uid is empty, then all colons are removed, fx in http:// -> http// .
So possible fix is this
// remove the bbcode_uid from post_text
if(!empty($topic->bbcode_uid)) {
$topic->post_text = preg_replace("/:$topic->bbcode_uid/", '', $topic->post_text);
}
I found this issue on the following lines; 358, 371, 602, 780
Those line numbers are approx, due to some other bugfixes i have applied in #594876: Various bugfixes for signatures, access time and attachments
Comments
Comment #1
Phliplip commentedThis is also a fix that needs to be applied in the phpbb2privatemsg.module file
Comment #2
naheemsays commentedThanks - I have applied this patch to:
Head: http://drupal.org/cvs?commit=270694
6.x-1.x branch: http://drupal.org/cvs?commit=270704
and Drupal 5 branch (which was accidental): http://drupal.org/cvs?commit=270696