Dave Stubbs a �crit :
> Tomi Manninen wrote:
>
> >On Sun, 2005-03-06 at 15:12, Dave Stubbs wrote:
> >
> >
> >
> >>So, a new question - does anyone know where the console messages (they
> >>start with "Tx:") come from? Can they be redirected to syslog or sent
> >>there instead of the console?
> >>
> >>
> >
> >It's soundmodem in soundcard/kisspkt.c:
> >
> > line 306: printf("Rx: %s\n", buf);
> >
> >and
> >
> > line 407: printf("Tx: %s\n", buf);
> >
> >So it's hardcoded to go to stdout, you need to modify the source to
> >make it go elsewhere.
> >
> >
> >
> Indeed.
>
> Well, there's the culprit. Actually, what I would really like to see is
> the same output from *listen -a* showing up in the syslog. Is there a
> way to do something like "listen -a > /dev/log" or something like that?
> It seems that I can't redirect stdout to a FIFO, or this would work. Is
> there a tool that would do it then?
>
> Thanks for the help,
>
> Dave
> -
I used this function for showing up in the syslog, it may be modified for your
use:
#include <syslog.h>
#define LOG_LEVEL LOG_INFO
void log(int loglevel, const char *fmt, ...)
{
va_list args;
int pri;
static int opened = 0;
if (!opened) {
openlog("your_identifier", LOG_CONS, LOG_LOCAL6);
opened = 1;
}
pri = loglevel;
va_start(args, fmt);
vsprintf(buf, fmt, args);
syslog(pri, buf);
va_end(args);
}
log(LOG_LEVEL, "%d %s%d.%06d %ld\n", dcft.tv_sec, sign? "-": "+", delta.tv_sec,
delta.tv_usec, tx.freq);
--
73 G�rard F6FGZ
-
To unsubscribe from this list: send the line "unsubscribe linux-hams" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html