-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
快速滑动会导致程序崩溃 #15
Comments
public CancellableAsyncTask(final CancellableTaskDefinition<Params, Result> task)
{
if (task == null)
throw new IllegalArgumentException();
this.ourTask = task;
asyncTask = new AsyncTask<Params, Void, Result>()
{
@Override
protected Result doInBackground(Params... params)
{
return task.doInBackground(params);
}
@Override
protected void onPreExecute()
{
CancellableAsyncTask.this.onPreExecute();
}
@Override
protected void onPostExecute(Result result)
{
CancellableAsyncTask.this.onPostExecute(result);
task.doCleanup();
}
+ @Override
+ protected void onCancelled(Result result)
+ {
+ task.doCleanup();
+ }
};
}
public void cancelAndWait()
{
this.asyncTask.cancel(true);
ourTask.doCancel();
try
{
this.asyncTask.get();
}
catch (InterruptedException e)
{
}
catch (ExecutionException e)
{
}
catch (CancellationException e)
{
}
-
- ourTask.doCleanup();
} |
1uokun
added a commit
to 1uokun/mupdf-android
that referenced
this issue
Sep 22, 2020
See the detail in LonelyPluto/PdfViewerDemo#15
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
2020-08-08 13:56:31.920 4060-4158/com.shuyuntu.rzzyghgw A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x4 in tid 4158 (RenderThread), pid 4060 (uyuntu.rzzyghgw)
2020-08-08 13:56:31.970 4448-4448/? E/crash_dump32: unknown process state: t
2020-08-08 13:56:32.007 4448-4448/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2020-08-08 13:56:32.008 4448-4448/? A/DEBUG: Build fingerprint: 'samsung/a7y18ltedx/a7y18lte:10/QP1A.190711.020/A750GNDXU6CTF1:user/release-keys'
2020-08-08 13:56:32.008 4448-4448/? A/DEBUG: Revision: '5'
2020-08-08 13:56:32.008 4448-4448/? A/DEBUG: ABI: 'arm'
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: Timestamp: 2020-08-08 13:56:32+0800
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: pid: 4060, tid: 4158, name: RenderThread >>> com.shuyuntu.rzzyghgw <<<
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: uid: 10560
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x4
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: Cause: null pointer dereference
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: r0 00000004 r1 ddf080e0 r2 00000001 r3 00000000
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: r4 beafd7a8 r5 beafd7a4 r6 00000004 r7 beafd7a8
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: r8 bd8e0ff4 r9 bd8e0ff0 r10 beafd79c r11 d3fded38
2020-08-08 13:56:32.009 4448-4448/? A/DEBUG: ip ec66c884 sp bd8e0fe8 lr ec5b0407 pc ec5b0412
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: backtrace:
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #00 pc 000e7412 /system/lib/libandroid_runtime.so (void std::__1::set<android::spandroid::uirenderer::PropertyValuesAnimatorSet, std::__1::less<android::spandroid::uirenderer::PropertyValuesAnimatorSet>, std::__1::allocator<android::spandroid::uirenderer::PropertyValuesAnimatorSet>>::insert<std::__1::__tree_const_iterator<android::spandroid::uirenderer::PropertyValuesAnimatorSet, std::__1::__tree_node<android::spandroid::uirenderer::PropertyValuesAnimatorSet, void*>, int>>(std::__1::__tree_const_iterator<android::spandroid::uirenderer::PropertyValuesAnimatorSet, std::__1::__tree_node<android::spandroid::uirenderer::PropertyValuesAnimatorSet, void>, int>, std::__1::set<android::spandroid::uirenderer::PropertyValuesAnimatorSet, std::__1::less<android::spandroid::uirenderer::PropertyValuesAnimatorSet>, std::__1::allocator<android::spandroid::uirenderer::PropertyValuesAnimatorSet>>::insert<std::__1::__tree_const_iterator<android::spandroid::uirenderer::PropertyValuesAnimatorSet, std::__1::__tree_node<android::spandroid::uirenderer::PropertyValuesAnimatorSet, void>, int>>)+142) (BuildId: 398a834e9bbd595ad677fd10fa4e85b3)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #1 pc 000e7325 /system/lib/libandroid_runtime.so (android::AnimationContextBridge::startFrame(android::uirenderer::TreeInfo::TraversalMode)+120) (BuildId: 398a834e9bbd595ad677fd10fa4e85b3)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #2 pc 00319f41 /system/lib/libhwui.so (android::uirenderer::renderthread::CanvasContext::prepareTree(android::uirenderer::TreeInfo&, long long, long long, android::uirenderer::RenderNode*)+172) (BuildId: 361ef466e058fdb7c65246150d0c34cb)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #3 pc 00319d2b /system/lib/libhwui.so (android::uirenderer::renderthread::DrawFrameTask::syncFrameState(android::uirenderer::TreeInfo&)+142) (BuildId: 361ef466e058fdb7c65246150d0c34cb)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #4 pc 003199a3 /system/lib/libhwui.so (_ZNSt3__110__function6__funcIZN7android10uirenderer12renderthread13DrawFrameTask11postAndWaitEvE3$_0NS_9allocatorIS6_EEFvvEEclEv$c303f2d2360db58ed70a2d0ac7ed911b+78) (BuildId: 361ef466e058fdb7c65246150d0c34cb)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #5 pc 00324c8f /system/lib/libhwui.so (android::uirenderer::WorkQueue::process()+158) (BuildId: 361ef466e058fdb7c65246150d0c34cb)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #6 pc 00324aed /system/lib/libhwui.so (android::uirenderer::renderthread::RenderThread::threadLoop()+72) (BuildId: 361ef466e058fdb7c65246150d0c34cb)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #7 pc 0000d84f /system/lib/libutils.so (android::Thread::_threadLoop(void*)+182) (BuildId: 0782021e9b98ed0a90e55b58e977ddce)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #8 pc 000a75b3 /apex/com.android.runtime/lib/bionic/libc.so (__pthread_start(void*)+20) (BuildId: 320fbdc2a1289fadd7dacae7f2eb77a3)
2020-08-08 13:56:32.076 4448-4448/? A/DEBUG: #9 pc 00061b33 /apex/com.android.runtime/lib/bionic/libc.so (__start_thread+30) (BuildId: 320fbdc2a1289fadd7dacae7f2eb77a3)
2020-08-08 13:56:32.635 4018-4018/? E//system/bin/tombstoned: Tombstone written to: /data/tombstones/tombstone_04
2020-08-08 13:56:32.676 3957-3957/? E/audit: type=1701 audit(1596866192.673:146814): auid=4294967295 uid=10560 gid=10560 ses=4294967295 subj=u:r:untrusted_app:s0:c48,c258,c512,c768 pid=4060 comm="RenderThread" exe="/system/bin/app_process32" sig=11
The text was updated successfully, but these errors were encountered: