summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/androhelpers/try_n_catch.c3
-rw-r--r--plugins/readdex/class.c20
2 files changed, 15 insertions, 8 deletions
diff --git a/plugins/androhelpers/try_n_catch.c b/plugins/androhelpers/try_n_catch.c
index 83be896..0e2ae43 100644
--- a/plugins/androhelpers/try_n_catch.c
+++ b/plugins/androhelpers/try_n_catch.c
@@ -347,6 +347,9 @@ static void look_for_exception_handlers(const GLoadedBinary *binary, const GDexF
body = g_dex_method_get_dex_body(method);
+ if (body == NULL)
+ return;
+
if (body->tries_size == 0)
return;
diff --git a/plugins/readdex/class.c b/plugins/readdex/class.c
index ccfdf9d..d3ca197 100644
--- a/plugins/readdex/class.c
+++ b/plugins/readdex/class.c
@@ -311,17 +311,21 @@ static bool annotate_dex_class_data(const GDexFormat *format, const GDexClass *c
data = g_dex_class_get_data(class);
- for (i = 0; i < data->static_fields_size && result; i++)
- result = annotate_dex_encoded_field(format, &pos);
+ if (data != NULL)
+ {
+ for (i = 0; i < data->static_fields_size && result; i++)
+ result = annotate_dex_encoded_field(format, &pos);
+
+ for (i = 0; i < data->instance_fields_size && result; i++)
+ result = annotate_dex_encoded_field(format, &pos);
- for (i = 0; i < data->instance_fields_size && result; i++)
- result = annotate_dex_encoded_field(format, &pos);
+ for (i = 0; i < data->direct_methods_size && result; i++)
+ result = annotate_dex_encoded_method(format, &data->direct_methods[i], &pos);
- for (i = 0; i < data->direct_methods_size && result; i++)
- result = annotate_dex_encoded_method(format, &data->direct_methods[i], &pos);
+ for (i = 0; i < data->virtual_methods_size && result; i++)
+ result = annotate_dex_encoded_method(format, &data->virtual_methods[i], &pos);
- for (i = 0; i < data->virtual_methods_size && result; i++)
- result = annotate_dex_encoded_method(format, &data->virtual_methods[i], &pos);
+ }
/* Nettoyage final */