Skip to content

Commit

Permalink
Generate unique signature dict key
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonas Zaddach committed Jul 20, 2017
1 parent 5adb8ce commit 93cdefa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion plugin/casc_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -2220,7 +2220,10 @@ def add_signature(self):
sig = self.signature_line_edit.text()
self._add_signature(sig)
self.signature_line_edit.setText("")
self.netnode[len(self.netnode.keys())] = sig
key = len(self.netnode.keys())
while key in self.netnode.keys():
key += 1
self.netnode[key] = sig

def _add_signature(self, sig):
signature = parse_signature(sig)
Expand Down

0 comments on commit 93cdefa

Please sign in to comment.