FreeCalypso > hg > freecalypso-sw
diff target-utils/libtiffs/cmd_find.c @ 224:2900fe603f8a
beginning of MPFFS->TIFFS naming convention change
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Sun, 12 Jan 2014 07:59:00 +0000 |
parents | target-utils/libmpffs/cmd_find.c@3daa8ebbe74d |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/target-utils/libtiffs/cmd_find.c Sun Jan 12 07:59:00 2014 +0000 @@ -0,0 +1,25 @@ +#include <sys/types.h> +#include "types.h" + +void +cmd_find(argbulk) + char *argbulk; +{ + char *argv[2]; + int stat, cont; + u8 *start; + size_t size; + + if (parse_args(argbulk, 1, 1, argv, 0) < 0) + return; + stat = mpffs_find_file(argv[0], &start, &size, &cont); + if (stat < 0) + return; + printf("chunk @%08X size %x\n", (u32)start, (u32)size); + while (cont) { + stat = mpffs_get_segment(cont, &start, &size, &cont); + if (stat < 0) + return; + printf("chunk @%08X size %x\n", (u32)start, (u32)size); + } +}