summaryrefslogtreecommitdiff
path: root/lib/mkdir-p.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2005-12-20 10:28:53 +0000
committerJim Meyering <jim@meyering.net>2005-12-20 10:28:53 +0000
commitcf02d3c6f6b155b26166dc7e149be7b3a88bdb3e (patch)
tree73eb82b15cf74cfe8201f4aa50b2d16b1be0f425 /lib/mkdir-p.c
parentddb24aa9fbc0585532b8a40ac4217dd4c33dd50d (diff)
downloadcoreutils-cf02d3c6f6b155b26166dc7e149be7b3a88bdb3e.tar.xz
(make_dir_parents): Remove unnecessary casts of alloca,
since now it's guaranteed to be (void *).
Diffstat (limited to 'lib/mkdir-p.c')
-rw-r--r--lib/mkdir-p.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/mkdir-p.c b/lib/mkdir-p.c
index e970e118d..3923fbee1 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;