Questions tagged [bounds-checker]

A software developer tool used to detect the inappropriate usage of memory regions.

A "Bounds Checker", in the computing world, is a tool used to analyze a program, either through static code inspection or through direct testing of the running program, in order to ensure that all references to data objects are done according to their proper rules. In particular, memory buffer usage does not overflow nor underflow the memory buffer's allocated space. Such tools are often used in the search for memory leaks and other such flaws in running programs.

The name probably derives from the product BoundsChecker, originally produced by Nu-Mega Technologies in the early 1990s.

27 questions
47
votes
2 answers

GCC STL bound checking

How do I enable bound checking for operator[] and iterators?
pic11
  • 14,267
  • 21
  • 83
  • 119
27
votes
6 answers

How to make std::vector's operator[] compile doing bounds checking in DEBUG but not in RELEASE

I'm using Visual Studio 2008. I'm aware that std::vector has bounds checking with the at() function and has undefined behaviour if you try to access something using the operator [] incorrectly (out of range). I'm curious if it's possible to compile…
Gustavo Muenz
  • 9,278
  • 7
  • 40
  • 42
20
votes
1 answer

@inbounds propagation rules in Julia

I'm looking for some clarification of the bounds checking rules in Julia. Is this meaning that if I put @inbounds at the beginning of the for loop, @inbounds for ... end then only for "one layer" inbounds propagates, so if there is a for loop…
Chris Rackauckas
  • 18,645
  • 3
  • 50
  • 81
17
votes
10 answers

64 bit tools like BoundsChecker & Purify

For many years I have used two great tools BoundsChecker & Purify, but the developers of these applications have let me down, they no longer put effort into maintaining them or developing them. We have corporate accounts with both companies, and…
titanae
  • 2,259
  • 2
  • 21
  • 31
10
votes
6 answers

How can I find the location of a "List index out of bounds" error in Delphi

In Delphi 2009, my program now produces a "List index out of bounds" error. It generates a popup box: (source: beholdgenealogy.com) I'm using the "Debug" Build Configuration that has all the Runtime error checking turned on. But this does not…
lkessler
  • 19,819
  • 36
  • 132
  • 203
8
votes
5 answers

Good memory profiling, leak and error detection for Windows

I'm currently looking for a good memory / leak detection tool for Windows. A few years ago, I used Numega's Boundschecker, which was VERY good. Right now it seems to have been sold to Compuware, which apparently sold it again to some other company.…
cfischer
  • 24,452
  • 37
  • 131
  • 214
6
votes
8 answers

How do virtual destructors work?

Few hours back I was fiddling with a Memory Leak issue and it turned out that I really got some basic stuff about virtual destructors wrong! Let me put explain my class design. class Base { virtual push_elements() {} }; class Derived:public…
Prabhu
  • 3,434
  • 8
  • 40
  • 48
5
votes
3 answers

Bounds checking for Variable Length Arrays (VLA)?

Is there a way to check for buffer overflows in VLA's ? I used -fstack-protector-all -Wstack-protector but get these warnings: warning: not protecting local variables: variable length buffer Is there a library for achieving this ? (-lefence is for…
Jan Chou
  • 51
  • 1
4
votes
2 answers

Will any programs detect a buffer overflow within a C/C++ structure?

Consider the following program: struct abc { int x[5]; int y[5]; }; int main() { struct abc test; test.y[0] = 10; printf("%d", test.x[5]); } (borrowed from Is it legal to overrun one element of a struct to view…
user265445
  • 341
  • 1
  • 4
  • 11
3
votes
1 answer

Failed to install MPX Runtime Driver (for bounds checking)

After reading this blog post on detecting memory leaks I decided to install the MPX runtime driver from here. I right-clicked mpxruntime.inf and selected "install". The Device manager then lists "Intel(R) MPX Runtime Driver" under system devices,…
Mick
  • 8,284
  • 22
  • 81
  • 173
3
votes
2 answers

Visual C++ debugger and BoundsChecker mystery

Look at this screenshot of a Visual C++ debugger session: (source: lviv.ua) The execution point is now inside a virtual function. "mDb" is a reference to an object which is the member of that class. "mDb" has the type CDbBackend&. There is only…
user38329
  • 719
  • 4
  • 17
2
votes
1 answer

Can array bounds checking be disabled in Visual Basic 2008

I know that this was an advanced compiler option in previous versions of Visual Studio, is there a way to disable array bounds checking in Visual Studio 2008? There's no option for it that I can see.
SteveGSD
  • 1,750
  • 1
  • 17
  • 28
2
votes
1 answer

GDI resource leak in DrawFrameControl

It seems that DrawFrameControl() creates Font and Brush objects, select them into dc, and doesn't delete them. (according to BoundsChecker messages). Does anyone faced such thing?
cos
  • 940
  • 1
  • 10
  • 25
2
votes
1 answer

Does cyclone perform static or dynamic checks on fat pointers?

I am working my way thru Cyclone: A Safe Dialect of C for a PL class. The paper's authors explain that they've added a special 'fat' pointer that stores bounds information to prevent buffer overflows. But they don't specify if the check on this…
bernie2436
  • 22,841
  • 49
  • 151
  • 244
2
votes
4 answers

Technical name for a region of memory with a fixed pattern for bounds checking?

I want to know if there is some technical name for those regions of extra memory that are allocated for debugging purposes and filled with special patterns, so they can be checked at runtime to see if have been overwritten (and thus detecting a…
fortran
  • 74,053
  • 25
  • 135
  • 175
1
2