-
Vitaly Ostrosablin authored
cat *.pid works when we have only one running process at any moment. That's because pidfiles contain no newlines and cat will just concatenate content of all files present in directory. So, e.g., if we have pidfiles: 31338 31359 31880 31884 31889 cat will build following string from those pidfiles: 3133831359318803188431889 Obviously, kill would fail to send signals to processes, because it's now a single big number, which cannot be unambigously split back in general case. That's where awk comes in. We don't need to modify C part of tests to print newlines at end of file. We just order awk to print content of each file, which adds a newline at end - problem solved, kill can once again parse, which PIDs it get and send proper signals to them. Also, should be completely safe for zdtm.py, because it doesn't use Makefiles and sends signals on it's own. travis-ci: success for series starting with [v2,1/2] test: replace cat in Makefiles with awk Signed-off-by:
Vitaly Ostrosablin <vostrosablin@virtuozzo.com> Reviewed-by:
Cyrill Gorcunov <gorcunov@openvz.org> Reviewed-by:
Dmitry Safonov <dsafonov@virtuozzo.com> Acked-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@virtuozzo.com>
911317ea