[CRIU] [PATCH] sk-unix: Print error message if external socket failure happened

Cyrill Gorcunov gorcunov at openvz.org
Tue Mar 26 05:09:45 EDT 2013


show_one_unix uses pr_debug to provide details (for developers
mostly) but when regular user meets such a case better to
warn him about problem rather than exit out silently.

Reported-by: Kevin Wilson <wkevils at gmail.com>
Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
---
 sk-unix.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/sk-unix.c b/sk-unix.c
index 4905cd1..5aacb96 100644
--- a/sk-unix.c
+++ b/sk-unix.c
@@ -432,11 +432,13 @@ int fix_external_unix_sockets(void)
 		BUG_ON(sk->sd.already_dumped);
 
 		if (!opts.ext_unix_sk) {
+			pr_err("External socket found but no option passed\n");
 			show_one_unix("Runaway socket", sk);
 			goto err;
 		}
 
 		if (sk->type != SOCK_DGRAM) {
+			pr_err("External socket with unsupported type\n");
 			show_one_unix("Ext stream not supported", sk);
 			goto err;
 		}
-- 
1.8.1.4



More information about the CRIU mailing list