diff options
author | Guy Harris <guy@alum.mit.edu> | 2013-03-25 11:53:56 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2013-03-25 11:53:56 +0000 |
commit | a1133d2fddd5c8d9d34be0e9928a153161388e2e (patch) | |
tree | c64ff7f46f7ae5be3cbd70eb2e28a586e6b22b3d /capture_sync.c | |
parent | f95221719432a53d8d6af1712ba9244700efa6e0 (diff) |
From Michal Labedzki: linktype_val_to_name() returns a string, not a
number, and that string is what's appropriate for the -y command-line
argument, so just directly pass it to sync_pipe_add_arg(), and get rid
of the now-unnecessary sdlt variable.
svn path=/trunk/; revision=48546
Diffstat (limited to 'capture_sync.c')
-rw-r--r-- | capture_sync.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/capture_sync.c b/capture_sync.c index 51c74bc13b..fded034adf 100644 --- a/capture_sync.c +++ b/capture_sync.c @@ -322,7 +322,6 @@ init_pipe_args(int *argc) { gboolean sync_pipe_start(capture_options *capture_opts) { char ssnap[ARGV_NUMBER_LEN]; - char sdlt[ARGV_NUMBER_LEN]; char scount[ARGV_NUMBER_LEN]; char sfilesize[ARGV_NUMBER_LEN]; char sfile_duration[ARGV_NUMBER_LEN]; @@ -452,8 +451,7 @@ sync_pipe_start(capture_options *capture_opts) { if (interface_opts.linktype != -1) { argv = sync_pipe_add_arg(argv, &argc, "-y"); - g_snprintf(sdlt, ARGV_NUMBER_LEN, "%s", linktype_val_to_name(interface_opts.linktype)); - argv = sync_pipe_add_arg(argv, &argc, sdlt); + argv = sync_pipe_add_arg(argv, &argc, linktype_val_to_name(interface_opts.linktype)); } if (!interface_opts.promisc_mode) { |