Page MenuHomeFreeBSD

devmatch(8): Respect mask field when matching strings.
ClosedPublic

Authored by wulf on Oct 17 2020, 12:19 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 22 2024, 11:03 PM
Unknown Object (File)
Mar 22 2024, 11:03 PM
Unknown Object (File)
Mar 22 2024, 11:03 PM
Unknown Object (File)
Mar 8 2024, 9:37 AM
Unknown Object (File)
Jan 11 2024, 10:44 PM
Unknown Object (File)
Jan 7 2024, 1:06 AM
Unknown Object (File)
Jan 7 2024, 1:06 AM
Unknown Object (File)
Jan 7 2024, 1:06 AM
Subscribers
None

Details

Summary

Currently, only integer fields of descriptor string can be masked out for matching. This patch adds support for masking of 'Z' type field.

While here, add debug output for this action.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

wulf requested review of this revision.Oct 17 2020, 12:19 AM
wulf created this revision.
sbin/devmatch/devmatch.c
352

When would bit by < 0?

sbin/devmatch/devmatch.c
352

It starts iterating from -1. May be the first field is dedicated to mask itself?

sbin/devmatch/devmatch.c
352

Yes.... I don't think the check is needed, but I'm not sure

sbin/devmatch/devmatch.c
352

I borrowed the check from integer case to not introduce new bugs.

imp added inline comments.
sbin/devmatch/devmatch.c
352

I borrowed the check from integer case to not introduce new bugs.

Fair enough. Keep it...

This revision is now accepted and ready to land.Oct 17 2020, 12:53 AM