Android-Download-Manager-Pro icon indicating copy to clipboard operation
Android-Download-Manager-Pro copied to clipboard

Crash application when i try to pause when onStop trigger

Open pishguy opened this issue 7 years ago • 0 comments

I'm trying to pause current download on onStop by this code:

@Override
protected void onStop() {
    super.onStop();
    Alachiq.getDefaultInstance().pauseDownload(Alachiq.getDefaultInstance().getCurrentDownloadingTaskId());

    EventBus.getDefault().unregister(this);
}

public int getCurrentTask(){
    int thisTask = 0;
    String query = "SELECT * FROM " + TABLES.TASKS
            + " WHERE " + TASKS.COLUMN_STATE + "==" + SqlString.Int(TaskStates.DOWNLOADING);

    ...
}

but i get an error on this line of code

.core.chunkWorker.ConnectionWatchDog.run(ConnectionWatchDog.java:56)

pishguy avatar Dec 18 '16 12:12 pishguy