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
93a3177f
Commit
93a3177f
authored
Aug 28, 2002
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add some fascist code to trap __FUNCTION__ pasting, fix up
some more pasters..
parent
aad4ad15
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
fs/fcntl.c
fs/fcntl.c
+2
-2
include/linux/kernel.h
include/linux/kernel.h
+6
-0
No files found.
fs/fcntl.c
View file @
93a3177f
...
@@ -52,7 +52,7 @@ static int expand_files(struct files_struct *files, int nr)
...
@@ -52,7 +52,7 @@ static int expand_files(struct files_struct *files, int nr)
{
{
int
err
,
expand
=
0
;
int
err
,
expand
=
0
;
#ifdef FDSET_DEBUG
#ifdef FDSET_DEBUG
printk
(
KERN_ERR
__FUNCTION__
" %d: nr = %d
\n
"
,
current
->
pid
,
nr
);
printk
(
KERN_ERR
"%s %d: nr = %d
\n
"
,
__FUNCTION__
,
current
->
pid
,
nr
);
#endif
#endif
if
(
nr
>=
files
->
max_fdset
)
{
if
(
nr
>=
files
->
max_fdset
)
{
...
@@ -69,7 +69,7 @@ static int expand_files(struct files_struct *files, int nr)
...
@@ -69,7 +69,7 @@ static int expand_files(struct files_struct *files, int nr)
out:
out:
#ifdef FDSET_DEBUG
#ifdef FDSET_DEBUG
if
(
err
)
if
(
err
)
printk
(
KERN_ERR
__FUNCTION__
" %d: return %d
\n
"
,
current
->
pid
,
err
);
printk
(
KERN_ERR
"%s %d: return %d
\n
"
,
__FUNCTION__
,
current
->
pid
,
err
);
#endif
#endif
return
err
;
return
err
;
}
}
...
...
include/linux/kernel.h
View file @
93a3177f
...
@@ -191,4 +191,10 @@ struct sysinfo {
...
@@ -191,4 +191,10 @@ struct sysinfo {
};
};
#define BUG_ON(condition) do { if (unlikely((condition)!=0)) BUG(); } while(0)
#define BUG_ON(condition) do { if (unlikely((condition)!=0)) BUG(); } while(0)
/* Trap pasters of __FUNCTION__ at compile-time */
#if __GNUC__ > 2 || __GNUC_MINOR__ >= 95
#define __FUNCTION__ (__func__)
#endif
#endif
#endif
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