Date: Sun, 7 Jun 2015 13:18:14 GMT From: def@FreeBSD.org To: svn-soc-all@FreeBSD.org Subject: socsvn commit: r286780 - in soc2013/def/crashdump-head/sys: kern sys Message-ID: <201506071318.t57DIExd027338@socsvn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: def Date: Sun Jun 7 13:18:13 2015 New Revision: 286780 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=286780 Log: Return proper size when kernel dump key is NULL. Modified: soc2013/def/crashdump-head/sys/kern/kern_shutdown.c soc2013/def/crashdump-head/sys/sys/kerneldump.h Modified: soc2013/def/crashdump-head/sys/kern/kern_shutdown.c ============================================================================== --- soc2013/def/crashdump-head/sys/kern/kern_shutdown.c Sun Jun 7 13:15:29 2015 (r286779) +++ soc2013/def/crashdump-head/sys/kern/kern_shutdown.c Sun Jun 7 13:18:13 2015 (r286780) @@ -71,6 +71,8 @@ #include <sys/vnode.h> #include <sys/watchdog.h> +#include <crypto/rijndael/rijndael-api-fst.h> + #include <ddb/ddb.h> #include <machine/cpu.h> Modified: soc2013/def/crashdump-head/sys/sys/kerneldump.h ============================================================================== --- soc2013/def/crashdump-head/sys/sys/kerneldump.h Sun Jun 7 13:15:29 2015 (r286779) +++ soc2013/def/crashdump-head/sys/sys/kerneldump.h Sun Jun 7 13:18:13 2015 (r286780) @@ -38,11 +38,9 @@ #ifndef _SYS_KERNELDUMP_H #define _SYS_KERNELDUMP_H -#include <machine/endian.h> +#include <sys/param.h> -#ifdef _KERNEL -#include <crypto/rijndael/rijndael-api-fst.h> -#endif +#include <machine/endian.h> #if BYTE_ORDER == LITTLE_ENDIAN #define dtoh32(x) __bswap32(x) @@ -105,6 +103,8 @@ kerneldumpkey_size(struct kerneldumpkey *kdk) { + if (kdk == NULL) + return (0); return (kdk->kdk_size); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201506071318.t57DIExd027338>