OpenCoverageBash

Bash patch #10 - Test report of the modifications

Overview

Test Execution StatusStatistics
Passed
  0.000% (0/1)
Failed
  0.000% (0/1)
Requires Manual Checking
  0.000% (0/1)
Unknown
100.000% (1/1)
All
100.000% (1/1)
CategoryRemoved LinesInserted LinesTotal
Modified lines executed:
  0.000% (0/30)
  2.899% (2/69)
  2.020% (2/99)
Modified lines not executed:
  6.667% (2/30)
  4.348% (3/69)
  5.051% (5/99)
Source code lines not covered:
 93.333% (28/30)
 92.754% (64/69)
 92.929% (92/99)

List of tests executing the changes

Execution NameState
Self testUnknown

Patch File

Showing: 

Modified File: CWRU/CWRU.chlog

LineTestsDifference Output
diff --git a/CWRU/CWRU.chlog b/CWRU/CWRU.chlog
index 545a6137..5d6eec63 100644
--- a/CWRU/CWRU.chlog
+++ b/CWRU/CWRU.chlog
@@ -14902,3 +14902,28 @@ execute_cmd.c
14902 - execute_command_internal: if redirections attached to a compound
14903 command fail, make sure we discard the `internal_fifos' unwind-
14904 protect frame after freeing the copied fifo_list and before returning
14905
-
+
14906
-
+ 1/30
14907
-
+ ----
14908
-
+lib/readline/rlprivate.h
14909
-
+ - BRACK_PASTE_FINI: add \r to the end of the string to avoid problems
14910
-
+ with the tty driver thinking the cursor was in the wrong position.
14911
-
+ Fixes issue reported by Egmont Koblinger <egmont@gmail.com>
14912
-
+
14913
-
+ 1/31
14914
-
+ ----
14915
-
+lib/sh/zread.c
14916
-
+ - zread,zreadintr: call check_signals() before calling read() to
14917
-
+ minimize the race window between signal delivery, signal handling,
14918
-
+ and a blocking read(2). Partial fix for FIFO read issue reported by
14919
-
+ Oyvind Hvidsten <oyvind.hvidsten@dhampir.no>
14920
-
+
14921
-
+doc/{bash.1,bashref.texi}
14922
-
+ - shopt: document `assoc_expand_once' shell option
14923
-
+
14924
-
+ 2/1
14925
-
+ ---
14926
-
+config-top.h
14927
-
+ - DONT_REPORT_SIGPIPE: define, so non-interactive shells will no
14928
-
+ longer print termination messages for child processes killed by
14929
-
+ SIGTERM

Modified File: Makefile.in

LineTestsDifference Output
diff --git a/Makefile.in b/Makefile.in
index 3a4d66b0..d62ea078 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1047,7 +1047,7 @@ hashlib.o: quit.h ${BASHINCDIR}/maxpath.h unwind_prot.h dispose_cmd.h
1047 hashlib.o: make_cmd.h subst.h sig.h pathnames.h externs.h
1048 input.o: config.h bashtypes.h ${BASHINCDIR}/filecntl.h ${BASHINCDIR}/posixstat.h bashansi.h ${BASHINCDIR}/ansi_stdlib.h
1049 input.o: command.h ${BASHINCDIR}/stdc.h general.h xmalloc.h input.h error.h externs.h
1050
-
No equivalent source code line in the reference code can be identified.
-input.o: quit.h shell.h
1050
-
+input.o: quit.h shell.h pathnames.h
1051 list.o: shell.h syntax.h config.h bashjmp.h ${BASHINCDIR}/posixjmp.h command.h ${BASHINCDIR}/stdc.h error.h
1052 list.o: general.h xmalloc.h bashtypes.h variables.h arrayfunc.h conftypes.h array.h hashlib.h
1053 list.o: quit.h ${BASHINCDIR}/maxpath.h unwind_prot.h dispose_cmd.h
@@ -1070,7 +1070,7 @@ make_cmd.o: command.h ${BASHINCDIR}/stdc.h general.h xmalloc.h error.h flags.h m
1070 make_cmd.o: variables.h arrayfunc.h conftypes.h array.h hashlib.h subst.h input.h externs.h
1071 make_cmd.o: jobs.h quit.h sig.h siglist.h syntax.h dispose_cmd.h parser.h
1072 make_cmd.o: ${BASHINCDIR}/shmbutil.h ${BASHINCDIR}/shmbchar.h ${BASHINCDIR}/ocache.h
1073
-
No equivalent source code line in the reference code can be identified.
-make_cmd.o: shell.h execute_cmd.h
1073
-
+make_cmd.o: shell.h execute_cmd.h pathnames.h
1074 y.tab.o: config.h bashtypes.h bashansi.h ${BASHINCDIR}/ansi_stdlib.h ${BASHINCDIR}/memalloc.h
1075 y.tab.o: shell.h syntax.h config.h bashjmp.h ${BASHINCDIR}/posixjmp.h command.h ${BASHINCDIR}/stdc.h error.h
1076 y.tab.o: general.h xmalloc.h bashtypes.h variables.h arrayfunc.h conftypes.h array.h hashlib.h

