Last modified: 2010-10-18 21:25:01 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T27546, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 25546 - Call to finfo_file fails on windows systems
Call to finfo_file fails on windows systems
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
ResourceLoader (Other open bugs)
1.17.x
All Windows 7
: Normal major (vote)
: ---
Assigned To: Trevor Parscal
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-10-16 23:24 UTC by Stefan Harwarth
Modified: 2010-10-18 21:25 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Stefan Harwarth 2010-10-16 23:24:01 UTC
On Windows systems the call to finfo_file in CSSMin.php fails because of the relative path that is passed as argument.

According to http://drupal.org/node/288811 the path must be passed through realpath for finfo_file to work.

Changing line 563 to the following cures the bug on windows:
$type = finfo_file( finfo_open( FILEINFO_MIME_TYPE ), realpath( $file ) );
Comment 1 Roan Kattouw 2010-10-18 15:00:17 UTC
Thanks for doing the research and making the fix easy for me!

Fixed in r74946.
Comment 2 Stefan Harwarth 2010-10-18 21:25:01 UTC
You're welcome, but I was confused at first because the exception was only visible when I looked directly at the JS-file with the developertools in Chrome. It would be easier if such exceptions would be presented to the user (if that's possible).

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links