Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nettle
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
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
Wim Lewis
nettle
Commits
74538386
Commit
74538386
authored
Sep 07, 2012
by
Niels Möller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved use of gcc __attribute__.
parent
6ad4d518
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
17 deletions
+13
-17
ChangeLog
ChangeLog
+9
-0
examples/io.h
examples/io.h
+1
-5
examples/nettle-benchmark.c
examples/nettle-benchmark.c
+1
-1
tools/misc.h
tools/misc.h
+2
-11
No files found.
ChangeLog
View file @
74538386
2012-09-07 Niels Möller <nisse@lysator.liu.se>
* examples/nettle-benchmark.c (die): Add NORETURN attribute. Patch
from Tim Rühsen.
* tools/misc.h (die, werror): Use PRINTF_STYLE and NORETURN macros
for attributes. Patch from Tim Rühsen.
* examples/io.h (werror): Use PRINTF_STYLE macro.
2012-08-22 Niels Möller <nisse@lysator.liu.se>
From Sam Thursfield <sam.thursfield@codethink.co.uk>:
...
...
examples/io.h
View file @
74538386
...
...
@@ -37,11 +37,7 @@ void *
xalloc
(
size_t
size
);
void
werror
(
const
char
*
format
,
...)
#if __GNUC___
__attribute__
((
__format__
(
__printf__
,
1
,
2
)))
#endif
;
werror
(
const
char
*
format
,
...)
PRINTF_STYLE
(
1
,
2
);
/* If size is > 0, read at most that many bytes. If size == 0,
* read until EOF. Allocates the buffer dynamically. */
...
...
examples/nettle-benchmark.c
View file @
74538386
...
...
@@ -96,7 +96,7 @@ static double frequency = 0.0;
#define BENCH_ITERATIONS 10
#endif
static
void
static
void
NORETURN
die
(
const
char
*
format
,
...)
{
va_list
args
;
...
...
tools/misc.h
View file @
74538386
...
...
@@ -28,19 +28,10 @@
#endif
void
die
(
const
char
*
format
,
...)
#if __GNUC___
__attribute__
((
__format__
(
__printf__
,
1
,
2
)))
__attribute__
((
__noreturn__
))
#endif
;
die
(
const
char
*
format
,
...)
PRINTF_STYLE
(
1
,
2
)
NORETURN
;
void
werror
(
const
char
*
format
,
...)
#if __GNUC___
__attribute__
((
__format__
(
__printf__
,
1
,
2
)))
#endif
;
werror
(
const
char
*
format
,
...)
PRINTF_STYLE
(
1
,
2
);
void
*
xalloc
(
size_t
size
);
...
...
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