RAD Studio (Common)
|
ToolsCodeGuard Configuration
Use the CodeGuard Configuration dialog box to specify how the CodeGuard runtime debugger behaves.
Item |
Description |
Enable (CodeGuard) |
Enables or disables CodeGuard. |
Stack Fill Frequency |
Specifies how frequently CodeGuard fills the uninitialized portion of the runtime stack with a unique byte pattern. Values are:
|
Statistics |
Reports function and resource usage statistics. |
Resource Leaks |
Reports resource leaks detected after the application terminates. |
Send To OutputDebugString |
Uses the OutputDebugString function to send CodeGuard messages to an external debugger. |
Append To Log File |
Appends the error log to the existing log. When this option is disabled, CodeGuard writes over the existing error log. |
Repeated Errors |
Reports errors that occur repeatedly per function. |
Limit Number Of Error Messages |
Limits the number of errors reported. You can specify a maximum value of 65535. |
Enable (Error Message Box) |
Enables the Error Message Box. If you run a CodeGuard-enabled application outside of RAD Studio, the Error Message Box displays when runtime errors occur. |
Caption |
Specifies the text that appears in the title bar. |
Message |
Specifies the error message to display. |
Read Debug Info |
Enables CodeGuard to use the debugging information in your project to point to a source line when a runtime error is reported. |
Source Path |
If the source code is in a different location from the executable, specify the path (or paths separated by semicolons). CodeGuard checks its own debug source path first, then (if it is running in the IDE) checks the IDE debug source path. |
Use the Resource Options page to specify how CodeGuard covers various types of resources.
Item |
Description |
Resources |
Lists the resource types that CodeGuard can cover, as follows: Memory Block — Memory managed by malloc and free functions. Object — Memory managed by new and delete operators. Object Array — Memory managed by new[] and delete[] operators. File handle — A file managed by the open and close functions. File stream — A file managed by the fopen and fclose functions. Pipe stream — A command processor pipe managed by the _popen and _pclose functions. Directory stream — A directory managed by the opendir and closedir functions. |
Enable Tracking |
Enables tracking on the selected resource. Disabling tracking results in lower memory usage and faster execution. |
Track Resource Leaks |
Reports resource allocations that have no matching deallocations. For example, a leak can be caused by failing to free a file handle before the program terminates. |
Report Invalid Handle / Resource Parameters |
Reports incorrect usage of resources in function arguments. |
Delay Free |
Tracks the selected resource after it has been deallocated. When you enable the Delay Free option, CodeGuard marks the each resource once it has been freed and prevents Windows and runtime libraries from attempting to reuse the resource. Some resources, such as stack memory allocations, cannot be queued for delayed release. |
Delay Queue Length |
Specifies the number of objects that can be queued for delayed release. You can set a maximum value of 65535 objects. |
Maximum Memory Block Size |
Specifies the maximum memory block size that CodeGuard can store in the delay queue. You can set a maximum value of 65535 bytes. |
Use the Function Options page to specify how CodeGuard covers various types of functions.
Item |
Description |
Functions |
Lists the functions that CodeGuard can track. |
Disable Function Tracking |
Disables function tracking for the selected functions. |
Memory Access Errors |
Reports a runtime error if a function uses a pointer to reference invalid memory. |
Log Each Call |
Reports each call to the selected functions. |
Warnings |
Reports situations where your application may be accessing memory beyond a buffer's maximum size. Warnings are reported for only the following runtime library functions: strncmp, strnicmp, strncmpi, _fstrncmp, _fstrnicmp, memcmp, memicmp, _fmemcmp, _fmemicmp, fnmerge, fnsplit, getcurdir. |
Function Results Errors |
Reports if the selected functions return a value that indicates failure. |
Invalid Handle / Resource Parameters |
If any of the selected functions' parameters is a handle or resource identifier, verify that it has been properly allocated and is currently valid. |
Set Default Function Options |
Displays the Set Default Function Options dialog box, which you can use to view and set the default function options. |
Reset To Default Function Options |
Applies the default function options to the selected functions. |
Use the Ignored Modules page to specify modules that you want CodeGuard to skip when it reports errors.
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
|
What do you think about this topic? Send feedback!
|