~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/lockdir.py

  • Committer: Tarmac
  • Author(s): Vincent Ladeuil
  • Date: 2017-01-30 14:42:05 UTC
  • mfrom: (6620.1.1 trunk)
  • Revision ID: tarmac-20170130144205-r8fh2xpmiuxyozpv
Merge  2.7 into trunk including fix for bug #1657238 [r=vila]

Show diffs side-by-side

added added

removed removed

Lines of Context:
98
98
but helps protect against colliding host names.
99
99
"""
100
100
 
 
101
from __future__ import absolute_import
 
102
 
101
103
 
102
104
# TODO: We sometimes have the problem that our attempt to rename '1234' to
103
105
# 'held' fails because the transport server moves into an existing directory,
107
109
# the existing locking code and needs a new format of the containing object.
108
110
# -- robertc, mbp 20070628
109
111
 
110
 
import errno
111
112
import os
112
113
import time
113
114
 
857
858
    as it gives some clue who the user is.
858
859
    """
859
860
    try:
860
 
        return config.GlobalConfig().username()
 
861
        return config.GlobalStack().get('email')
861
862
    except errors.NoWhoami:
862
863
        return osutils.getuser_unicode()