Hello community, here is the log from the commit of package crash for openSUSE:Factory checked in at 2013-12-08 19:26:18 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/crash (Old) and /work/SRC/openSUSE:Factory/.crash.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "crash" Changes: -------- --- /work/SRC/openSUSE:Factory/crash/crash.changes 2013-11-22 17:38:17.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.crash.new/crash.changes 2013-12-08 19:26:20.000000000 +0100 @@ -1,0 +2,6 @@ +Fri Dec 6 11:27:53 UTC 2013 - ptesa...@suse.cz + +- crash-compressed-booted-kernel.patch: Fix a bug that may cause + removal of the booted kernel's vmlinux image (bnc#828260). + +------------------------------------------------------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ crash.spec ++++++ --- /var/tmp/diff_new_pack.THDFuA/_old 2013-12-08 19:26:21.000000000 +0100 +++ /var/tmp/diff_new_pack.THDFuA/_new 2013-12-08 19:26:21.000000000 +0100 @@ -16,7 +16,6 @@ # -%define crash_version 7.0.3 %define whitepaper_version 2003 %define scripts_version 2008-02-08 %define gcore_version 2011-09-22 @@ -39,7 +38,7 @@ Summary: Crash utility for live systems; netdump, diskdump, LKCD or mcore dumpfiles License: GPL-3.0+ and GFDL-1.2 Group: Development/Tools/Debuggers -Version: %{crash_version} +Version: 7.0.3 Release: 0 Source: %{name}-%{version}.tar.gz Source2: crash_whitepaper-%{whitepaper_version}.tar.bz2 ++++++ crash-compressed-booted-kernel.patch ++++++ --- /var/tmp/diff_new_pack.THDFuA/_old 2013-12-08 19:26:22.000000000 +0100 +++ /var/tmp/diff_new_pack.THDFuA/_new 2013-12-08 19:26:22.000000000 +0100 @@ -1,21 +1,25 @@ +From: Petr Tesarik <ptesa...@suse.cz> +Subject: Automatically detect compressed booted kernel +References: bnc#777516, bnc#828260 +Patch-mainline: not yet + +Signed-off-by: Petr Tesarik <ptesa...@suse.cz> + --- - filesys.c | 37 ++++++++++++++++++++++++++++--------- - 1 file changed, 28 insertions(+), 9 deletions(-) + filesys.c | 26 ++++++++++++++++++++++---- + 1 file changed, 22 insertions(+), 4 deletions(-) -Index: crash-7.0.3/filesys.c -=================================================================== ---- crash-7.0.3.orig/filesys.c -+++ crash-7.0.3/filesys.c -@@ -529,6 +529,8 @@ static int +--- a/filesys.c ++++ b/filesys.c +@@ -530,6 +530,7 @@ static int find_booted_kernel(void) { char kernel[BUFSIZE]; -+ char *kernel_unpacked; + char *real_kernel; char buffer[BUFSIZE]; char **searchdirs; int i, preferred, wrapped; -@@ -578,16 +580,25 @@ find_booted_kernel(void) +@@ -579,16 +580,24 @@ find_booted_kernel(void) sprintf(kernel, "%s%s", searchdirs[i], dp->d_name); if (mount_point(kernel) || @@ -24,12 +28,8 @@ + !file_readable(kernel)) continue; -+ if (is_compressed_kernel(kernel, &kernel_unpacked)) -+ real_kernel = kernel_unpacked; -+ else { -+ kernel_unpacked = NULL; ++ if (!is_compressed_kernel(kernel, &real_kernel)) + real_kernel = kernel; -+ } + if (CRASHDEBUG(1)) fprintf(fp, "find_booted_kernel: check: %s\n", @@ -37,42 +37,34 @@ - found = match_file_string(kernel, kt->proc_version, buffer); - -+ if (!is_elf_file(real_kernel)) ++ if (!is_elf_file(real_kernel)) { ++ if (real_kernel != kernel) ++ free(real_kernel); + continue; ++ } + + found = match_file_string(real_kernel, kt->proc_version, buffer); + if (found) break; } -@@ -598,17 +609,25 @@ find_booted_kernel(void) - build_searchdirs(DESTROY, NULL); - - if (found) { -- if ((pc->namelist = (char *)malloc -- (strlen(kernel)+1)) == NULL) -+ if ((pc->namelist_orig = strdup(kernel)) == NULL) -+ error(FATAL, "booted kernel real name malloc: %s\n", -+ strerror(errno)); -+ else if ((pc->namelist = strdup(real_kernel)) == NULL) - error(FATAL, "booted kernel name malloc: %s\n", - strerror(errno)); -- else { -- strcpy(pc->namelist, kernel); -+ else +@@ -608,10 +617,19 @@ find_booted_kernel(void) if (CRASHDEBUG(1)) fprintf(fp, "find_booted_kernel: found: %s\n", pc->namelist); -+ if (kernel_unpacked) -+ free(kernel_unpacked); ++ if (real_kernel != kernel) { ++ pc->namelist_orig = pc->namelist; ++ pc->namelist = real_kernel; ++ } return TRUE; -- } -+ } -+ -+ if (kernel_unpacked) { -+ remove(kernel_unpacked); -+ if (kernel_unpacked) -+ free(kernel_unpacked); + } } ++ if (real_kernel != kernel) { ++ remove(real_kernel); ++ free(real_kernel); ++ } ++ error(INFO, + "cannot find booted kernel -- please enter namelist argument\n\n"); + return FALSE; -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org