]> granicus.if.org Git - python/commitdiff
When run as a script, don't pass a fake __main__ dictionary; use the
authorGuido van Rossum <guido@python.org>
Thu, 15 Oct 1998 01:38:23 +0000 (01:38 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 15 Oct 1998 01:38:23 +0000 (01:38 +0000)
real one.

Lib/pdb.py

index de769bb87a6b739617269c2f6b82613e77c5ead3..fae6b2c604413bef3c8c010d1393f7243ec3f7ea 100755 (executable)
@@ -893,4 +893,4 @@ if __name__=='__main__':
        # Insert script directory in front of module search path
        sys.path.insert(0, os.path.dirname(filename))
 
-       run('execfile(' + `filename` + ')', {'__name__': '__main__'})
+       run('execfile(' + `filename` + ')')