mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Use subprocess instead of os.popen3 to avoid deprecation warnings.
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1404 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@ -48,10 +48,11 @@ def get_svn_info(path):
|
||||
rev = 'None'
|
||||
if path[0:4] == 'http' or os.path.exists(path):
|
||||
try:
|
||||
(stream_in, stream_out, stream_err) = os.popen3(svn_exe+' info --xml '+path)
|
||||
err = stream_err.read()
|
||||
p = subprocess.Popen([svn_exe, 'info', '--xml', path], \
|
||||
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
out, err = p.communicate()
|
||||
if err == '':
|
||||
tree = ET.ElementTree(ET.fromstring(stream_out.read()))
|
||||
tree = ET.ElementTree(ET.fromstring(out))
|
||||
entry = tree.getroot().find('entry')
|
||||
url = entry.find('url').text
|
||||
rev = entry.attrib['revision']
|
||||
|
Reference in New Issue
Block a user