From 789f759f4cea382053851669bb7076d9a990a2cd Mon Sep 17 00:00:00 2001 From: james <> Date: Tue, 27 Jul 2010 14:49:35 +0000 Subject: add support for byte logging --- apps/sympathy.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'apps') diff --git a/apps/sympathy.c b/apps/sympathy.c index dc79ed0..92ee3e1 100644 --- a/apps/sympathy.c +++ b/apps/sympathy.c @@ -11,6 +11,9 @@ static char rcsid[] = /* * $Log$ + * Revision 1.52 2010/07/27 14:49:34 james + * add support for byte logging + * * Revision 1.51 2010/07/16 11:04:10 james * ignore tedious return values * @@ -553,7 +556,7 @@ main (int argc, char *argv[]) memset (oflags, 0, sizeof (oflags)); memset (oargs, 0, sizeof (oargs)); - while ((c = getopt (argc, argv, "I:NCSRP:vw:utscr:lKHd:pb:fL:Fk:n:")) != EOF) + while ((c = getopt (argc, argv, "BI:NCSRP:vw:utscr:lKHd:pb:fL:Fk:n:")) != EOF) { switch (c) { @@ -691,6 +694,7 @@ main (int argc, char *argv[]) oflags['f'] = 0; oflags['L'] = 0; oflags['R'] = 0; + oflags['B'] = 0; oflags['P'] = 0; oflags['n'] = 0; oflags['w'] = 0; @@ -729,9 +733,9 @@ main (int argc, char *argv[]) fatal_moan ("-s is incompatible with -H, -N and -I"); if ((oflags['p'] || oflags['d'] || oflags['K'] || oflags['b'] || oflags['f'] - || oflags['L'] || oflags['R'] || oflags['P']) && oflags['c']) + || oflags['L'] || oflags['R'] || oflags['B'] || oflags['P']) && oflags['c']) fatal_moan - ("-c or -r are incompatible with -p, -d, -K, -b, -f, -R, -P or -L"); + ("-c or -r are incompatible with -p, -d, -K, -b, -f, -R, -P, -B or -L"); if (oflags['C'] && (!oflags['d'])) fatal_moan ("-C requires -d"); @@ -826,6 +830,7 @@ main (int argc, char *argv[]) if (oflags['L']) { ctx->l = file_log_new (oargs['L'], oflags['R']); + ctx->byte_logging=oflags['B']; if (!ctx->l) fatal_moan ("unable to access log file %s", oargs['L']); } -- cgit v1.2.3