-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
aaron@svn.wikimedia.org wrote:
# Check the text if not in rev_len for the entry's text size
if( !$size ) {
$text = $dbw->selectField( 'text', 'old_text', array('old_id' => $textId ) );
$size = $text ? strlen($text) : 'NULL';
}
This will give incorrect results for compressed text, external storage entries, and batch compression entries.
You need to also fetch old_flags and run the row through the Revision::getRevisionText() function to expand such rows.
- -- brion vibber (brion @ wikimedia.org)