]> code.ossystems Code Review - openembedded-core.git/commit
testimage.bbclass: correctly process SIGTERM
authorAlexander Kanavin <alex.kanavin@gmail.com>
Fri, 17 Apr 2020 14:18:44 +0000 (16:18 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 25 Apr 2020 15:34:13 +0000 (16:34 +0100)
commit06568a06ca22ee279d1829d26d4c38738233c06a
tree93537dc76c81e6b790d110482d66b1e1d663f919
parentf97a6d241d1ad1a2cb03ced05202f615223d3a32
testimage.bbclass: correctly process SIGTERM

Python's unittest will not propagate exceptions upside
of itself, but rather will just catch and print them.

The working way to make it stop is to send a SIGINT
(e.g. simulate a ctrl-c press), which will make it exit
with a KeyboardInterrupt exception.

This also makes pressing ctrl-c twice from bitbake work
again (previously hanging instances of bitbake and qemu were
left around, and bitbake would no longer start until they
were killed manually).

Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/testimage.bbclass