Mercurial > hg
changeset 4956:02b127749dc0
fix unused variables reported by pychecker
author | Benoit Boissinot <benoit.boissinot@ens-lyon.org> |
---|---|
date | Fri, 20 Jul 2007 09:31:32 +0200 |
parents | 9bbc0217209b |
children | cdd33a048289 |
files | mercurial/changelog.py mercurial/commands.py mercurial/util.py |
diffstat | 3 files changed, 2 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/changelog.py Thu Jul 19 18:39:51 2007 +0200 +++ b/mercurial/changelog.py Fri Jul 20 09:31:32 2007 +0200 @@ -58,7 +58,6 @@ def read(self, count=-1): '''only trick here is reads that span real file and data''' ret = "" - old_offset = self.offset if self.offset < self.size: s = self.fp.read(count) ret = s
--- a/mercurial/commands.py Thu Jul 19 18:39:51 2007 +0200 +++ b/mercurial/commands.py Fri Jul 20 09:31:32 2007 +0200 @@ -8,7 +8,7 @@ import demandimport; demandimport.enable() from node import * from i18n import _ -import bisect, os, re, sys, urllib, shlex, stat +import bisect, os, re, sys, urllib, stat import ui, hg, util, revlog, bundlerepo, extensions import difflib, patch, time, help, mdiff, tempfile import errno, version, socket @@ -2197,7 +2197,6 @@ Modified files and added files are not removed by default. To remove them, use the -f/--force option. """ - names = [] if not opts['after'] and not pats: raise util.Abort(_('no files specified')) files, matchfn, anypats = cmdutil.matchpats(repo, pats, opts) @@ -2659,7 +2658,6 @@ bundle command. """ fnames = (fname1,) + fnames - result = None for fname in fnames: if os.path.exists(fname): f = open(fname, "rb")
--- a/mercurial/util.py Thu Jul 19 18:39:51 2007 +0200 +++ b/mercurial/util.py Fri Jul 20 09:31:32 2007 +0200 @@ -616,7 +616,7 @@ """forcibly rename a file""" try: os.rename(src, dst) - except OSError, err: + except OSError, err: # FIXME: check err (EEXIST ?) # on windows, rename to existing file is not allowed, so we # must delete destination first. but if file is open, unlink # schedules it for delete but does not delete it. rename