chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
update default rules
[elogind.git]
/
udev_rules_parse.c
diff --git
a/udev_rules_parse.c
b/udev_rules_parse.c
index d527bf4bad4a51c8ee397d697124d6a0042217a7..ecb6a7be31b1133ab2a104c02dbcded411a13ba6 100644
(file)
--- a/
udev_rules_parse.c
+++ b/
udev_rules_parse.c
@@
-219,7
+219,7
@@
static int add_rule_key_pair(struct udev_rule *rule, struct key_pairs *pairs,
size_t key_len = strnlen(key, PATH_SIZE);
if (pairs->count >= PAIRS_MAX) {
size_t key_len = strnlen(key, PATH_SIZE);
if (pairs->count >= PAIRS_MAX) {
- err("skip, too many keys in a single rule");
+ err("skip, too many keys
of the same type
in a single rule");
return -1;
}
return -1;
}
@@
-322,11
+322,6
@@
static int add_to_rules(struct udev_rules *rules, char *line, const char *filena
}
if (strncasecmp(key, "ATTR", sizeof("ATTR")-1) == 0) {
}
if (strncasecmp(key, "ATTR", sizeof("ATTR")-1) == 0) {
- if (operation != KEY_OP_MATCH &&
- operation != KEY_OP_NOMATCH) {
- err("invalid ATTR operation");
- goto invalid;
- }
attr = get_key_attribute(key + sizeof("ATTR")-1);
if (attr == NULL) {
err("error parsing ATTR attribute");
attr = get_key_attribute(key + sizeof("ATTR")-1);
if (attr == NULL) {
err("error parsing ATTR attribute");
@@
-375,11
+370,6
@@
static int add_to_rules(struct udev_rules *rules, char *line, const char *filena
if (strncasecmp(key, "ATTRS", sizeof("ATTRS")-1) == 0 ||
strncasecmp(key, "SYSFS", sizeof("SYSFS")-1) == 0) {
if (strncasecmp(key, "ATTRS", sizeof("ATTRS")-1) == 0 ||
strncasecmp(key, "SYSFS", sizeof("SYSFS")-1) == 0) {
- if (operation != KEY_OP_MATCH &&
- operation != KEY_OP_NOMATCH) {
- err("invalid ATTRSS operation");
- goto invalid;
- }
attr = get_key_attribute(key + sizeof("ATTRS")-1);
if (attr == NULL) {
err("error parsing ATTRS attribute");
attr = get_key_attribute(key + sizeof("ATTRS")-1);
if (attr == NULL) {
err("error parsing ATTRS attribute");