Jjanes has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/129109

Change subject: PostgreSQL: decode image.img_metadata
......................................................................

PostgreSQL: decode image.img_metadata

The img_metadata field was not being decoded from bytea into text.

This change fixes the reported problem with PdfHandler against both
master and 1.22.5.

Bug: 59147
Change-Id: I285a317a57a29713af1f7f630b340278bd5400da
---
M includes/filerepo/file/LocalFile.php
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/09/129109/1

diff --git a/includes/filerepo/file/LocalFile.php 
b/includes/filerepo/file/LocalFile.php
index dbf6918..2247364 100644
--- a/includes/filerepo/file/LocalFile.php
+++ b/includes/filerepo/file/LocalFile.php
@@ -386,6 +386,7 @@
                $dbr = $this->repo->getMasterDB();
                $row = $dbr->selectRow( 'image', $this->getCacheFields( 'img_' 
),
                        array( 'img_name' => $this->getName() ), $fname );
+        $row->img_metadata = $dbr->decodeBlob( $row->img_metadata );
 
                if ( $row ) {
                        $this->loadFromRow( $row );

-- 
To view, visit https://gerrit.wikimedia.org/r/129109
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I285a317a57a29713af1f7f630b340278bd5400da
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Jjanes <jeff.ja...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to