Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 6 Dec 2021 00:27:56 GMT
From:      Konstantin Belousov <kib@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 4914a141fb6c - stable/13 - libc/net/getnetnamadr.c: Mark write-only variables as unused
Message-ID:  <202112060027.1B60Ruc0084615@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by kib:

URL: https://cgit.FreeBSD.org/src/commit/?id=4914a141fb6c49341baf6d99cfd2c69d7f618010

commit 4914a141fb6c49341baf6d99cfd2c69d7f618010
Author:     Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2021-11-28 03:45:52 +0000
Commit:     Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2021-12-06 00:23:44 +0000

    libc/net/getnetnamadr.c: Mark write-only variables as unused
    
    (cherry picked from commit 1c4f305d21c069ebfdab6baada0837f7ecc810ea)
---
 lib/libc/net/getnetnamadr.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/lib/libc/net/getnetnamadr.c b/lib/libc/net/getnetnamadr.c
index 2d9776685cf9..82ff089c1f1b 100644
--- a/lib/libc/net/getnetnamadr.c
+++ b/lib/libc/net/getnetnamadr.c
@@ -121,12 +121,12 @@ static int
 net_marshal_func(char *buffer, size_t *buffer_size, void *retval, va_list ap,
     void *cache_mdata)
 {
-	char *name;
-	uint32_t net;
-	int type;
+	char *name __unused;
+	uint32_t net __unused;
+	int type __unused;
 	struct netent *ne;
-	char *orig_buf;
-	size_t orig_buf_size;
+	char *orig_buf __unused;
+	size_t orig_buf_size __unused;
 
 	struct netent new_ne;
 	size_t desired_size, size, aliases_size;
@@ -210,9 +210,9 @@ static int
 net_unmarshal_func(char *buffer, size_t buffer_size, void *retval, va_list ap,
     void *cache_mdata)
 {
-	char *name;
-	uint32_t net;
-	int type;
+	char *name __unused;
+	uint32_t net __unused;
+	int type __unused;
 	struct netent *ne;
 	char *orig_buf;
 	size_t orig_buf_size;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202112060027.1B60Ruc0084615>