HomeClusterLabs Projects

tests: replace open coded error handling with knet_handle_start() calls

Description

tests: replace open coded error handling with knet_handle_start() calls

Done by:
$ sed -i -e '1h;2,$H;$!d;g' -e 's/knet_h = knet_handle_new(1, logfds\[1\], \(KNET_LOG_[A-Z]*\));\n\n\tif (!knet_h) {\n\t\tprintf("knet_handle_new failed: %s\\n", strerror(errno));\n\t\tflush_logs(logfds\[0\], stdout);\n\t\tclose_logpipes(logfds);\n\t\texit(FAIL);\n\t}/knet_h = knet_handle_start(logfds, \1);/g' libknet/tests/*.c

Signed-off-by: Ferenc Wágner <wferi@debian.org>

Details

Provenance
wferiAuthored on Dec 18 2017, 3:31 PM
Parents
rK2d5eabd79494: tests: introduce knet_handle_start helper
Branches
Unknown
Tags
Unknown

Event Timeline