Legoktm has uploaded a new change for review.

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

Change subject: dumpURLs: Improve error message if the file isn't writable
......................................................................

dumpURLs: Improve error message if the file isn't writable

Change-Id: I051ac64a6022c42f8414b89da38e530cf6a158f5
---
M maintenance/dumpURLs.php
1 file changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/UrlShortener 
refs/changes/94/277894/1

diff --git a/maintenance/dumpURLs.php b/maintenance/dumpURLs.php
index e0a0d84..7ebee66 100644
--- a/maintenance/dumpURLs.php
+++ b/maintenance/dumpURLs.php
@@ -24,6 +24,9 @@
                $file = $this->getArg( 0 );
                $this->output( "Writing to $file...\n" );
                $handle = fopen( $file, 'w' );
+               if ( $handle === false ) {
+                       $this->error( "Error opening $file. Check 
permissions?", 1 );
+               }
                $id = 0;
                do {
                        $text = '';

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I051ac64a6022c42f8414b89da38e530cf6a158f5
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/UrlShortener
Gerrit-Branch: master
Gerrit-Owner: Legoktm <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to