Ask a Question

stl vector leak?

New Contributor

stl vector leak?

The allocation profiler suggest that code is leaking ... 4 bytes

At the lowest level, before the memory allocation

    // TEMPLATE FUNCTION _Allocate

template<class _Ty> inline

    _Ty _FARQ *_Allocate(_SIZT _Count, _Ty _FARQ *)

    {   // check for integer overflow

    if (_Count <= 0)

        _Count = 0;

    else if (((_SIZT)(-1) / _Count) < sizeof (_Ty))

        _THROW_NCEE(std::bad_alloc, NULL);

        // allocate storage for _Count elements of type _Ty

    return ((_Ty _FARQ *)::operator new(_Count * sizeof (_Ty)));


Are there any known issues with AQTime and the stl vector?

Hello Christian,

There are no known memory leaks in the STL vector implementation. Please check whether the leaked object's creation call stack contains function calls from your code to identify the source of the leak. See the "Searching for Memory Leaks" article on our Support Portal for the reference.

Best regards,

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
Showing results for 
Search instead for 
Did you mean: