[Toybox] [PATCH] blkid, mount: fix `blkid -L` and add support for `mount LABEL=...`

Rob Landley rob at landley.net
Fri Nov 8 01:32:16 PST 2024


On 11/6/24 14:35, Kana Steimle wrote:
> On Sat, 2024-11-02 at 23:53 -0500, Rob Landley wrote:
>> On 11/2/24 03:30, Kana Steimle wrote:
>>> Fixes `blkid -L`, and uses that to implement `mount LABEL=...`, the
>>> same way
>>> `mount UUID=...` was implemented.
>>
>> Your message got wordwrapped, including the patch itself so it needs
>> fixing up to apply it.
>>
>> Could you try again as an attachment?
>>
>> Thanks,
>>
>> Rob
 >
> Sorry for not replying sooner. For some reason gmail decided to put
> your reply in spam, so I didn't realize you responded until I thought
> to check it.

No idea what gmail's up to these days. I moved my own email off it 
earlier this year (to dreamhost's mail servers) because they yanked the 
login method I was using.

And now "patch format detection failed" because there's no header lines 
like "git format-patch -1 $HASH" produces. But I can fix that up but 
cutting and pasting the from/subject/time from your email's headers...

Your new test fails because there's no "fat32.bz2" file. (I'm assuming 
you have one?)

The if (*type=='v') test is ok for distinguishing between "we just 
checked for 'vfat' and 'iso9660' so which of the two was it", but in 
code that's run for every filesystem I'm a lot less comfortable with 
that. A new 4 letter filesystem starting with v added in future could 
theoretically trigger this non-obviously. Maybe not LIKELY ("virt" and 
"v9fs" are both network filesystems), but It's a sharp edge. If you want 
to exclude -U then I'd much prefer doing that ala:

-      if (*type=='v') show_tag("SEC_TYPE", "msdos");
+      if (*type=='v' && !FLAG(U)) show_tag("SEC_TYPE", "msdos");

The one thing I can't easily fixup here is the missing fat32.bz2. Could 
you send me that?

Thanks,

Rob


More information about the Toybox mailing list