From 7f13d0b0eda86f150331e0411fa146896b26f247 Mon Sep 17 00:00:00 2001 From: dim Date: Tue, 4 Feb 2020 19:19:48 +0000 Subject: [PATCH] MFC r357223: Merge r357222 from the clang1000-import branch: Fix the following -Werror warning from clang 10.0.0 in rbootd: libexec/rbootd/rmpproto.c:335:49: error: multiple unsequenced modifications to 'filename' [-Werror,-Wunsequenced] filename = (filename = strrchr(filepath,'/'))? ++filename: filepath; ~ ^ git-svn-id: svn://svn.freebsd.org/base/stable/10@357517 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f --- libexec/rbootd/rmpproto.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libexec/rbootd/rmpproto.c b/libexec/rbootd/rmpproto.c index aa4be5647..a13258810 100644 --- a/libexec/rbootd/rmpproto.c +++ b/libexec/rbootd/rmpproto.c @@ -330,7 +330,8 @@ SendBootRepl(struct rmp_packet *req, RMPCONN *rconn, char *filelist[]) * stripped file name and spoof the client into thinking that it * really got what it wanted. */ - filename = (filename = strrchr(filepath,'/'))? ++filename: filepath; + filename = strrchr(filepath,'/'); + filename = filename? filename + 1: filepath; /* * Check that this is a valid boot file name. -- 2.42.0