Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
f7c8831b
Commit
f7c8831b
authored
Jun 26, 2015
by
Mike Hibler
Browse files
Lint.
parent
8f43717b
Changes
1
Hide whitespace changes
Inline
Side-by-side
tbsetup/power.in
View file @
f7c8831b
#!/usr/bin/perl -wT
#
# Copyright (c) 2000-201
3
University of Utah and the Flux Group.
# Copyright (c) 2000-201
5
University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
...
...
@@ -240,8 +240,12 @@ if ($ELABINELAB) {
# What if the node is on? Nothing is going to
# happen and changing the state is wrong.
#
$newstate
=
TBDB_NODESTATE_SHUTDOWN
()
if
(
$oldstate
eq
TBDB_NODESTATE_POWEROFF
());
if
(
$oldstate
eq
TBDB_NODESTATE_POWEROFF
())
{
$newstate
=
TBDB_NODESTATE_SHUTDOWN
()
}
else
{
$newstate
=
$oldstate
;
}
}
print
"
$node
:
$oldstate
,
$newstate
\n
";
...
...
@@ -249,7 +253,7 @@ if ($ELABINELAB) {
# Avoid sending duplicate events; annoys stated.
#
$node
->
SetEventState
(
$newstate
)
if
(
defined
(
$newstate
)
&&
$newstate
ne
$oldstate
);
if
(
$newstate
ne
$oldstate
);
}
}
exit
(
$rval
);
...
...
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