From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E09EE3971C29; Thu, 14 May 2020 16:12:32 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E09EE3971C29 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1589472752; bh=rYKRzkId8RdTCUswFkyJtMeiXqb1qFSVv0LNBDLOZ0c=; h=From:To:Subject:Date:In-Reply-To:References:From; b=L/zp0wlAAk/QpUYL0ARIFxFi3Odezd1KC44IHc30xGIlvhWrwDOiZfpE2lueLTBhz qUIqT8rE57dUZ0kAai2q+SZmGuAVDeIPxTmraQjwuqTZI/zcdvQc3A6VdiFAvJVe8e 7N9spVDsneB8YR7yX+J9Bc6RATa+/SlKAzBHjP0k= From: "tkoenig at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/95119] CLOSE hangs when -fopenmp is specified in compilation Date: Thu, 14 May 2020 16:12:32 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 9.3.0 X-Bugzilla-Keywords: openmp, wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: tkoenig at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED 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: bug_status 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 May 2020 16:12:33 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95119 Thomas Koenig changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED --- Comment #5 from Thomas Koenig --- This looks simple enough. Regression-testing as I write this. @@ -31,7 +31,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. = If not, see #endif typedef enum -{ CLOSE_DELETE, CLOSE_KEEP, CLOSE_UNSPECIFIED } +{ CLOSE_INVALID =3D - 1, CLOSE_DELETE, CLOSE_KEEP, CLOSE_UNSPECIFIED } close_status; static const st_option status_opt[] =3D { @@ -61,6 +61,12 @@ st_close (st_parameter_close *clp) find_option (&clp->common, clp->status, clp->status_len, status_opt, "Bad STATUS parameter in CLOSE statement"); + if (status =3D=3D CLOSE_INVALID) + { + library_end (); + return; + } + u =3D find_unit (clp->common.unit); if (ASYNC_IO && u && u->au)=