Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
9dfa6e19
Commit
9dfa6e19
authored
Oct 29, 2016
by
Christian Brauner
Committed by
Stéphane Graber
Nov 21, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tools/lxc_stop: use lxc_safe_long()
Signed-off-by:
Christian Brauner
<
christian.brauner@canonical.com
>
parent
45cf2817
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
7 deletions
+4
-7
lxc_stop.c
src/lxc/tools/lxc_stop.c
+4
-7
No files found.
src/lxc/tools/lxc_stop.c
View file @
9dfa6e19
...
@@ -48,7 +48,7 @@ static int my_parser(struct lxc_arguments *args, int c, char *arg)
...
@@ -48,7 +48,7 @@ static int my_parser(struct lxc_arguments *args, int c, char *arg)
args
->
nowait
=
1
;
args
->
nowait
=
1
;
break
;
break
;
case
't'
:
case
't'
:
if
(
lxc_safe_
int
(
arg
,
&
args
->
timeout
)
<
0
)
if
(
lxc_safe_
long
(
arg
,
&
args
->
timeout
)
<
0
)
return
-
1
;
return
-
1
;
break
;
break
;
case
'k'
:
case
'k'
:
...
@@ -168,17 +168,14 @@ int main(int argc, char *argv[])
...
@@ -168,17 +168,14 @@ int main(int argc, char *argv[])
/* Set default timeout */
/* Set default timeout */
if
(
my_args
.
timeout
==
-
2
)
{
if
(
my_args
.
timeout
==
-
2
)
{
if
(
my_args
.
hardstop
)
{
if
(
my_args
.
hardstop
)
my_args
.
timeout
=
0
;
my_args
.
timeout
=
0
;
}
else
else
{
my_args
.
timeout
=
60
;
my_args
.
timeout
=
60
;
}
}
}
if
(
my_args
.
nowait
)
{
if
(
my_args
.
nowait
)
my_args
.
timeout
=
0
;
my_args
.
timeout
=
0
;
}
/* some checks */
/* some checks */
if
(
!
my_args
.
hardstop
&&
my_args
.
timeout
<
-
1
)
{
if
(
!
my_args
.
hardstop
&&
my_args
.
timeout
<
-
1
)
{
...
...
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