X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=cpmchattr.c;h=cf337e21b496a66c94eba8c4271fb7df8216455b;hb=a2d7d89e8d4dbd8860a2f1fd624fcdb46eda35fc;hp=cb9e53d4358493bf73b49d17fa802b8a5e4e5406;hpb=975c05c916276c70d34b5aa14e5f0faca1ae013d;p=debian%2Fcpmtools diff --git a/cpmchattr.c b/cpmchattr.c index cb9e53d..cf337e2 100644 --- a/cpmchattr.c +++ b/cpmchattr.c @@ -6,7 +6,7 @@ #include #include -#include "getopt.h" +#include "getopt_.h" #include "cpmfs.h" #ifdef USE_DMALLOC @@ -43,8 +43,8 @@ int main(int argc, char *argv[]) /*{{{*/ if (optind>=(argc-2)) usage=1; else { - image=argv[optind]; - attrs = argv[optind+1]; + image=argv[optind++]; + attrs = argv[optind++]; } if (usage) @@ -106,6 +106,7 @@ int main(int argc, char *argv[]) /*{{{*/ exitcode=1; } } + cpmUmount(&drive); exit(exitcode); } /*}}}*/