RE: [PATCH 2/2] blkid: introduce symbolic names for different blkid exit codes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Karel Zak wrote:

> On Wed, May 16, 2012 at 11:24:09AM +0200, Petr Uzel wrote:
> > Hmm, the return value depends only on the last argument (device). I
> > don't think this is intentional. Karel?
> > 
> >         # blkid -p /dev/sda /dev/sdb ; echo $?
> >         /dev/sda: PTTYPE="gpt" 
> >         error: /dev/sdb: No such file or directory
> >         2
> >         
> >         # blkid -p /dev/sdb /dev/sda ; echo $?
> >         error: /dev/sdb: No such file or directory
> >         /dev/sda: PTTYPE="gpt" 
> >         0
> 
>  It would be better to break the loop and exit after first error.

Then we can already exit() from lowprobe_device(),
and thus BLKID_EXIT_* will have become pure "exit codes" ... ;-)

Have a nice day,
Berny--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux