Skip to content

Commit be70dcf

Browse files
committed
fixes #429
1 parent c8434eb commit be70dcf

2 files changed

Lines changed: 17 additions & 7 deletions

File tree

cSploit/src/main/java/org/csploit/android/MainActivity.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ public void run() {
150150
}
151151

152152
private void onCoreUpdated() {
153+
System.onCoreInstalled();
153154
MainActivity.this.runOnUiThread(new Runnable() {
154155
@Override
155156
public void run() {

cSploit/src/main/java/org/csploit/android/core/System.java

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -196,13 +196,8 @@ public static void init(Context context) throws Exception {
196196
// initialize network data at the end
197197
uncaughtReloadNetworkMapping();
198198

199-
ThreadHelper.getSharedExecutor().execute(new Runnable() {
200-
@Override
201-
public void run() {
202-
preloadVendors();
203-
preloadServices();
204-
}
205-
});
199+
if(isCoreInstalled())
200+
beginLoadServicesAndVendors();
206201
} catch (Exception e) {
207202
if (!(e instanceof NoRouteToHostException))
208203
errorLogging(e);
@@ -211,6 +206,20 @@ public void run() {
211206
}
212207
}
213208

209+
private static void beginLoadServicesAndVendors() {
210+
ThreadHelper.getSharedExecutor().execute(new Runnable() {
211+
@Override
212+
public void run() {
213+
preloadVendors();
214+
preloadServices();
215+
}
216+
});
217+
}
218+
219+
public static void onCoreInstalled() {
220+
beginLoadServicesAndVendors();
221+
}
222+
214223
public static void reloadTools() {
215224
getTools().reload();
216225
}

0 commit comments

Comments
 (0)