Page MenuHomePhabricator

thumb.php uses hook ExtractThumbParameters instead of the relavent MediaHandler::parseParamString
Closed, ResolvedPublic


thump.php seems to use its own hook for parsing image param string (Introduced dcbe8e7dd3), instead of using the media handlers parseParamString method. This is confusing, and I'm not sure why it does this.

Version: 1.22.0
Severity: normal



Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 1:53 AM
bzimport set Reference to bz49629.
bzimport added a subscriber: Unknown Object (MLST).

At the moment, wfExtractThumbParams() just takes a string and then does stuff to that string -- it's very lightweight. I guess that's why they didn't go for fancy MIME detection/object instantiation which might be memory intensive.

Also, the Apache code for redirecting requests for non-existent thumbs to thumb.php will need to be adjusted; AFAIK at the moment it includes a manual list of permutations.

...or maybe not, if that's what does. Not sure to be honest, bit out of my depth.

Related URL: (Gerrit Change I3e703c84ff84e30d8b96acf491318829767eb2ab)

Related URL: (Gerrit Change I43a0e7d6f0e45536e4e24b72140157791f5f027f)

Change 69027 merged by jenkins-bot:
Make thumb_handler.php use MediaHandler::parseParamString

Gilles raised the priority of this task from Medium to Unbreak Now!.Dec 4 2014, 10:25 AM
Gilles moved this task from Untriaged to Done on the Multimedia board.
Gilles lowered the priority of this task from Unbreak Now! to Medium.Dec 4 2014, 11:21 AM