X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;ds=sidebyside;f=ucw%2Ffit.c;h=30b1b9fa8a434c8f0d696788cf956701d56317cc;hb=9e62571d66243d0f5c8bd302ff23f3789de9ab89;hp=b310c120db5bdb14a96985ff8946d9c8bc9bbd5a;hpb=e5a93f28cb02fa26ae39c70555bf0fc07d447922;p=misc.git diff --git a/ucw/fit.c b/ucw/fit.c index b310c12..30b1b9f 100644 --- a/ucw/fit.c +++ b/ucw/fit.c @@ -1,6 +1,6 @@ -#include "lib/lib.h" -#include "lib/fastbuf.h" -#include "lib/bbuf.h" +#include "ucw/lib.h" +#include "ucw/fastbuf.h" +#include "ucw/bbuf.h" #include #include @@ -53,13 +53,15 @@ int main(int argc, char **argv) while (!map[max]) max--; - printf("Found subset with %d blocks:\n", max); + printf("Found subset with %d blocks of %d (%.2f%%):\n", max, m, 100.*max/m); + int free = m-max; while (max) { int f = map[max]-2; printf("%7d\t%s\n", files[f].blocks, files[f].name); max -= files[f].blocks; } + printf("%7d\t*FREE*\n", free); return 0; }