Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
SWIFT
SWIFTsim
Commits
27f89d7e
Commit
27f89d7e
authored
Aug 01, 2017
by
Peter W. Draper
Browse files
No need to exit, just make sure we don't overrun
parent
9d6a39a1
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/version.c
View file @
27f89d7e
...
...
@@ -142,10 +142,7 @@ const char *configuration_options(void) {
static
int
initialised
=
0
;
static
const
char
*
config
=
SWIFT_CONFIG_FLAGS
;
if
(
!
initialised
)
{
if
(
strlen
(
config
)
<
1024
-
2
)
sprintf
(
buf
,
"'%s'"
,
config
);
else
error
(
"SWIFT_CONFIG_FLAGS string longer than buffer"
);
snprintf
(
buf
,
1024
,
"'%s'"
,
config
);
initialised
=
1
;
}
return
buf
;
...
...
@@ -161,10 +158,7 @@ const char *compilation_cflags(void) {
static
int
initialised
=
0
;
static
const
char
*
cflags
=
SWIFT_CFLAGS
;
if
(
!
initialised
)
{
if
(
strlen
(
cflags
)
<
1024
-
2
)
sprintf
(
buf
,
"'%s'"
,
cflags
);
else
error
(
"SWIFT_CFLAGS string longer than buffer"
);
snprintf
(
buf
,
1024
,
"'%s'"
,
cflags
);
initialised
=
1
;
}
return
buf
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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