Description and cause summary of common crashes or flashbacks on Android

Source: Internet
Author: User

1,nullpointer--that is, the use of an object has not been initialized to cause the problem

Under what circumstances is it generally easy to appear?

(1) parent window + child window appears at the same time, the parent window for some reason, the child window is still in the operation of the child window can not find the PID of the parent window , there will be problems

(2) The problem occurs when a refresh or other click is performed during the loading process and a resource may not have been initialized successfully.

(3) Abnormal circumstances, such as the disconnection of the network, such as the need to connect the device is not connected, the corresponding resources can not be taken, at this point, click on some buttons, the problem will also occur

2, OOM-in the video \ image to switch back and forth, such as the screen of the back and forth to switch the process is relatively easy to appear, because its own machine comparison card, memory is small, loading a larger picture or video is easy to this problem

Solution:

(1) The loading process can be moved from the upper layer to the bottom, such as from the upper Java layer to the underlying C + + layer, which will be compared to save memory

(2) for different pixels of the mobile phone to do a different adaptation (compared to the chip pixel also changes, otherwise the high-pixel picture in the low-pixel cell phone also does not perceive)

Description and cause summary of common crashes or flashbacks on Android

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.