From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 1A3793858D39; Fri, 3 Nov 2023 10:06:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1A3793858D39 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1699005984; bh=Qypm2WWj27swuh6n6K9yeLuANmySmsTeMg/JA1nCFso=; h=From:To:Subject:Date:In-Reply-To:References:From; b=J0hlm5WmpIF8jxWFqz9/AjVsonnEZ5YwFI7TYu+i3/RORc0eLbuUc2P63tpFgIq74 kpgMl4NBEfaPwNUtNWb5jhLxz5s4kQ+XQ2On0NEl34TYqb+YJ9Y5rnROdST0vz6a3W jol6Jnad7tzJPbuVGx8rs3AHkzKc4c9roi5TyVJs= From: "muecker at gwdg dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug libfortran/112364] calloc used incorrectly Date: Fri, 03 Nov 2023 10:06:23 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libfortran X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: easyhack, internal-improvement X-Bugzilla-Severity: normal X-Bugzilla-Who: muecker at gwdg dot de X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D112364 --- Comment #4 from Martin Uecker --- Interesting. But independently of alignment, the description of calloc make= s it clear that it allocates an array of nmemb objects of size x. So in any cas= e I think the code should be changed accordingly, which seems simple enough.=