String search optimization

This commit is contained in:
Dima Turchenkov 2015-11-25 14:31:52 +03:00 committed by pancake
parent c09208909f
commit 898a00d1d4

View File

@ -1347,7 +1347,10 @@ R_API int r_bin_is_string(RBin *bin, ut64 va) {
RList *list;
if ((list = r_bin_get_strings (bin)) == NULL) return false;
r_list_foreach (list, iter, string) {
if (string->vaddr == va) return true;
if (string->vaddr == va)
return true;
else if (string->vaddr > va)
return false;
}
return false;
}