Modified File: arrayfunc.c

LineTestsDifference Output
diff --git a/arrayfunc.c b/arrayfunc.c
index a7c7ec1e..10b2b06a 100644
--- a/arrayfunc.c
+++ b/arrayfunc.c
@@ -44,8 +44,8 @@
44 once, when performing variable expansion. */
45 int assoc_expand_once = 0;
46
47
-
No equivalent source code line in the reference code can be identified.
-/* Ditto for indexed array subscripts */
48
-
No equivalent source code line in the reference code can be identified.
-int array_expand_once = 1;
47
-
+/* Ditto for indexed array subscripts -- currently unused */
48
-
+int array_expand_once = 0;
49
50 static SHELL_VAR *bind_array_var_internal __P((SHELL_VAR *, arrayind_t, char *, char *, int));
51 static SHELL_VAR *assign_array_element_internal __P((SHELL_VAR *, char *, char *, char *, int, char *, int));

Modified File: builtins/read.def

LineTestsDifference Output
diff --git a/builtins/read.def b/builtins/read.def
index f769c5b0..45772273 100644
--- a/builtins/read.def
+++ b/builtins/read.def
@@ -585,6 +585,7 @@ read_builtin (list)
585 }
586
587 reading = 1;
588
1
Executed by:
  • Self test
+ CHECK_ALRM;
588 ➡ 589 if (unbuffered_read == 2)
589 ➡ 590 retval = posixly_correct ? zreadintr (fd, &c, 1) : zreadn (fd, &c, nchars - nr);
590 ➡ 591 else if (unbuffered_read)

Modified File: config-top.h

