Skip to content

Commit

Permalink
fixes a bug in adt printer (which breaks bap-python integration)
Browse files Browse the repository at this point in the history
Since the release of BAP 2.0 bap-python integration was broken, as
Tid.name now returns a parseable representation of the knowledge
object and, as a result, we were getting something like
`Tid(0x%deadbeef)` as the input in python.
  • Loading branch information
ivg authored and gitoleg committed Sep 12, 2019
1 parent 8a46bbe commit 69fde6f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion plugins/print/print_main.ml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,9 @@ module Adt = struct
let pp_word ppf = Word.pp_generic ~prefix:`base ~format:`hex ppf

module Tid = struct
let pp ppf tid = pr ppf "Tid(0x%a, %S)" Tid.pp tid (Tid.name tid)
let pp ppf tid = pr ppf "Tid(%#Ld, %S)"
(Int63.to_int64 (KB.Object.id tid))
(Tid.name tid)
end

let pp_seq pp_elem ch seq =
Expand Down

0 comments on commit 69fde6f

Please sign in to comment.