]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix bug when reporting error
authorGuido van Rossum <guido@python.org>
Thu, 10 Dec 1992 00:01:24 +0000 (00:01 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 10 Dec 1992 00:01:24 +0000 (00:01 +0000)
Tools/scripts/classfix.py
Tools/scripts/fixps.py

index c1842561ec40b81170d37c59f36fd621eabf8607..7ec0e7a44d654b2203ed247bd186ad1a5613a9b0 100755 (executable)
@@ -1,5 +1,5 @@
 #! /ufs/guido/bin/sgi/python
-#! /usr/local/python
+#! /usr/local/bin/python
 
 # Fix Python source files to use the new class definition syntax, i.e.,
 #      class C() = base(), base(), ...: ...
@@ -38,7 +38,7 @@ rep = sys.stdout.write
 def main():
        bad = 0
        if not sys.argv[1:]: # No arguments
-               err('usage: ' + argv[0] + ' file-or-directory ...\n')
+               err('usage: ' + sys.argv[0] + ' file-or-directory ...\n')
                sys.exit(2)
        for arg in sys.argv[1:]:
                if os.path.isdir(arg):
index c5e4cb3efd3be352becf62e84324768524ed88a8..3238c493772b828c4c3b93e3f3f2ec91fb29e300 100755 (executable)
@@ -12,7 +12,7 @@ def main():
                try:
                        f = open(file, 'r+')
                except IOError:
-                       print f, ': can\'t open for update'
+                       print file, ': can\'t open for update'
                        continue
                line = f.readline()
                if regex.match('^#! */usr/local/python', line) < 0: