From 10c6258e326f6fcc749747334de9fc1672296719 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Mon, 2 May 2016 11:14:13 +0200 Subject: [PATCH] minor CODING_STYLE clarification --- CODING_STYLE | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CODING_STYLE b/CODING_STYLE index c2b2e56d5d6..b689355c9a6 100644 --- a/CODING_STYLE +++ b/CODING_STYLE @@ -240,6 +240,11 @@ unlink("/foo/bar/baz"); + Don't cast function calls to (void) that return no error + conditions. Specifically, the various xyz_unref() calls that return a NULL + object shouldn't be cast to (void), since not using the return value does not + hide any errors. + - Don't invoke exit(), ever. It is not replacement for proper error handling. Please escalate errors up your call chain, and use normal "return" to exit from the main function of a process. If you -- 2.39.2