Skip to content

Commit

Permalink
Export pickles to python2
Browse files Browse the repository at this point in the history
  • Loading branch information
Wei-Cheng Wu committed Jul 30, 2020
1 parent 8001621 commit b3715e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions BB-weight-angr.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ def dump_analysis(filename):
a,b = fweight[addr]
fweight[addr] = (1.0/a,b)
with open("%s.pkl"%filename,"wb") as f:
pickle.dump(fweight,f)
pickle.dump(fweight,f,protocol=2)
# dump cmp operands analysis
cmp_imm_operands_hex = []
cmp_imm_operands2 = list(cmp_imm_operands)
Expand All @@ -210,7 +210,7 @@ def dump_analysis(filename):
cmp_imm_operands.remove(op)
cmp_imm_operands_hex = set().union(cmp_imm_operands_hex)
with open("%s.names" % filename,'wb') as f:
pickle.dump((cmp_imm_operands,cmp_imm_operands_hex),f)
pickle.dump((cmp_imm_operands,cmp_imm_operands_hex),f,protocol=2)

def find_CMP_operands(proj,cfg,binName):
global cmp_imm_operands
Expand Down

0 comments on commit b3715e9

Please sign in to comment.