~wwoods/apport/fedora

« back to all changes in this revision

Viewing changes to apport/crashdb.py

  • Committer: Will Woods
  • Date: 2007-07-17 14:47:01 UTC
  • mfrom: (857.1.75 apport)
  • Revision ID: wwoods@metroid.rdu.redhat.com-20070717144701-2aiazkottxs22jba
mergeĀ fromĀ upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
243
243
 
244
244
        return self.duplicate_db_last_consolidation() >= interval
245
245
 
 
246
    def duplicate_db_change_master_id(self, old_id, new_id):
 
247
        '''Change a crash ID.'''
 
248
 
 
249
        assert self.duplicate_db, 'init_duplicate_db() needs to be called before'
 
250
 
 
251
        cur = self.duplicate_db.cursor()
 
252
        cur.execute('UPDATE crashes SET crash_id = ?, last_change = CURRENT_TIMESTAMP WHERE crash_id = ?',
 
253
            [new_id, old_id])
 
254
        self.duplicate_db.commit()
 
255
 
246
256
    def _duplicate_search_signature(self, sig):
247
257
        '''Look up signature in the duplicate db and return an [(id,
248
258
        fixed_version)] tuple list.