Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-127615

Review usages of std::realloc(ptr, 0)

    XMLWordPrintable

Details

    Description

      Calling realloc with 0 size has always been deprecated ("Invoking realloc with a size argument equal to zero is an obsolescent feature", 7.31.12 in N2176 / C17).

      C23 made it undefined behavior. C++26 is aiming to be rebased on top of C23, incorporating this change.

      We should review our calls to (std::)realloc and make sure we never call it with 0 size.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            thiago Thiago Macieira
            peppe Giuseppe D'Angelo
            Vladimir Minenko Vladimir Minenko
            Alex Blasche Alex Blasche
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes