]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - common/hash.c
Merge branch 'u-boot/master' into 'u-boot-arm/master'
[karo-tx-uboot.git] / common / hash.c
index 722c40b3f33044bb1680643c47b236308cf1dd2b..872cd8542800895cd94f13d5290fd1a82c3e9cf7 100644 (file)
@@ -325,8 +325,8 @@ int hash_command(const char *algo_name, int flags, cmd_tbl_t *cmdtp, int flag,
                printf("CRC32 for %08lx ... %08lx ==> %08lx\n",
                                addr, addr + len - 1, crc);
 
-               if (argc > 3) {
-                       ptr = (ulong *)simple_strtoul(argv[3], NULL, 16);
+               if (argc >= 3) {
+                       ptr = (ulong *)simple_strtoul(argv[0], NULL, 16);
                        *ptr = crc;
                }
        }