Fix CutterCore::getAllRelocs() for RBTree (#1135)

* Fix CutterCore::getAllRelocs() for RBTree

* Update r2 submodule for RBTree C++ fix
This commit is contained in:
Florian Märkl 2019-01-22 16:35:44 +01:00 committed by GitHub
parent 2d2d4d3346
commit fc534df099
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

@ -1 +1 @@
Subproject commit bbe5c2a31e984a93e465afbc4892352857e8aae9 Subproject commit 2032399ca89bda5539af120ee201f77b4564c1ba

View File

@ -1619,12 +1619,13 @@ QList<CommentDescription> CutterCore::getAllComments(const QString &filterType)
QList<RelocDescription> CutterCore::getAllRelocs() QList<RelocDescription> CutterCore::getAllRelocs()
{ {
CORE_LOCK(); CORE_LOCK();
RListIter *it;
QList<RelocDescription> ret; QList<RelocDescription> ret;
RBinReloc *br;
if (core_ && core_->bin && core_->bin->cur && core_->bin->cur->o) { if (core_ && core_->bin && core_->bin->cur && core_->bin->cur->o) {
CutterRListForeach(core_->bin->cur->o->relocs, it, RBinReloc, br) { auto relocs = core_->bin->cur->o->relocs;
RBIter iter;
RBinReloc *br;
r_rbtree_foreach (relocs, iter, br, RBinReloc, vrb) {
RelocDescription reloc; RelocDescription reloc;
reloc.vaddr = br->vaddr; reloc.vaddr = br->vaddr;