Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
de641b56
Commit
de641b56
authored
Aug 31, 2020
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix unused-result warning
parent
b3478a09
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
tools/caf-run.cpp
tools/caf-run.cpp
+7
-3
No files found.
tools/caf-run.cpp
View file @
de641b56
...
@@ -223,7 +223,7 @@ void bootstrap(actor_system& system, const string& wdir,
...
@@ -223,7 +223,7 @@ void bootstrap(actor_system& system, const string& wdir,
#define RETURN_WITH_ERROR(output) \
#define RETURN_WITH_ERROR(output) \
do { \
do { \
::std::cerr << output << ::std::endl; \
::std::cerr << output << ::std::endl; \
return
1;
\
return
EXIT_FAILURE;
\
} while (true)
} while (true)
namespace
{
namespace
{
...
@@ -242,9 +242,12 @@ struct config : actor_system_config {
...
@@ -242,9 +242,12 @@ struct config : actor_system_config {
int
main
(
int
argc
,
char
**
argv
)
{
int
main
(
int
argc
,
char
**
argv
)
{
config
cfg
;
config
cfg
;
cfg
.
parse
(
argc
,
argv
);
if
(
auto
err
=
cfg
.
parse
(
argc
,
argv
))
{
std
::
cerr
<<
"error parsing command line: "
<<
to_string
(
err
)
<<
'\n'
;
return
EXIT_FAILURE
;
}
if
(
cfg
.
cli_helptext_printed
)
if
(
cfg
.
cli_helptext_printed
)
return
0
;
return
EXIT_SUCCESS
;
if
(
cfg
.
slave_mode
)
if
(
cfg
.
slave_mode
)
RETURN_WITH_ERROR
(
"cannot use slave mode in caf-run tool"
);
RETURN_WITH_ERROR
(
"cannot use slave mode in caf-run tool"
);
std
::
unique_ptr
<
char
,
void
(
*
)(
void
*
)
>
pwd
{
getcwd
(
nullptr
,
0
),
::
free
};
std
::
unique_ptr
<
char
,
void
(
*
)(
void
*
)
>
pwd
{
getcwd
(
nullptr
,
0
),
::
free
};
...
@@ -265,4 +268,5 @@ int main(int argc, char** argv) {
...
@@ -265,4 +268,5 @@ int main(int argc, char** argv) {
hosts
.
erase
(
hosts
.
begin
());
hosts
.
erase
(
hosts
.
begin
());
bootstrap
(
system
,
(
cfg
.
wdir
.
empty
())
?
pwd
.
get
()
:
cfg
.
wdir
.
c_str
(),
master
,
bootstrap
(
system
,
(
cfg
.
wdir
.
empty
())
?
pwd
.
get
()
:
cfg
.
wdir
.
c_str
(),
master
,
std
::
move
(
hosts
),
cmd
,
xs
);
std
::
move
(
hosts
),
cmd
,
xs
);
return
EXIT_SUCCESS
;
}
}
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