Skip to content
Tcl Source Code View Ticket
Login

View Ticket

Can't do exec > file anymore

Closed / Invalid1654651fffffffffffffffffffffffffffffffffCreated 20 years agoUpdated 20 years ago
Descriptionplain2007-02-07 22:50:04
This command here was working in 8.4.7 :

exec > anyfile

In 8.4.13, it's not working anymore.
% exec > tata
illegal use of | or |& in command

In 8.4.9, it was still working.

exec man page :
> fileName 
Standard output from the last command is redirected to the file named fileName, overwriting its previous contents.
dkf Ticket [1654651fff]: 4 changes [History diff]2007-02-08 16:40:39
andreas_kupriesplain2007-02-09 00:57:50
Logged In: YES 
user_id=75003
Originator: NO

What should 'exec > file' do ? You execute nothing and redirect that to a file ? There is no output to redirect, no last command, as there is no command at all. Therefore I do not believe that the quoted part of the manpage applies.

This change in behaviour is likely coming from the fix for [Bug 768659]. The relevant changelog entry is

2006-03-14  Andreas Kupries <[email protected]>

* generic/tclPipe.c (TclCreatePipeline): Modified the processing of
pipebars to fail if the last bar is followed only by redirections.
[Bug 768659]
hobbs Pending ticket [1654651fff]. [History diff]2007-02-09 06:14:32
sf-robotplain2007-02-23 10:20:09
Logged In: YES 
user_id=1312539
Originator: NO

This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).
Log in (anonymous is fine) to add a comment.