~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/trace.py

  • Committer: Robert Collins
  • Date: 2005-09-28 05:25:54 UTC
  • mfrom: (1185.1.42)
  • mto: (1092.2.18)
  • mto: This revision was merged to the branch mainline in revision 1397.
  • Revision ID: robertc@robertcollins.net-20050928052554-beb985505f77ea6a
update symlink branch to integration

Show diffs side-by-side

added added

removed removed

Lines of Context:
101
101
            return
102
102
        old_fname = trace_fname + '.old'
103
103
 
104
 
        try:
105
 
            # must remove before rename on windows
106
 
            os.remove(old_fname)
107
 
        except OSError:
108
 
            pass
 
104
        from osutils import rename
 
105
        rename(trace_fname, old_fname)
109
106
 
110
 
        try:
111
 
            # might fail if in use on windows
112
 
            os.rename(trace_fname, old_fname)
113
 
        except OSError:
114
 
            pass
115
107
    except OSError:
116
108
        return
117
109
 
197
189
    logging.getLogger('').addHandler(_stderr_handler)
198
190
 
199
191
 
200
 
 
201
192
def disable_default_logging():
202
193
    """Turn off default log handlers.
203
194