Hello community,
here is the log from the commit of package bash for openSUSE:Factory
checked in at Wed Mar 9 13:18:30 CET 2011.
--------
--- bash/bash.changes 2011-03-08 18:49:06.000000000 +0100
+++ /mounts/work_src_done/STABLE/bash/bash.changes 2011-03-09 12:02:19.000000000 +0100
@@ -1,0 +2,7 @@
+Wed Mar 9 12:00:48 CET 2011 - werner@suse.de
+
+- Avoid siglongjmp, compare with
+ http://lists.gnu.org/archive/html/bug-bash/2011-03/msg00070.html
+ use temprary solution from Chet
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
bash-4.2-history-myown.dif.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ bash.spec ++++++
--- /var/tmp/diff_new_pack.6PTvHb/_old 2011-03-09 13:07:35.000000000 +0100
+++ /var/tmp/diff_new_pack.6PTvHb/_new 2011-03-09 13:07:35.000000000 +0100
@@ -37,7 +37,7 @@
%endif
AutoReqProv: on
Version: 4.2
-Release: 1
+Release: 2
Summary: The GNU Bourne-Again Shell
Url: http://www.gnu.org/software/bash/bash.html
Source0: ftp://ftp.gnu.org/gnu/bash/bash-%{bash_vers}.tar.bz2
@@ -49,6 +49,11 @@
Source6: dot.profile
Source7: bash-rpmlintrc
Source8: baselibs.conf
+# Remember unsafe method, compare with
+# http://lists.gnu.org/archive/html/bug-bash/2011-03/msg00070.html
+# http://lists.gnu.org/archive/html/bug-bash/2011-03/msg00071.html
+# http://lists.gnu.org/archive/html/bug-bash/2011-03/msg00073.html
+Source9: bash-4.2-history-myown.dif.bz2
Patch0: bash-%{bash_vers}.dif
Patch1: bash-2.03-manual.patch
Patch2: bash-4.0-security.patch
@@ -102,7 +107,7 @@
Provides: bash:%{_infodir}/bash.info.gz
PreReq: %install_info_prereq
Version: 4.2
-Release: 1
+Release: 2
AutoReqProv: on
%if %suse_version > 1120
BuildArch: noarch
@@ -138,7 +143,7 @@
Summary: Include Files mandatory for Development of bash loadable builtins
Group: Development/Languages/C and C++
Version: 4.2
-Release: 1
+Release: 2
AutoReqProv: on
%description -n bash-devel
@@ -158,7 +163,7 @@
Summary: Loadable bash builtins
Group: System/Shells
Version: 4.2
-Release: 1
+Release: 2
AutoReqProv: on
%description -n bash-loadables
@@ -227,7 +232,7 @@
Group: System/Libraries
Provides: bash:/%{_lib}/libreadline.so.%{rl_major}
Version: 6.2
-Release: 1
+Release: 2
%if %suse_version > 1020
Recommends: readline-doc = %{version}
%endif
@@ -258,7 +263,7 @@
Group: Development/Libraries/C and C++
Provides: bash:%{_libdir}/libreadline.a
Version: 6.2
-Release: 1
+Release: 2
Requires: libreadline6 = %{version}
Requires: ncurses-devel
%if %suse_version > 1020
@@ -289,7 +294,7 @@
Provides: readline:%{_infodir}/readline.info.gz
PreReq: %install_info_prereq
Version: 6.2
-Release: 1
+Release: 2
AutoReqProv: on
%if %suse_version > 1120
BuildArch: noarch
++++++ bash-4.2-history-myown.dif.bz2 ++++++
--- shell.c
+++ shell.c 2011-03-08 17:25:55.160426342 +0000
@@ -261,6 +261,11 @@ static const struct {
{ (char *)0x0, Int, (int *)0x0, (char **)0x0 }
};
+#if defined (HAVE_POSIX_SIGSETJMP)
+volatile procenv_t terminating_now;
+volatile sig_atomic_t jump_with_sig;
+#endif /* HAVE_POSIX_SIGSETJMP */
+
/* These are extern so execute_simple_command can set them, and then
longjmp back to main to execute a shell script, instead of calling
main () again and resulting in indefinite, possibly fatal, stack
@@ -379,6 +384,39 @@ main (argc, argv, env)
if (code)
exit (2);
+#if defined (HAVE_POSIX_SIGSETJMP)
+ /* Catch signals here */
+ if (sigsetjmp (terminating_now, 1))
+ {
+ int sig = jump_with_sig;
+
+ /* I don't believe this condition ever tests true. */
+ if (sig == SIGINT && signal_is_trapped (SIGINT))
+ run_interrupt_trap ();
+
+# if defined (HISTORY)
+ if (interactive_shell && sig != SIGABRT)
+ maybe_save_shell_history ();
+# endif /* HISTORY */
+
+# if defined (JOB_CONTROL)
+ if (sig == SIGHUP && (interactive || (subshell_environment & (SUBSHELL_COMSUB|SUBSHELL_PROCSUB))))
+ hangup_all_jobs ();
+ end_job_control ();
+# endif /* JOB_CONTROL */
+
+# if defined (PROCESS_SUBSTITUTION)
+ unlink_fifo_list ();
+# endif /* PROCESS_SUBSTITUTION */
+
+ run_exit_trap ();
+ set_signal_handler (sig, SIG_DFL);
+ kill (getpid (), sig);
+ _exit(0);
+ }
+ jump_with_sig = 0;
+#endif /* HAVE_POSIX_SIGSETJMP */
+
xtrace_init ();
#if defined (USING_BASH_MALLOC) && defined (DEBUG) && !defined (DISABLE_MALLOC_WRAPPERS)
--- sig.c
+++ sig.c 2011-03-08 17:26:31.627928783 +0000
@@ -503,7 +503,7 @@ termsig_sighandler (sig)
/* XXX - should this also trigger when interrupt_immediately is set? */
if (terminate_immediately)
{
-#if defined (HISTORY)
+#if defined (HISTORY) && ! defined (HAVE_POSIX_SIGSETJMP)
/* XXX - will inhibit history file being written */
history_lines_this_session = 0;
#endif
@@ -514,6 +514,11 @@ termsig_sighandler (sig)
SIGRETURN (0);
}
+#if defined (HAVE_POSIX_SIGSETJMP)
+extern volatile procenv_t terminating_now;
+extern volatile sig_atomic_t jump_with_sig;
+#endif /* HAVE_POSIX_SIGSETJMP */
+
void
termsig_handler (sig)
int sig;
@@ -528,32 +533,39 @@ termsig_handler (sig)
handling_termsig = 1;
terminating_signal = 0; /* keep macro from re-testing true. */
+#if ! defined (HAVE_POSIX_SIGSETJMP)
/* I don't believe this condition ever tests true. */
if (sig == SIGINT && signal_is_trapped (SIGINT))
run_interrupt_trap ();
-#if defined (HISTORY)
+# if defined (HISTORY)
if (interactive_shell && sig != SIGABRT)
maybe_save_shell_history ();
-#endif /* HISTORY */
+# endif /* HISTORY */
-#if defined (JOB_CONTROL)
+# if defined (JOB_CONTROL)
if (sig == SIGHUP && (interactive || (subshell_environment & (SUBSHELL_COMSUB|SUBSHELL_PROCSUB))))
hangup_all_jobs ();
end_job_control ();
-#endif /* JOB_CONTROL */
+# endif /* JOB_CONTROL */
-#if defined (PROCESS_SUBSTITUTION)
+# if defined (PROCESS_SUBSTITUTION)
unlink_fifo_list ();
-#endif /* PROCESS_SUBSTITUTION */
+# endif /* PROCESS_SUBSTITUTION */
+#endif /* ! HAVE_POSIX_SIGSETJMP */
/* Reset execution context */
loop_level = continuing = breaking = funcnest = 0;
executing_list = comsub_ignore_return = return_catch_flag = 0;
+#if defined (HAVE_POSIX_SIGSETJMP)
+ jump_with_sig = sig;
+ siglongjmp(terminating_now, 1);
+#else /* ! HAVE_POSIX_SIGSETJMP */
run_exit_trap ();
set_signal_handler (sig, SIG_DFL);
kill (getpid (), sig);
+#endif /* ! HAVE_POSIX_SIGSETJMP */
}
/* What we really do when SIGINT occurs. */
++++++ bash-4.2-history.dif ++++++
--- /var/tmp/diff_new_pack.6PTvHb/_old 2011-03-09 13:07:35.000000000 +0100
+++ /var/tmp/diff_new_pack.6PTvHb/_new 2011-03-09 13:07:35.000000000 +0100
@@ -1,123 +1,34 @@
---- shell.c
-+++ shell.c 2011-03-08 17:25:55.160426342 +0000
-@@ -261,6 +261,11 @@ static const struct {
- { (char *)0x0, Int, (int *)0x0, (char **)0x0 }
- };
-
-+#if defined (HAVE_POSIX_SIGSETJMP)
-+volatile procenv_t terminating_now;
-+volatile sig_atomic_t jump_with_sig;
-+#endif /* HAVE_POSIX_SIGSETJMP */
-+
- /* These are extern so execute_simple_command can set them, and then
- longjmp back to main to execute a shell script, instead of calling
- main () again and resulting in indefinite, possibly fatal, stack
-@@ -379,6 +384,39 @@ main (argc, argv, env)
- if (code)
- exit (2);
-
-+#if defined (HAVE_POSIX_SIGSETJMP)
-+ /* Catch signals here */
-+ if (sigsetjmp (terminating_now, 1))
-+ {
-+ int sig = jump_with_sig;
-+
-+ /* I don't believe this condition ever tests true. */
-+ if (sig == SIGINT && signal_is_trapped (SIGINT))
-+ run_interrupt_trap ();
-+
-+# if defined (HISTORY)
-+ if (interactive_shell && sig != SIGABRT)
-+ maybe_save_shell_history ();
-+# endif /* HISTORY */
-+
-+# if defined (JOB_CONTROL)
-+ if (sig == SIGHUP && (interactive || (subshell_environment & (SUBSHELL_COMSUB|SUBSHELL_PROCSUB))))
-+ hangup_all_jobs ();
-+ end_job_control ();
-+# endif /* JOB_CONTROL */
-+
-+# if defined (PROCESS_SUBSTITUTION)
-+ unlink_fifo_list ();
-+# endif /* PROCESS_SUBSTITUTION */
-+
-+ run_exit_trap ();
-+ set_signal_handler (sig, SIG_DFL);
-+ kill (getpid (), sig);
-+ _exit(0);
-+ }
-+ jump_with_sig = 0;
-+#endif /* HAVE_POSIX_SIGSETJMP */
-+
- xtrace_init ();
-
- #if defined (USING_BASH_MALLOC) && defined (DEBUG) && !defined (DISABLE_MALLOC_WRAPPERS)
---- sig.c
-+++ sig.c 2011-03-08 17:26:31.627928783 +0000
-@@ -503,7 +503,7 @@ termsig_sighandler (sig)
- /* XXX - should this also trigger when interrupt_immediately is set? */
- if (terminate_immediately)
- {
--#if defined (HISTORY)
-+#if defined (HISTORY) && ! defined (HAVE_POSIX_SIGSETJMP)
- /* XXX - will inhibit history file being written */
- history_lines_this_session = 0;
- #endif
-@@ -514,6 +514,11 @@ termsig_sighandler (sig)
- SIGRETURN (0);
- }
-
-+#if defined (HAVE_POSIX_SIGSETJMP)
-+extern volatile procenv_t terminating_now;
-+extern volatile sig_atomic_t jump_with_sig;
-+#endif /* HAVE_POSIX_SIGSETJMP */
-+
- void
- termsig_handler (sig)
- int sig;
-@@ -528,32 +533,39 @@ termsig_handler (sig)
- handling_termsig = 1;
- terminating_signal = 0; /* keep macro from re-testing true. */
-
-+#if ! defined (HAVE_POSIX_SIGSETJMP)
- /* I don't believe this condition ever tests true. */
- if (sig == SIGINT && signal_is_trapped (SIGINT))
- run_interrupt_trap ();
-
--#if defined (HISTORY)
-+# if defined (HISTORY)
- if (interactive_shell && sig != SIGABRT)
- maybe_save_shell_history ();
--#endif /* HISTORY */
-+# endif /* HISTORY */
-
--#if defined (JOB_CONTROL)
-+# if defined (JOB_CONTROL)
- if (sig == SIGHUP && (interactive || (subshell_environment & (SUBSHELL_COMSUB|SUBSHELL_PROCSUB))))
- hangup_all_jobs ();
- end_job_control ();
--#endif /* JOB_CONTROL */
-+# endif /* JOB_CONTROL */
-
--#if defined (PROCESS_SUBSTITUTION)
-+# if defined (PROCESS_SUBSTITUTION)
- unlink_fifo_list ();
--#endif /* PROCESS_SUBSTITUTION */
-+# endif /* PROCESS_SUBSTITUTION */
-+#endif /* ! HAVE_POSIX_SIGSETJMP */
-
- /* Reset execution context */
- loop_level = continuing = breaking = funcnest = 0;
- executing_list = comsub_ignore_return = return_catch_flag = 0;
-
-+#if defined (HAVE_POSIX_SIGSETJMP)
-+ jump_with_sig = sig;
-+ siglongjmp(terminating_now, 1);
-+#else /* ! HAVE_POSIX_SIGSETJMP */
- run_exit_trap ();
- set_signal_handler (sig, SIG_DFL);
- kill (getpid (), sig);
-+#endif /* ! HAVE_POSIX_SIGSETJMP */
- }
-
- /* What we really do when SIGINT occurs. */
+*** ../bash-4.2-patched/sig.c Tue Nov 23 08:21:22 2010
+--- sig.c Tue Mar 8 21:28:32 2011
+***************
+*** 47,50 ****
+--- 47,51 ----
+ #if defined (READLINE)
+ # include "bashline.h"
++ # include