Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 6 Dec 2018 20:28:09 +0000 (UTC)
From:      Ian Lepore <ian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r341651 - head/stand/i386/loader
Message-ID:  <201812062028.wB6KS9DS046795@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ian
Date: Thu Dec  6 20:28:09 2018
New Revision: 341651
URL: https://svnweb.freebsd.org/changeset/base/341651

Log:
  Don't reference zfs-specific variables if LOADER_ZFS_SUPPORT is undefined
  because the variables will be undefined too.
  
  Reported by:	sjg@
  Pointy hat:	ian@

Modified:
  head/stand/i386/loader/main.c

Modified: head/stand/i386/loader/main.c
==============================================================================
--- head/stand/i386/loader/main.c	Thu Dec  6 20:15:54 2018	(r341650)
+++ head/stand/i386/loader/main.c	Thu Dec  6 20:28:09 2018	(r341651)
@@ -195,11 +195,14 @@ main(void)
      */
 #define	LEGACY_GELI_ARGS_SIZE	260	/* This can never change */
 
+#ifdef LOADER_ZFS_SUPPORT
     if (zargs != NULL) {
 	if (zargs->size > offsetof(struct zfs_boot_args, gelidata)) {
 	    gbdata = &zargs->gelidata;
 	}
-    } else if ((kargs->bootflags & KARGS_FLAGS_EXTARG) != 0) {
+    } else
+#endif /* LOADER_ZFS_SUPPORT */
+	   if ((kargs->bootflags & KARGS_FLAGS_EXTARG) != 0) {
 	gargs = (struct geli_boot_args *)(kargs + 1);
 	if ((kargs->bootflags & KARGS_FLAGS_GELI) ||
 	    gargs->size == LEGACY_GELI_ARGS_SIZE) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201812062028.wB6KS9DS046795>