Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
d884596f
Commit
d884596f
authored
Dec 16, 2005
by
David Woodhouse
Committed by
Al Viro
Mar 20, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] Minor cosmetic cleanups to the code moved into auditfilter.c
Signed-off-by:
David Woodhouse
<
dwmw2@infradead.org
>
parent
fe7752ba
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
7 deletions
+4
-7
kernel/auditfilter.c
kernel/auditfilter.c
+4
-7
No files found.
kernel/auditfilter.c
View file @
d884596f
...
...
@@ -69,7 +69,7 @@ static inline int audit_copy_rule(struct audit_rule *d, struct audit_rule *s)
/* Check to see if two rules are identical. It is called from
* audit_add_rule during AUDIT_ADD and
* audit_del_rule during AUDIT_DEL. */
static
in
line
in
t
audit_compare_rule
(
struct
audit_rule
*
a
,
struct
audit_rule
*
b
)
static
int
audit_compare_rule
(
struct
audit_rule
*
a
,
struct
audit_rule
*
b
)
{
int
i
;
...
...
@@ -107,19 +107,18 @@ static inline int audit_add_rule(struct audit_rule *rule,
/* Do not use the _rcu iterator here, since this is the only
* addition routine. */
list_for_each_entry
(
entry
,
list
,
list
)
{
if
(
!
audit_compare_rule
(
rule
,
&
entry
->
rule
))
{
if
(
!
audit_compare_rule
(
rule
,
&
entry
->
rule
))
return
-
EEXIST
;
}
}
for
(
i
=
0
;
i
<
rule
->
field_count
;
i
++
)
{
if
(
rule
->
fields
[
i
]
&
AUDIT_UNUSED_BITS
)
return
-
EINVAL
;
if
(
rule
->
fields
[
i
]
&
AUDIT_NEGATE
)
if
(
rule
->
fields
[
i
]
&
AUDIT_NEGATE
)
rule
->
fields
[
i
]
|=
AUDIT_NOT_EQUAL
;
else
if
(
(
rule
->
fields
[
i
]
&
AUDIT_OPERATORS
)
==
0
)
rule
->
fields
[
i
]
|=
AUDIT_EQUAL
;
rule
->
fields
[
i
]
&=
(
~
AUDIT_NEGATE
)
;
rule
->
fields
[
i
]
&=
~
AUDIT_NEGATE
;
}
if
(
!
(
entry
=
kmalloc
(
sizeof
(
*
entry
),
GFP_KERNEL
)))
...
...
@@ -374,5 +373,3 @@ int audit_filter_type(int type)
rcu_read_unlock
();
return
result
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment