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
Kirill Smelkov
linux
Commits
c0315f4b
Commit
c0315f4b
authored
Nov 26, 2002
by
Greg Kroah-Hartman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
LSM: change if statements into something more readable for the ipc/*, mm/*, and net/* files.
parent
ee099009
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
12 additions
and
6 deletions
+12
-6
ipc/msg.c
ipc/msg.c
+2
-1
ipc/sem.c
ipc/sem.c
+2
-1
ipc/shm.c
ipc/shm.c
+2
-1
mm/mmap.c
mm/mmap.c
+2
-1
mm/mprotect.c
mm/mprotect.c
+2
-1
net/core/scm.c
net/core/scm.c
+2
-1
No files found.
ipc/msg.c
View file @
c0315f4b
...
@@ -101,7 +101,8 @@ static int newque (key_t key, int msgflg)
...
@@ -101,7 +101,8 @@ static int newque (key_t key, int msgflg)
msq
->
q_perm
.
key
=
key
;
msq
->
q_perm
.
key
=
key
;
msq
->
q_perm
.
security
=
NULL
;
msq
->
q_perm
.
security
=
NULL
;
if
((
retval
=
security_msg_queue_alloc
(
msq
)))
{
retval
=
security_msg_queue_alloc
(
msq
);
if
(
retval
)
{
ipc_rcu_free
(
msq
,
sizeof
(
*
msq
));
ipc_rcu_free
(
msq
,
sizeof
(
*
msq
));
return
retval
;
return
retval
;
}
}
...
...
ipc/sem.c
View file @
c0315f4b
...
@@ -136,7 +136,8 @@ static int newary (key_t key, int nsems, int semflg)
...
@@ -136,7 +136,8 @@ static int newary (key_t key, int nsems, int semflg)
sma
->
sem_perm
.
key
=
key
;
sma
->
sem_perm
.
key
=
key
;
sma
->
sem_perm
.
security
=
NULL
;
sma
->
sem_perm
.
security
=
NULL
;
if
((
retval
=
security_sem_alloc
(
sma
)))
{
retval
=
security_sem_alloc
(
sma
);
if
(
retval
)
{
ipc_rcu_free
(
sma
,
size
);
ipc_rcu_free
(
sma
,
size
);
return
retval
;
return
retval
;
}
}
...
...
ipc/shm.c
View file @
c0315f4b
...
@@ -188,7 +188,8 @@ static int newseg (key_t key, int shmflg, size_t size)
...
@@ -188,7 +188,8 @@ static int newseg (key_t key, int shmflg, size_t size)
shp
->
shm_flags
=
(
shmflg
&
S_IRWXUGO
);
shp
->
shm_flags
=
(
shmflg
&
S_IRWXUGO
);
shp
->
shm_perm
.
security
=
NULL
;
shp
->
shm_perm
.
security
=
NULL
;
if
((
error
=
security_shm_alloc
(
shp
)))
{
error
=
security_shm_alloc
(
shp
);
if
(
error
)
{
ipc_rcu_free
(
shp
,
sizeof
(
*
shp
));
ipc_rcu_free
(
shp
,
sizeof
(
*
shp
));
return
error
;
return
error
;
}
}
...
...
mm/mmap.c
View file @
c0315f4b
...
@@ -504,7 +504,8 @@ unsigned long do_mmap_pgoff(struct file * file, unsigned long addr,
...
@@ -504,7 +504,8 @@ unsigned long do_mmap_pgoff(struct file * file, unsigned long addr,
}
}
}
}
if
((
error
=
security_file_mmap
(
file
,
prot
,
flags
)))
error
=
security_file_mmap
(
file
,
prot
,
flags
);
if
(
error
)
return
error
;
return
error
;
/* Clear old maps */
/* Clear old maps */
...
...
mm/mprotect.c
View file @
c0315f4b
...
@@ -263,7 +263,8 @@ sys_mprotect(unsigned long start, size_t len, unsigned long prot)
...
@@ -263,7 +263,8 @@ sys_mprotect(unsigned long start, size_t len, unsigned long prot)
goto
out
;
goto
out
;
}
}
if
((
error
=
security_file_mprotect
(
vma
,
prot
)))
error
=
security_file_mprotect
(
vma
,
prot
);
if
(
error
)
goto
out
;
goto
out
;
if
(
vma
->
vm_end
>
end
)
{
if
(
vma
->
vm_end
>
end
)
{
...
...
net/core/scm.c
View file @
c0315f4b
...
@@ -217,7 +217,8 @@ void scm_detach_fds(struct msghdr *msg, struct scm_cookie *scm)
...
@@ -217,7 +217,8 @@ void scm_detach_fds(struct msghdr *msg, struct scm_cookie *scm)
for
(
i
=
0
,
cmfptr
=
(
int
*
)
CMSG_DATA
(
cm
);
i
<
fdmax
;
i
++
,
cmfptr
++
)
for
(
i
=
0
,
cmfptr
=
(
int
*
)
CMSG_DATA
(
cm
);
i
<
fdmax
;
i
++
,
cmfptr
++
)
{
{
int
new_fd
;
int
new_fd
;
if
((
err
=
security_file_receive
(
fp
[
i
])))
err
=
security_file_receive
(
fp
[
i
]);
if
(
err
)
break
;
break
;
err
=
get_unused_fd
();
err
=
get_unused_fd
();
if
(
err
<
0
)
if
(
err
<
0
)
...
...
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