Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

From: Alan Cox
Date: Wed Nov 07 2007 - 10:12:51 EST


> Users are used to work on characters, not on bytes.

Absolutely true - but completely missing the point.

When I open a UTF-8 file name as displayed by nautilus the kernel does
byte comparisons. The kernel doesn't care what character set is in use.

> > So you either implement "match one byte", or you go crazy. It's that
> > simple.
>
> Sure, you can limit what is possible and what not.

If your regexps are reasonably complete you just have to turn the unicode
match into a byte match. That is a user interface problem - in user space.

Alan
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/