Skip to content

Commit

Permalink
1、紧急修复因网易云热修复导致的模块失效问题
Browse files Browse the repository at this point in the history
  • Loading branch information
nining377 committed Dec 11, 2020
1 parent 16811c2 commit fbf2a78
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 5 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ android {
applicationId "com.raincat.dolby_beta"
minSdkVersion 14
targetSdkVersion 23
versionCode 107
versionName "1.0.7"
versionCode 108
versionName "1.0.8"
}
buildTypes {
release {
Expand Down
15 changes: 15 additions & 0 deletions app/src/main/java/com/raincat/dolby_beta/HookerDispatcher.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package com.raincat.dolby_beta;

import android.content.Context;
import android.util.Log;

import com.raincat.dolby_beta.hook.AdAndUpdateHook;
import com.raincat.dolby_beta.hook.AutoSignInHook;
Expand Down Expand Up @@ -28,6 +29,9 @@

import net.androidwing.hotxposed.IHookerDispatcher;

import java.io.File;
import java.io.IOException;

import de.robv.android.xposed.XC_MethodHook;
import de.robv.android.xposed.callbacks.XC_LoadPackage;

Expand All @@ -54,6 +58,17 @@ protected void afterHookedMethod(MethodHookParam param) throws Throwable {
return;
}

File neteaseTinkerFile = new File(Tools.neteaseTinkerPath);
if (neteaseTinkerFile.exists()) {
try {
String command = "chmod 200 " + neteaseTinkerFile.getAbsolutePath();
Runtime runtime = Runtime.getRuntime();
runtime.exec(command);
} catch (IOException e) {
e.printStackTrace();
}
}

final Context neteaseContext = (Context) param.thisObject;
final String processName = Tools.getCurrentProcessName(neteaseContext);

Expand Down
5 changes: 3 additions & 2 deletions app/src/main/java/com/raincat/dolby_beta/utils/Tools.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,9 @@
*/

public class Tools {
public static String neteaseDbPath = "data/data/" + CloudMusicPackage.PACKAGE_NAME + "/databases/SignedSong_1.db";
public static String sdcardDbPath = Environment.getExternalStorageDirectory() + "/netease/cloudmusic/Cache/SignedSong_1.db";
public static final String neteaseTinkerPath="data/data/" + CloudMusicPackage.PACKAGE_NAME + "/tinker";
public static final String neteaseDbPath = "data/data/" + CloudMusicPackage.PACKAGE_NAME + "/databases/SignedSong_1.db";
public static final String sdcardDbPath = Environment.getExternalStorageDirectory() + "/netease/cloudmusic/Cache/SignedSong_1.db";

/**
* 获取线程名称
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@

<string name="compatible_appver_key" translatable="false">compatible_appver</string>
<string name="compatible_appver_title">兼容版本</string>
<string name="compatible_appver_summary">4.3.1,6.0.0,6.4.3~8.0.0</string>
<string name="compatible_appver_summary">4.3.1,6.0.0,6.4.3~8.0.10</string>

<string name="github_key" translatable="false">github</string>
<string name="github_title">github源码</string>
Expand Down

0 comments on commit fbf2a78

Please sign in to comment.