Merge tag 'u-boot-rockchip-20200531' of https://gitlab.denx.de/u-boot/custodians...
[oweals/u-boot.git] / common / cli_hush.c
index cf1e273485c7e98c82cc897030439faf3a2e917e..5b1f11907438e893911ca6f8e0650be8a423392c 100644 (file)
@@ -1849,8 +1849,7 @@ static int run_list_real(struct pipe *pi)
                                continue;
                        } else {
                                /* insert new value from list for variable */
-                               if (pi->progs->argv[0])
-                                       free(pi->progs->argv[0]);
+                               free(pi->progs->argv[0]);
                                pi->progs->argv[0] = *list++;
 #ifndef __U_BOOT__
                                pi->progs->glob_result.gl_pathv[0] =
@@ -3665,8 +3664,8 @@ static char *make_string(char **inp, int *nonnull)
 }
 
 #ifdef __U_BOOT__
-static int do_showvar(cmd_tbl_t *cmdtp, int flag, int argc,
-                     char * const argv[])
+static int do_showvar(struct cmd_tbl *cmdtp, int flag, int argc,
+                     char *const argv[])
 {
        int i, k;
        int rcode = 0;