java - 在 smali 中删除 Intent
问题描述
我通过 jadx 收到了这个方法:
public final void onResponse(Call<UpdaterUpdates> call, Response<UpdaterUpdates> response) {
if (response.isSuccessful()) {
try {
UpdaterUpdates updaterUpdates = (UpdaterUpdates) response.body();
int i = this.a.getPackageManager().getPackageInfo(this.a.getPackageName(), 0).versionCode;
if (!this.a.getPackageName().equals(updaterUpdates.getPackageName())) {
return;
}
if (!updaterUpdates.isIsMandatory() || i >= updaterUpdates.getVersionCode() || VERSION.SDK_INT < updaterUpdates.getMinSdk()) {
d.a(this.a.getApplicationContext()).d(false);
return;
}
d.a(this.a.getApplicationContext()).d(true);
Intent intent = new Intent(this.a.getApplicationContext(), SmartNetUpdaterActivity.class);
intent.setFlags(268468224);
this.a.startActivity(intent);
} catch (Throwable e) {
a.a(e, e.getMessage(), new Object[0]);
}
}
}
在这里,我想评论一下意图本身。
如何在生成的 .smali 类中执行此操作?
这是我以 .smali 格式收到的代码-> Gist 中的链接
解决方案
只需更换
invoke-virtual {v1, v0}, Lcom/testProject/testProjectApplication;->startActivity(Landroid/content/Intent;)V
上
goto :goto_0
推荐阅读
- sql - 如何优化从表的一列中选择对?
- javascript - Javascript 通过引用复制对象。但是下面的代码我为一个对象分配了空值。但是另一个对象仍然具有相同的值
- kdb - 将字符列表列转换为符号
- python - Nginx Web 应用程序重定向在表单提交时失败(重定向到其中包含 %2C 的虚假 url)
- javascript - React useState 不会立即更新数组的状态(react-native)
- reactjs - 了解 React 中键的使用
- python - 语句中的 Python Panda SQL 减法
- c# - 通用方法参数
- spring - 无法通过 spring.flyway.enabled 禁用 flyway
- genexus - 是否有支持票证的 GeneXus 服务器?