From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 866EB3857C69; Wed, 10 Jan 2024 20:20:56 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 866EB3857C69 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1704918056; bh=krXirdqfVI8uW/w8ehZORy8rd1BhbBuXKOenU/MUgpE=; h=From:To:Subject:Date:From; b=vkxxpkl6oorV2A4fBUEWCFQtfZy1frJCV9tqzfwbd2+q6cMT9PHf626oB3AgSLhBG 31LKoRUIXToDBy+FGPIBUPNyQwqkjrDQQeyKCOliV288UqF/p5t/hs3Y10f86rLQ5u eyZjVQPVt3E6h4Wtz3qZDu1x/35Y5/DCeTA2dhhM= From: "john.harper at vuw dot ac.nz" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/113313] New: execute_command_line hangs at run time Date: Wed, 10 Jan 2024 20:20:55 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 13.1.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: john.harper at vuw dot ac.nz X-Bugzilla-Status: UNCONFIRMED 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_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: 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=3D113313 Bug ID: 113313 Summary: execute_command_line hangs at run time Product: gcc Version: 13.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: john.harper at vuw dot ac.nz Target Milestone: --- This program compiles and executes as expected with 3 other compilers (ifor= t, ifx, flang). With gfortran 13.1.0 it compiles happily but prints nothing and hangs at run time. My operating system is ubuntu1~22.04. program test ! f2008 using execute_command_line and assuming Linux implicit none print "(A,L2)",'I am john',iam('john') print "(A,L2)",'I am JOHN',iam('JOHN') contains logical function iam( name) character(*),intent(in)::name integer estat character(len(name)+38):: cmd cmd =3D 'if [ `whoami` !=3D "'//name//'" ]; then exit 1; fi' call execute_command_line(cmd,exitstat=3Destat) iam =3D (estat=3D=3D0) end function iam end program test The other compilers all printed I am john T I am JOHN F=