svn commit: r225084 - stable/8/usr.sbin/mfiutil

John Baldwin jhb at FreeBSD.org
Mon Aug 22 18:58:00 UTC 2011


Author: jhb
Date: Mon Aug 22 18:57:59 2011
New Revision: 225084
URL: http://svn.freebsd.org/changeset/base/225084

Log:
  MFC 224495:
  Properly initialize an error variable to avoid returning uninitialized
  data when 'show drives' succeeds, often resulting in a failing exit code
  even though the command worked fine.

Modified:
  stable/8/usr.sbin/mfiutil/mfi_show.c
Directory Properties:
  stable/8/usr.sbin/mfiutil/   (props changed)

Modified: stable/8/usr.sbin/mfiutil/mfi_show.c
==============================================================================
--- stable/8/usr.sbin/mfiutil/mfi_show.c	Mon Aug 22 18:46:23 2011	(r225083)
+++ stable/8/usr.sbin/mfiutil/mfi_show.c	Mon Aug 22 18:57:59 2011	(r225084)
@@ -533,6 +533,7 @@ show_drives(int ac, char **av)
 		    MFI_DNAME_ES));
 		printf("\n");
 	}
+	error = 0;
 error:
 	free(list);
 	close(fd);


More information about the svn-src-stable mailing list