[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-ed] Exit without saving if output file is a command
From: |
Jérôme FRGACIC |
Subject: |
[Bug-ed] Exit without saving if output file is a command |
Date: |
Sun, 14 Aug 2016 18:00:04 +0200 |
Dear Maintainer(s),
I recently use GNU ed (1.10 version) to transmit some input lines to
another command. However, I remark that after the 'w' command, I can
exit ed without any warnings even if the data were not saved into a
file.
Here is an example :
$ ed
P
*a
A simple line.
.
*w !sed 's/^/#/'
#A simple line.
15
*q
$ # No warning before exit
This bug seems to be present in the other versions of ed, including the
last version, 1.13. I would suggest to modify line 580 in main_loop.c
by this one to resolve this problem.
if( addr == last_addr() && fnp[0] != '!') set_modified( false );
Kind regards,
Jérôme FRGACIC
- [Bug-ed] Exit without saving if output file is a command,
Jérôme FRGACIC <=