summaryrefslogtreecommitdiff
path: root/bashline.c
diff options
context:
space:
mode:
Diffstat (limited to 'bashline.c')
-rw-r--r--bashline.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/bashline.c b/bashline.c
index 824ea9d9..97adaa0f 100644
--- a/bashline.c
+++ b/bashline.c
@@ -961,11 +961,8 @@ edit_and_execute_command (count, c, editing_mode, edit_command)
/* This breaks down when using command-oriented history and are not
finished with the command, so we should not ignore the last command */
using_history ();
- if (rl_line_buffer[0])
- {
- current_command_line_count++; /* for rl_newline above */
- bash_add_history (rl_line_buffer);
- }
+ current_command_line_count++; /* for rl_newline above */
+ bash_add_history (rl_line_buffer);
current_command_line_count = 0; /* for dummy history entry */
bash_add_history ("");
history_lines_this_session++;