[openssh-commits] [openssh] 05/08: upstream commit
git+noreply at mindrot.org
git+noreply at mindrot.org
Fri Nov 15 16:09:10 AEDT 2019
This is an automated email from the git hooks/post-receive script.
djm pushed a commit to branch master
in repository openssh.
commit 228dd595c7882bb9b161dbb7d4dca15c8a5f03f5
Author: Damien Miller <djm at mindrot.org>
Date: Fri Nov 15 16:04:28 2019 +1100
upstream commit
revision 1.46
date: 2015/12/28 22:08:18; author: mmcc; state: Exp; lines: +5 -9; commitid: 0uXuF2O13NH9q2e1;
Remove NULL-checks before free() and a few related dead assignments.
ok and valuable input from millert@
---
openbsd-compat/glob.c | 14 +++++---------
1 file changed, 5 insertions(+), 9 deletions(-)
diff --git a/openbsd-compat/glob.c b/openbsd-compat/glob.c
index 7409b96e..413dfc8c 100644
--- a/openbsd-compat/glob.c
+++ b/openbsd-compat/glob.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: glob.c,v 1.44 2015/09/14 16:09:13 tedu Exp $ */
+/* $OpenBSD: glob.c,v 1.46 2015/12/28 22:08:18 mmcc Exp $ */
/*
* Copyright (c) 1989, 1993
* The Regents of the University of California. All rights reserved.
@@ -820,14 +820,10 @@ globextend(const Char *path, glob_t *pglob, struct glob_lim *limitp,
pglob->gl_pathv && pglob->gl_pathv[i])
free(pglob->gl_statv[i]);
}
- if (pglob->gl_pathv) {
- free(pglob->gl_pathv);
- pglob->gl_pathv = NULL;
- }
- if (pglob->gl_statv) {
- free(pglob->gl_statv);
- pglob->gl_statv = NULL;
- }
+ free(pglob->gl_pathv);
+ pglob->gl_pathv = NULL;
+ free(pglob->gl_statv);
+ pglob->gl_statv = NULL;
return(GLOB_NOSPACE);
}
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list