~peter-pearse/ubuntu/natty/dash/prop001

« back to all changes in this revision

Viewing changes to debian/diff/0002--SHELL-print-n-upon-EOF-CTRL-D-when-run-interacti.diff

  • Committer: Bazaar Package Importer
  • Author(s): Michael Vogt
  • Date: 2009-04-29 10:45:09 UTC
  • mfrom: (3.1.3 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090429104509-awtb7757j3orktqr
Tags: 0.5.5.1-2ubuntu1
* Merge from debian unstable, remaining changes:
  - Make the package both "required" and "Essential" since this is our
    default system shell.
  - Add dependency on debianutils so /etc/shells exists before
    we are configured
  - If the dash/sh question has not been seen by the user, reset it to
    the default which is now true.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
From 1cb75049490ad83076a6f02a63a1563fcf3401f3 Mon Sep 17 00:00:00 2001
 
2
From: Gerrit Pape <pape@smarden.org>
 
3
Date: Wed, 11 Feb 2009 01:38:49 +0000
 
4
Subject: [PATCH 2/2] [SHELL] print \n upon EOF (CTRL-D) when run interactively
 
5
 
 
6
Suggested by jidanni through
 
7
 http://bugs.debian.org/476422
 
8
 
 
9
Signed-off-by: Gerrit Pape <pape@smarden.org>
 
10
---
 
11
 src/main.c |    9 ++++++++-
 
12
 1 files changed, 8 insertions(+), 1 deletions(-)
 
13
 
 
14
diff --git a/src/main.c b/src/main.c
 
15
index 7d07e2d..5f1ff0e 100644
 
16
--- a/src/main.c
 
17
+++ b/src/main.c
 
18
@@ -228,8 +228,15 @@ cmdloop(int top)
 
19
                        if (!top || numeof >= 50)
 
20
                                break;
 
21
                        if (!stoppedjobs()) {
 
22
-                               if (!Iflag)
 
23
+                               if (!Iflag) {
 
24
+                                       if (iflag) {
 
25
+                                               out2c('\n');
 
26
+#ifdef FLUSHERR
 
27
+                                               flushout(out2);
 
28
+#endif
 
29
+                                       }
 
30
                                        break;
 
31
+                               }
 
32
                                out2str("\nUse \"exit\" to leave shell.\n");
 
33
                        }
 
34
                        numeof++;
 
35
-- 
 
36
1.6.1.3
 
37