X-Git-Url: https://git.brokenzipper.com/gitweb?a=blobdiff_plain;f=src%2Fbuffer.c;h=77ebe272f14b827a26f6506b587787917ee45b11;hb=f4e4adea80a;hp=2b53ec38d6d90d4c0ef1fed3e7373fe1b372a306;hpb=8c10111c66c83092f53a8ed029552afd780a8bca;p=chaz%2Ftar diff --git a/src/buffer.c b/src/buffer.c index 2b53ec3..77ebe27 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -338,6 +338,9 @@ print_total_stats () print_stats (stderr, _("Total bytes read"), records_read * record_size); break; + + default: + abort (); } } @@ -433,16 +436,6 @@ _open_archive (enum access_mode wanted_access) { int backed_up_flag = 0; - if (index_file_name) - { - stdlis = freopen (index_file_name, "w", stdout); - if (! stdlis) - open_error (index_file_name); - close_stdout_set_file_name (index_file_name); - } - else - stdlis = to_stdout_option ? stderr : stdout; - if (record_size == 0) FATAL_ERROR ((0, 0, _("Invalid value for record_size"))); @@ -481,10 +474,6 @@ _open_archive (enum access_mode wanted_access) abort (); /* Should not happen */ break; } - - if (wanted_access == ACCESS_WRITE - && strcmp (archive_name_array[0], "-") == 0) - stdlis = stderr; } else if (strcmp (archive_name_array[0], "-") == 0) { @@ -510,12 +499,10 @@ _open_archive (enum access_mode wanted_access) case ACCESS_WRITE: archive = STDOUT_FILENO; - stdlis = stderr; break; case ACCESS_UPDATE: archive = STDIN_FILENO; - stdlis = stderr; write_archive_to_stdout = true; record_end = record_start; /* set up for 1st record = # 0 */ break;