summaryrefslogtreecommitdiff
path: root/util-linux/mdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'util-linux/mdev.c')
-rw-r--r--util-linux/mdev.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/util-linux/mdev.c b/util-linux/mdev.c
index 217075660..b4042c07e 100644
--- a/util-linux/mdev.c
+++ b/util-linux/mdev.c
@@ -374,10 +374,8 @@ static void make_device(char *path, int delete)
374 putenv(s1); 374 putenv(s1);
375 if (system(command) == -1) 375 if (system(command) == -1)
376 bb_perror_msg("can't run '%s'", command); 376 bb_perror_msg("can't run '%s'", command);
377 unsetenv("SUBSYSTEM"); 377 bb_unsetenv_and_free(s1);
378 free(s1); 378 bb_unsetenv_and_free(s);
379 unsetenv("MDEV");
380 free(s);
381 free(command); 379 free(command);
382 } 380 }
383 381