lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <148170364325.11774.10800199735048760595.stgit@bahia>
Date:   Wed, 14 Dec 2016 09:20:43 +0100
From:   Greg Kurz <groug@...d.org>
To:     Eric Van Hensbergen <ericvh@...il.com>
Cc:     v9fs-developer@...ts.sourceforge.net, trivial@...nel.org,
        linux-kernel@...r.kernel.org
Subject: [PATCH] 9p: safer definition of P9_NOTAG and P9_NOFID

Both defines should at least have enclosing parenthesis to be usable in
any syntactical situation. This is the case of U16_MAX and U32_MAX, so
let's use them.

This patch is just cleanup, it doesn't change any behaviour with the current
code.

Signed-off-by: Greg Kurz <groug@...d.org>
---
 include/net/9p/9p.h |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/net/9p/9p.h b/include/net/9p/9p.h
index 27dfe85772b1..5c80d98126b3 100644
--- a/include/net/9p/9p.h
+++ b/include/net/9p/9p.h
@@ -332,8 +332,8 @@ enum p9_qid_t {
 };
 
 /* 9P Magic Numbers */
-#define P9_NOTAG	(u16)(~0)
-#define P9_NOFID	(u32)(~0)
+#define P9_NOTAG	U16_MAX
+#define P9_NOFID	U32_MAX
 #define P9_MAXWELEM	16
 
 /* ample room for Twrite/Rread header */

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