ovs-ctl: Exit, instead of resuming, after handling fatal signals.
authorBen Pfaff <blp@nicira.com>
Wed, 26 Dec 2012 20:45:34 +0000 (12:45 -0800)
committerBen Pfaff <blp@nicira.com>
Wed, 26 Dec 2012 20:47:56 +0000 (12:47 -0800)
commit30c4aa0f11b12d3210686915993907e8f0f54ffe
tree900546beae0f7bb4b62e890c0eec3a242f962559
parentdd7f5718e5bf0bb7fb84aecfc54f528d84670b4c
ovs-ctl: Exit, instead of resuming, after handling fatal signals.

When I wrote the "trap" calls in ovs-ctl, I had the mistaken notion that
"trap $cmd $signal" would execute $cmd and then exit when $signal was
caught.  This is incorrect.  Instead, it executes $cmd and then resumes
executing the shell script.

On the other hand, "trap $cmd 0" does by itself what I wanted: it causes
the shell to execute $cmd and then exits due to the signal.  So this commit
changes the offending traps to use this form.

Bug #14290.
Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Kyle Mestery <kmestery@cisco.com>
utilities/ovs-ctl.in