diff --git a/prgm/codage.c b/prgm/codage.c index 6e4ae7b..e326fd0 100644 --- a/prgm/codage.c +++ b/prgm/codage.c @@ -23,30 +23,28 @@ int codage(int argc, char *argv[]) { count = count + 1; } generate(count); - fclose(f_m); + /* Traitement erreur */ + //fclose(f_m); //2 f_k = fopen(cheminFic_k, "wb"); - if (f_k) + while (f_k) { fwrite(cle, sizeof(char), count, f_k); - } - else - { - return EXIT_FAILURE; - } + } + fclose(f_k); f_k = fopen(cheminFic_k, "r"); /* Traitement erreur */ - fclose(f_k); + //fclose(f_k); //3 - f_mc = fopen(cheminFic_mc, "w"); - /* Traitement erreur */ - fclose(f_mc); - - f_m = fopen(cheminFic_m, "r"); - f_k = fopen(cheminFic_k, "r"); f_mc = fopen(cheminFic_mc, "wb"); + /* Traitement erreur */ + //fclose(f_mc); + + //f_m = fopen(cheminFic_m, "r"); + //f_k = fopen(cheminFic_k, "r"); + //f_mc = fopen(cheminFic_mc, "wb"); while ((c = fgetc(f_m)) != EOF) { k1 = fgetc(f_k); diff --git a/prgm/run b/prgm/run new file mode 100755 index 0000000..a0efa8c Binary files /dev/null and b/prgm/run differ