https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112364

--- Comment #12 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Tobias Burnus <bur...@gcc.gnu.org>:

https://gcc.gnu.org/g:17df6ddcf11aef6d200305d35641a7deb2f430e1

commit r14-5148-g17df6ddcf11aef6d200305d35641a7deb2f430e1
Author: Tobias Burnus <tob...@codesourcery.com>
Date:   Mon Nov 6 11:34:31 2023 +0100

    libgfortran: Fix calloc call by swapping arg order [PR112364]

    The prototype of calloc is
      void *calloc(size_t nmemb, size_t size);
    denoting "an array of nmemb objects, each of whose size is size." (C23)

    In order to follow the meaning of the argument names and to silence
    a -Walloc-size warning, this commit swaps the order of the two args
    to read now:  calloc (1, sizeof (transfer_queue));

    libgfortran/ChangeLog:

            PR libfortran/112364
            * io/async.c (enqueue_transfer, enqueue_done_id, enqueue_done,
            enqueue_close): Swap 1st and 2nd arg in calloc call.

Reply via email to