https://bugzilla.wikimedia.org/show_bug.cgi?id=41244
Web browser: ---
Bug #: 41244
Summary: Revision::getContentInternal() is not handling text
load failure properly
Product: MediaWiki
Version: unspecified
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: ContentHandler
AssignedTo: [email protected]
ReportedBy: [email protected]
Classification: Unclassified
Mobile Platform: ---
In that function, it calls $this->loadText() to load text. In loadText(), it
calls self::getRevisionText() and it's said to "@return String: text the text
requested or false on failure". When loading of text fails, loadText() returns
false, then false is passed to $handler->unserializeContent(), causing
exception "TextContent expects a string in the constructor."
TextContent expects a string in the constructor.
Backtrace:
#0
/home/liangent/code/gerrit/mediawiki/core/includes/content/WikitextContent.php(8):
TextContent->__construct(false, 'wikitext')
#1
/home/liangent/code/gerrit/mediawiki/core/includes/content/ContentHandler.php(1185):
WikitextContent->__construct(false)
#2 /home/liangent/code/gerrit/mediawiki/core/includes/Revision.php(979):
WikitextContentHandler->unserializeContent(false, 'text/x-wiki')
#3 /home/liangent/code/gerrit/mediawiki/core/includes/Revision.php(921):
Revision->getContentInternal()
#4 /home/liangent/code/gerrit/mediawiki/core/includes/Revision.php(897):
Revision->getContent(1, NULL)
#5
/home/liangent/code/gerrit/mediawiki/core/extensions/Wikipedia/classes/WikipediaHooks.php(273):
Revision->getText()
...
--
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l