/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/strace.py

  • Committer: Jelmer Vernooij
  • Date: 2018-11-16 23:19:12 UTC
  • mfrom: (7180 work)
  • mto: This revision was merged to the branch mainline in revision 7294.
  • Revision ID: jelmer@jelmer.uk-20181116231912-e043vpq22bdkxa6q
Merge trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
 
45
45
    # capture strace output to a file
46
46
    log_file = tempfile.NamedTemporaryFile()
47
 
    log_file_fd = log_file.fileno()
48
47
    err_file = tempfile.NamedTemporaryFile()
49
48
    pid = os.getpid()
50
49
    # start strace
57
56
                            stdout=subprocess.PIPE,
58
57
                            stderr=err_file.fileno())
59
58
    # Wait for strace to attach
60
 
    attached_notice = proc.stdout.readline()
 
59
    proc.stdout.readline()
61
60
    # Run the function to strace
62
61
    result = function(*args, **kwargs)
63
62
    # stop strace
78
77
 
79
78
 
80
79
class StraceError(errors.BzrError):
81
 
    
 
80
 
82
81
    _fmt = "strace failed: %(err_messages)s"
83
82
 
84
83
 
92
91
        """
93
92
        self.raw_log = raw_log
94
93
        self.err_messages = err_messages
95
 
 
96