From cf02d3c6f6b155b26166dc7e149be7b3a88bdb3e Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Tue, 20 Dec 2005 10:28:53 +0000 Subject: [PATCH] (make_dir_parents): Remove unnecessary casts of alloca, since now it's guaranteed to be (void *). --- lib/mkdir-p.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/mkdir-p.c b/lib/mkdir-p.c index e970e118d4..3923fbee10 100644 --- a/lib/mkdir-p.c +++ b/lib/mkdir-p.c @@ -123,7 +123,7 @@ make_dir_parents (char const *arg, mode_t oldmask = umask (0); /* Make a copy of ARG that we can scribble NULs on. */ - dir = (char *) alloca (strlen (arg) + 1); + dir = alloca (strlen (arg) + 1); strcpy (dir, arg); strip_trailing_slashes (dir); full_dir = dir; @@ -210,8 +210,7 @@ make_dir_parents (char const *arg, if (re_protect) { - struct ptr_list *new = (struct ptr_list *) - alloca (sizeof *new); + struct ptr_list *new = alloca (sizeof *new); new->dirname_end = slash; new->next = leading_dirs; leading_dirs = new; -- 2.47.3