diff options
author | ulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7> | 2004-04-25 12:04:08 +0000 |
---|---|---|
committer | ulfl <ulfl@f5534014-38df-0310-8fa8-9805f1628bb7> | 2004-04-25 12:04:08 +0000 |
commit | 7862ca6700cf3a8adc5822ff99e0d15d76e8df8f (patch) | |
tree | 42dde0714aef5ead2cf2385fb258bdf99c01f457 /file.c | |
parent | 9fc177114d9340c4dc998c83720755091a23d174 (diff) |
put all required data into the print_args,
instead of confusing seperation of data
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@10692 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'file.c')
-rw-r--r-- | file.c | 11 |
1 files changed, 8 insertions, 3 deletions
@@ -1,7 +1,7 @@ /* file.c * File I/O routines * - * $Id: file.c,v 1.378 2004/04/24 23:13:45 ulfl Exp $ + * $Id: file.c,v 1.379 2004/04/25 12:04:07 ulfl Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -1610,8 +1610,13 @@ print_packets(capture_file *cf, print_args_t *print_args) int line_len; psp_return_t ret; - callback_args.print_fh = open_print_dest(print_args->to_file, - print_args->dest); + if(print_args->to_file) { + callback_args.print_fh = open_print_dest(print_args->to_file, + print_args->file); + } else { + callback_args.print_fh = open_print_dest(print_args->to_file, + print_args->cmd); + } if (callback_args.print_fh == NULL) return PP_OPEN_ERROR; /* attempt to open destination failed */ |