Kiln » Dependencies » Dulwich Read More
Clone URL:  
Pushed to one repository · View In Graph Contained in master-1, master-0, and 0.9.4

Properly abort connections when the determine_wants function
raises an exception.

Changeset 493ed46a2b8f

Parent df4aeaf61143

by Jelmer Vernooij

Changes to 2 files · Browse files at 493ed46a2b8f Showing diff from parent df4aeaf61143 Diff from another changeset...

Change 1 of 1 Show Entire File NEWS Stacked
 
11
12
13
 
 
 
14
15
16
 
11
12
13
14
15
16
17
18
19
@@ -11,6 +11,9 @@
  * Avoid calling free_objects() on NULL in error cases. (Chris Eberle)     * Fix use --bare argument to 'dulwich init'. (Chris Eberle) + + * Properly abort connections when the determine_wants function + raises an exception. (Jelmer Vernooij, #856769)     FEATURES  
Change 1 of 2 Show Entire File dulwich/​client.py Stacked
 
419
420
421
422
 
 
 
 
 
423
424
425
 
446
447
448
449
 
 
 
 
 
450
451
452
 
419
420
421
 
422
423
424
425
426
427
428
429
 
450
451
452
 
453
454
455
456
457
458
459
460
@@ -419,7 +419,11 @@
  negotiated_capabilities = list(self._send_capabilities)   if 'report-status' not in server_capabilities:   negotiated_capabilities.remove('report-status') - new_refs = determine_wants(old_refs) + try: + new_refs = determine_wants(old_refs) + except: + proto.write_pkt_line(None) + raise   if new_refs is None:   proto.write_pkt_line(None)   return old_refs @@ -446,7 +450,11 @@
  proto, can_read = self._connect('upload-pack', path)   (refs, server_capabilities) = self._read_refs(proto)   negotiated_capabilities = list(self._fetch_capabilities) - wants = determine_wants(refs) + try: + wants = determine_wants(refs) + except: + proto.write_pkt_line(None) + raise   if not wants:   proto.write_pkt_line(None)   return refs