Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9.2, 1.9.3, and 2.0

qqueue: fix Python 2.4 compatibility issue

In Python 2.4, with statement is not recognized.

Changeset a4a463e5514c

Parent 97441cf12263

by André Sintzoff

Changes to one file · Browse files at a4a463e5514c Showing diff from parent 97441cf12263 Diff from another changeset...

 
240
241
242
243
 
 
244
 
 
245
246
247
 
240
241
242
 
243
244
245
246
247
248
249
250
@@ -240,8 +240,11 @@
  sf = '/.hg/patches-%s/series' % q   sf = self.repo.root + sf   if os.path.exists(sf): - with open(sf, 'r') as f: + f = open(sf, 'r') + try:   patches = f.read().splitlines() + finally: + f.close()   for p in patches:   item = QListWidgetItem(hglib.tounicode(p))   item.setFlags(Qt.ItemIsSelectable | Qt.ItemIsEnabled)