dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(from parent 1:
49f7305
)
Merge "(Bug 45355) Read of arbitrary files through mwdoc-filter.php"
author
jenkins-bot
<jenkins-bot@gerrit.wikimedia.org>
Mon, 4 Mar 2013 19:43:11 +0000
(19:43 +0000)
committer
Gerrit Code Review
<gerrit@wikimedia.org>
Mon, 4 Mar 2013 19:43:11 +0000
(19:43 +0000)
maintenance/mwdoc-filter.php
patch
|
blob
|
history
diff --git
a/maintenance/mwdoc-filter.php
b/maintenance/mwdoc-filter.php
index
ab05a3e
..
6eeb48d
100644
(file)
--- a/
maintenance/mwdoc-filter.php
+++ b/
maintenance/mwdoc-filter.php
@@
-11,6
+11,10
@@
* @file
*/
+if ( PHP_SAPI != 'cli' ) {
+ die( "This filter can only be run from the command line.\n" );
+}
+
$source = file_get_contents( $argv[1] );
$regexp = '#\@var\s+([^\s]+)([^/]+)/\s+(var|public|protected|private)\s+(\$[^\s;=]+)#';
$replac = '${2} */ ${3} ${1} ${4}';