diff options
Diffstat (limited to 'reordercap.c')
-rw-r--r-- | reordercap.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/reordercap.c b/reordercap.c index 2f809e8cea..1e29303908 100644 --- a/reordercap.c +++ b/reordercap.c @@ -108,7 +108,8 @@ frame_write(FrameRecord_t *frame, wtap *wth, wtap_dumper *pdh, Buffer *buf) /* Dump frame to outfile */ if (!wtap_dump(pdh, &phdr, buffer_start_ptr(buf), &err)) { - printf("Error (%s) writing frame to outfile\n", wtap_strerror(err)); + fprintf(stderr, "reordercap: Error (%s) writing frame to outfile\n", + wtap_strerror(err)); exit(1); } } @@ -200,7 +201,8 @@ int main(int argc, char *argv[]) /* Open infile */ wth = wtap_open_offline(infile, &err, &err_info, TRUE); if (wth == NULL) { - printf("reorder: Can't open %s: %s\n", infile, wtap_strerror(err)); + fprintf(stderr, "reordercap: Can't open %s: %s\n", infile, + wtap_strerror(err)); exit(1); } DEBUG_PRINT("file_type is %u\n", wtap_file_type(wth)); @@ -213,7 +215,8 @@ int main(int argc, char *argv[]) 65535, FALSE, shb_hdr, idb_inf, &err); g_free(idb_inf); if (pdh == NULL) { - printf("Failed to open output file: (%s) - error %s\n", outfile, wtap_strerror(err)); + fprintf(stderr, "reordercap: Failed to open output file: (%s) - error %s\n", + outfile, wtap_strerror(err)); g_free(shb_hdr); exit(1); } @@ -269,7 +272,8 @@ int main(int argc, char *argv[]) /* Close outfile */ if (!wtap_dump_close(pdh, &err)) { - printf("Error closing %s: %s\n", outfile, wtap_strerror(err)); + fprintf(stderr, "reordercap: Error closing %s: %s\n", outfile, + wtap_strerror(err)); g_free(shb_hdr); exit(1); } |