Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Buglet in r222899 (mfiutil show drives)

3 views
Skip to first unread message

Andrew Boyer

unread,
Jul 29, 2011, 3:24:03 PM7/29/11
to
The error variable is returned uninitialized if no error occurs. I noticed because 'mfiutil -de show drives' started returning 1 for no apparent reason when I synced up to stable/8.

I looked through the rest of mfiutil and didn't see any more cases like this one.

-Andrew

Index: usr.sbin/mfiutil/mfi_show.c
===================================================================
--- usr.sbin/mfiutil/mfi_show.c (revision 224494)
+++ usr.sbin/mfiutil/mfi_show.c (working copy)
@@ -470,7 +470,7 @@
struct mfi_pd_list *list;
struct mfi_pd_info info;
u_int i, len, state_len;
- int error, fd;
+ int error = 0, fd;

if (ac != 1) {
warnx("show drives: extra arguments");

--------------------------------------------------
Andrew Boyer abo...@averesystems.com


_______________________________________________
freebs...@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-scsi
To unsubscribe, send any mail to "freebsd-scsi...@freebsd.org"

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-...@muc.de

Bjoern A. Zeeb

unread,
Jul 29, 2011, 4:31:52 PM7/29/11
to
On Jul 29, 2011, at 7:24 PM, Andrew Boyer wrote:

> The error variable is returned uninitialized if no error occurs. I noticed because 'mfiutil -de show drives' started returning 1 for no apparent reason when I synced up to stable/8.
>
> I looked through the rest of mfiutil and didn't see any more cases like this one.
>


John found that a couple of days ago; it's likely it's in the re@ queue for committing and fixing or has been fixed in head already.


> -Andrew
>
> Index: usr.sbin/mfiutil/mfi_show.c
> ===================================================================
> --- usr.sbin/mfiutil/mfi_show.c (revision 224494)
> +++ usr.sbin/mfiutil/mfi_show.c (working copy)
> @@ -470,7 +470,7 @@
> struct mfi_pd_list *list;
> struct mfi_pd_info info;
> u_int i, len, state_len;
> - int error, fd;
> + int error = 0, fd;
>
> if (ac != 1) {
> warnx("show drives: extra arguments");
>
> --------------------------------------------------
> Andrew Boyer abo...@averesystems.com
>
>
>
>

--
Bjoern A. Zeeb You have to have visions!
Stop bit received. Insert coin for new address family.

John Baldwin

unread,
Jul 29, 2011, 4:22:36 PM7/29/11
to
On Friday, July 29, 2011 3:24:03 pm Andrew Boyer wrote:
> The error variable is returned uninitialized if no error occurs. I noticed
because 'mfiutil -de show drives' started returning 1 for no apparent reason
when I synced up to stable/8.
>
> I looked through the rest of mfiutil and didn't see any more cases like this
one.
>
> -Andrew

Yeah, I have this sitting in my queue. re@ just opened up HEAD so I'll commit
it.

--
John Baldwin

0 new messages