LineTestsDifference Output
diff --git a/config-top.h b/config-top.h
index e1f97698..3769625b 100644
--- a/config-top.h
+++ b/config-top.h
@@ -53,7 +53,7 @@
53 /* Define DONT_REPORT_SIGTERM if you don't want to see `Terminates' message
54 when a job exits due to SIGTERM, since that's the default signal sent
55 by the kill builtin. */
56
-
No equivalent source code line in the reference code can be identified.
-/* #define DONT_REPORT_SIGTERM */
56
-
+#define DONT_REPORT_SIGTERM
57
58 /* Define DONT_REPORT_BROKEN_PIPE_WRITE_ERRORS if you don't want builtins
59 like `echo' and `printf' to report errors when output does not succeed

Modified File: configure

LineTestsDifference Output
diff --git a/configure b/configure
index b9c01296..47fd47ce 100755
--- a/configure
+++ b/configure
@@ -1,7 +1,7 @@
1 #! /bin/sh
2
-
No equivalent source code line in the reference code can be identified.
-# From configure.ac for Bash 4.4, version 4.089.
2
-
+# From configure.ac for Bash 5.0, version 4.090.
3 # Guess values for system-dependent variables and create Makefiles.
4
-
No equivalent source code line in the reference code can be identified.
-# Generated by GNU Autoconf 2.69 for bash 4.4-maint.
4
-
+# Generated by GNU Autoconf 2.69 for bash 5.0-alpha.
5 #
6 # Report bugs to <bug-bash@gnu.org>.
7 #
@@ -581,8 +581,8 @@ MAKEFLAGS=
581 # Identity of this package.
582 PACKAGE_NAME='bash'
583 PACKAGE_TARNAME='bash'
584
-
No equivalent source code line in the reference code can be identified.
-PACKAGE_VERSION='4.4-maint'
585
-
No equivalent source code line in the reference code can be identified.
-PACKAGE_STRING='bash 4.4-maint'
584
-
+PACKAGE_VERSION='5.0-alpha'
585
-
+PACKAGE_STRING='bash 5.0-alpha'
586 PACKAGE_BUGREPORT='bug-bash@gnu.org'
587 PACKAGE_URL=''
588
@@ -1394,7 +1394,7 @@ if test "$ac_init_help" = "long"; then
1394 # Omit some internal or obsolete options to make the list less imposing.
1395 # This message is too long to be a string in the A/UX 3.1 sh.
1396 cat <<_ACEOF
1397
-
No equivalent source code line in the reference code can be identified.
-\`configure' configures bash 4.4-maint to adapt to many kinds of systems.
1397
-
+\`configure' configures bash 5.0-alpha to adapt to many kinds of systems.
1398
1399 Usage: $0 [OPTION]... [VAR=VALUE]...
1400
@@ -1459,7 +1459,7 @@ fi
1459
1460 if test -n "$ac_init_help"; then
1461 case $ac_init_help in
1462
-
No equivalent source code line in the reference code can be identified.
- short | recursive ) echo "Configuration of bash 4.4-maint:";;
1462
-
+ short | recursive ) echo "Configuration of bash 5.0-alpha:";;
1463 esac
1464 cat <<\_ACEOF
1465
@@ -1655,7 +1655,7 @@ fi
1655 test -n "$ac_init_help" && exit $ac_status
1656 if $ac_init_version; then
1657 cat <<\_ACEOF
1658
-
No equivalent source code line in the reference code can be identified.
-bash configure 4.4-maint
1658
-
+bash configure 5.0-alpha
1659 generated by GNU Autoconf 2.69
1660
1661 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2364,7 +2364,7 @@ cat >config.log <<_ACEOF
2364 This file contains any messages produced by compilers while
2365 running configure, to aid debugging if configure makes a mistake.
2366
2367
-
No equivalent source code line in the reference code can be identified.
-It was created by bash $as_me 4.4-maint, which was
2367
-
+It was created by bash $as_me 5.0-alpha, which was
2368 generated by GNU Autoconf 2.69. Invocation command line was
2369
2370 $ $0 $@
@@ -2758,8 +2758,8 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2758 ac_config_headers="$ac_config_headers config.h"
2759
2760
2761
-
No equivalent source code line in the reference code can be identified.
-BASHVERS=4.4
2762
-
No equivalent source code line in the reference code can be identified.
-RELSTATUS=maint
2761
-
+BASHVERS=5.0
2762
-
+RELSTATUS=alpha
2763
2764 case "$RELSTATUS" in
2765 alp*|bet*|dev*|rc*|releng*|maint*) DEBUG='-DDEBUG' MALLOC_DEBUG='-DMALLOC_DEBUG' ;;
@@ -16814,7 +16814,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16814 # report actual input values of CONFIG_FILES etc. instead of their
16815 # values after options handling.
16816 ac_log="
16817
-
No equivalent source code line in the reference code can be identified.
-This file was extended by bash $as_me 4.4-maint, which was
16817
-
+This file was extended by bash $as_me 5.0-alpha, which was
16818 generated by GNU Autoconf 2.69. Invocation command line was
16819
16820 CONFIG_FILES = $CONFIG_FILES
@@ -16880,7 +16880,7 @@ _ACEOF
16880 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16881 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
16882 ac_cs_version="\\
16883
-
No equivalent source code line in the reference code can be identified.
-bash config.status 4.4-maint
16883
-
+bash config.status 5.0-alpha
16884 configured by $0, generated by GNU Autoconf 2.69,
16885 with options \\"\$ac_cs_config\\"
16886

Modified File: configure.ac

LineTestsDifference Output
diff --git a/configure.ac b/configure.ac
index 5080265a..43da66fc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -21,10 +21,10 @@ dnl Process this file with autoconf to produce a configure script.
21 # You should have received a copy of the GNU General Public License
22 # along with this program. If not, see <http://www.gnu.org/licenses/>.
23
24
-
No equivalent source code line in the reference code can be identified.
-AC_REVISION([for Bash 4.4, version 4.089])dnl
24
-
+AC_REVISION([for Bash 5.0, version 4.090])dnl
25
26
-
No equivalent source code line in the reference code can be identified.
-define(bashvers, 4.4)
27
-
No equivalent source code line in the reference code can be identified.
-define(relstatus, maint)
26
-
+define(bashvers, 5.0)
27
-
+define(relstatus, alpha)
28
29 AC_INIT([bash], bashvers-relstatus, [bug-bash@gnu.org])
30

Modified File: doc/bash.1

LineTestsDifference Output
diff --git a/doc/bash.1 b/doc/bash.1
index 1c72510a..aa77e883 100644
--- a/doc/bash.1
+++ b/doc/bash.1
@@ -5,12 +5,12 @@
5 .\" Case Western Reserve University
6 .\" chet.ramey@case.edu
7 .\"
8
-
No equivalent source code line in the reference code can be identified.
-.\" Last Change: Thu Jan 25 10:51:45 EST 2018
8
-
+.\" Last Change: Wed Jan 31 11:23:23 EST 2018
9 .\"
10 .\" bash_builtins, strip all but Built-Ins section
11 .if \n(zZ=1 .ig zZ
12 .if \n(zY=1 .ig zY
13
-
No equivalent source code line in the reference code can be identified.
-.TH BASH 1 "2018 January 25" "GNU Bash 4.4"
13
-
+.TH BASH 1 "2018 January 31" "GNU Bash 4.4"
14 .\"
15 .\" There's some problem with having a `@'
16 .\" in a tagged paragraph with the BSD man macros.
@@ -9691,6 +9691,11 @@ The list of \fBshopt\fP options is:
9691 .if n .sp 1v
9692 .PD 0
9693 .TP 8
9694
-
+.B assoc_expand_once
9695
-
+If set, the shell suppresses multiple evaluation of associative array
9696
-
+subscripts during arithmetic expression evaluation and while executing
9697
-
+builtins that can perform variable assignments.
9698
-
+.TP 8
9694 ➡ 9699 .B autocd
9695 ➡ 9700 If set, a command name that is the name of a directory is executed as if
9696 ➡ 9701 it were the argument to the \fBcd\fP command.

Modified File: doc/bashref.texi

LineTestsDifference Output
diff --git a/doc/bashref.texi b/doc/bashref.texi
index cf02af6b..bc3c2649 100644
--- a/doc/bashref.texi
+++ b/doc/bashref.texi
@@ -3605,7 +3605,7 @@ The @option{-d} option causes the shell to forget the remembered location
3605 of each @var{name}.
3606 If the @option{-t} option is supplied, the full pathname to which each
3607 @var{name} corresponds is printed. If multiple @var{name} arguments are
3608
-
No equivalent source code line in the reference code can be identified.
-supplied with @option{-t} the @var{name} is printed before the hashed
3608
-
+supplied with @option{-t}, the @var{name} is printed before the hashed
3609 full pathname.
3610 The @option{-l} option causes output to be displayed in a format
3611 that may be reused as input.
@@ -5097,6 +5097,11 @@ option.
5097 The list of @code{shopt} options is:
5098 @table @code
5099
5100
-
+@item assoc_expand_once
5101
-
+If set, the shell suppresses multiple evaluation of associative array
5102
-
+subscripts during arithmetic expression evaluation and while executing
5103
-
+builtins that can perform variable assignments.
5104
-
+
5100 ➡ 5105 @item autocd
5101 ➡ 5106 If set, a command name that is the name of a directory is executed as if
5102 ➡ 5107 it were the argument to the @code{cd} command.

Modified File: doc/version.texi

LineTestsDifference Output
diff --git a/doc/version.texi b/doc/version.texi
index b934a1a3..bad22734 100644
--- a/doc/version.texi
+++ b/doc/version.texi
@@ -2,10 +2,10 @@
2 Copyright (C) 1988-2018 Free Software Foundation, Inc.
3 @end ignore
4
5
-
No equivalent source code line in the reference code can be identified.
-@set LASTCHANGE Thu Jan 25 10:51:29 EST 2018
5
-
+@set LASTCHANGE Wed Jan 31 11:23:04 EST 2018
6
7 @set EDITION 4.4
8 @set VERSION 4.4
9
10
-
No equivalent source code line in the reference code can be identified.
-@set UPDATED 25 January 2018
10
-
+@set UPDATED 31 January 2018
11 @set UPDATED-MONTH January 2018

Modified File: lib/readline/display.c

LineTestsDifference Output
diff --git a/lib/readline/display.c b/lib/readline/display.c
index 5b2663a8..75019efc 100644
--- a/lib/readline/display.c
+++ b/lib/readline/display.c
@@ -1168,15 +1168,16 @@ rl_redisplay (void)
1168 wrap_offset. */
1169 if (linenum == 0 && (mb_cur_max > 1 && rl_byte_oriented == 0) && OLD_CPOS_IN_PROMPT())
1170 _rl_last_c_pos -= prompt_invis_chars_first_line; /* XXX - was wrap_offset */
1171
0
- else if (linenum == prompt_last_screen_line &&
1171
0
+ else if (cpos_adjusted == 0 &&
1172
0
+ linenum == prompt_last_screen_line &&
1172 ➡ 1173 prompt_physical_chars > _rl_screenwidth &&
1173 ➡ 1174 (mb_cur_max > 1 && rl_byte_oriented == 0) &&
1174
0
- cpos_adjusted == 0 &&
1175 _rl_last_c_pos != o_cpos &&
1176 _rl_last_c_pos > (prompt_last_invisible - _rl_screenwidth - prompt_invis_chars_first_line)) /* XXX - rethink this last one */
1177 /* This assumes that all the invisible characters are split
1178 between the first and last lines of the prompt, if the
1179 prompt consumes more than two lines. It's usually right */
1180
-
+ /* XXX - not sure this is ever executed */
1180 ➡ 1181 _rl_last_c_pos -= (wrap_offset-prompt_invis_chars_first_line);
1181 ➡ 1182
1182 ➡ 1183 /* If this is the line with the prompt, we might need to

Modified File: lib/readline/doc/hsuser.texi

LineTestsDifference Output
diff --git a/lib/readline/doc/hsuser.texi b/lib/readline/doc/hsuser.texi
index 483a2a04..1c25f813 100644
--- a/lib/readline/doc/hsuser.texi
+++ b/lib/readline/doc/hsuser.texi
@@ -124,7 +124,7 @@ The @code{lithist}
124 shell option causes the shell to save the command with embedded newlines
125 instead of semicolons.
126 The @code{shopt} builtin is used to set these options.
127
-
No equivalent source code line in the reference code can be identified.
-@xref{Bash Builtins}, for a description of @code{shopt}.
127
-
+@xref{The Shopt Builtin}, for a description of @code{shopt}.
128
129 @node Bash History Builtins
130 @section Bash History Builtins
@@ -286,7 +286,7 @@ in a double-quoted string.
286
287 @ifset BashFeatures
288 Several shell options settable with the @code{shopt}
289
-
No equivalent source code line in the reference code can be identified.
-builtin (@pxref{Bash Builtins}) may be used to tailor
289
-
+builtin (@pxref{The Shopt Builtin}) may be used to tailor
290 the behavior of history expansion. If the
291 @code{histverify} shell option is enabled, and Readline
292 is being used, history substitutions are not immediately passed to

Modified File: lib/readline/rlprivate.h

LineTestsDifference Output
diff --git a/lib/readline/rlprivate.h b/lib/readline/rlprivate.h
index 1d90c2c8..05ee9302 100644
--- a/lib/readline/rlprivate.h
+++ b/lib/readline/rlprivate.h
@@ -307,7 +307,7 @@ extern int _rl_search_getchar PARAMS((_rl_search_cxt *));
307 #define BRACK_PASTE_SLEN 6
308
309 #define BRACK_PASTE_INIT "\033[?2004h"
310
-
No equivalent source code line in the reference code can be identified.
-#define BRACK_PASTE_FINI "\033[?2004l"
310
-
+#define BRACK_PASTE_FINI "\033[?2004l\r"
311
312 /* macro.c */
313 extern void _rl_with_macro_input PARAMS((char *));

Modified File: lib/sh/zread.c

LineTestsDifference Output
diff --git a/lib/sh/zread.c b/lib/sh/zread.c
index 14b66381..8b7ecedf 100644
--- a/lib/sh/zread.c
+++ b/lib/sh/zread.c
@@ -53,6 +53,7 @@ zread (fd, buf, len)
53 {
54 ssize_t r;
55
56
1
Executed by:
  • Self test
+ check_signals (); /* check for signals before a blocking read */
56 ➡ 57 while ((r = read (fd, buf, len)) < 0 && errno == EINTR)
57 ➡ 58 /* XXX - bash-5.0 */
58 ➡ 59 /* We check executing_builtin and run traps here for backwards compatibility */
@@ -103,6 +104,7 @@ zreadintr (fd, buf, len)
103 ➡ 104 char *buf;
104 ➡ 105 size_t len;
105 ➡ 106 {
107
0
+ check_signals ();
106 ➡ 108 return (read (fd, buf, len));
107 ➡ 109 }
108 ➡ 110

Generated by Squish Coco 4.1.2