Use hooklogger to debug Memory leakage

Source: Internet
Author: User

Symbianc ++ has been developed recently. Because a shapelib open-source library is referenced, errors such as "program closed and program name alloc: Memory Address" will always pop up when you exit the program. As shown in.

 

I searched the internet. This dialog box is often caused by memory leakage.

There are also many methods to debug Memory leakage on Symbian. One of the tools is recognized by everyone, hooklogger. It is really convenient to download and try it out.

Step 1: Download hooklogger as follows:

Http://developer.symbian.com/main/downloads/files/HookLogger.msi


For details about this version, see the following page:

Http://developer.symbian.com/main/tools_and_sdks/developer_tools/supported/hook_logger/index.jsp

The SDK version I used is s60 3rd edition 1.1. It should be supported by symbian7.0 to 9.0.

After installation, run setuphooks in the installation path based on the SDK version. The steps are as follows:
First, enter:
Devices

Obtain the devices ID corresponding to your SDK. the SDK version displayed on my computer is s60_3rd_mr_2: COM. Nokia. s60.
Find the installation path of your hooklogger, switch to the drive letter of your hooklogger installation, and run the CD command to enter:

On the D Drive, enter "D:" And press Enter. Then, enter "cd d:" Symbian "hooklogger and press Enter.

Run
Setuphooks s60_3rd_mr_2: COM. Nokia. s60
Start hooklogger and switch to the threads tab:

 

Start the simulator again and you can see that the output area under threads has a response, indicating that the operation is successful.

Run the program you want to debug and exit. The "program closed error dialog box" pops up ". Switch to the heap tab in hooklogger.

 

Click the third button below. All alloc is not displayed for the first word. Locate the error address above. Double-click the address to bring up the following dialog box:

 

You can see the file and number of lines where the error code is located, check your code, and correct your error.

 

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.