git: 054f5815c511 - main - vfs: plug a set-but-not-used var in kern_alternate_path

From: Mateusz Guzik <mjg_at_FreeBSD.org>
Date: Fri, 26 Nov 2021 12:23:08 UTC
The branch main has been updated by mjg:

URL: https://cgit.FreeBSD.org/src/commit/?id=054f5815c5117f54eb8a161bf78ace3656805768

commit 054f5815c5117f54eb8a161bf78ace3656805768
Author:     Mateusz Guzik <mjg@FreeBSD.org>
AuthorDate: 2021-11-26 12:22:09 +0000
Commit:     Mateusz Guzik <mjg@FreeBSD.org>
CommitDate: 2021-11-26 12:22:09 +0000

    vfs: plug a set-but-not-used var in kern_alternate_path
    
    Sponsored by:   Rubicon Communications, LLC ("Netgate")
---
 sys/kern/vfs_lookup.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/sys/kern/vfs_lookup.c b/sys/kern/vfs_lookup.c
index d5960dd9e920..d05e1658a004 100644
--- a/sys/kern/vfs_lookup.c
+++ b/sys/kern/vfs_lookup.c
@@ -1676,13 +1676,11 @@ int
 kern_alternate_path(const char *prefix, const char *path, enum uio_seg pathseg,
     char **pathbuf, int create, int dirfd)
 {
-	struct thread *td;
 	struct nameidata nd, ndroot;
 	char *ptr, *buf, *cp;
 	size_t len, sz;
 	int error;
 
-	td = curthread;
 	buf = (char *) malloc(MAXPATHLEN, M_TEMP, M_WAITOK);
 	*pathbuf = buf;