X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=recv.c;h=df8b9ce99e445f3acce568486c02878276f03576;hp=52935a8840462af33589ed1378b481c593c405a1;hb=de9a70360fcd3b5285d280ad1f229f679d453603;hpb=40de1dd2fdbb054444d585aa70e2d50166a66e07 diff --git a/recv.c b/recv.c index 52935a88..df8b9ce9 100644 --- a/recv.c +++ b/recv.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2005-2008 Andre Noll + * Copyright (C) 2005-2009 Andre Noll * * Licensed under the GPL v2. For licencing details see COPYING. */ @@ -16,14 +16,16 @@ #include "recv.h" #include "recv.cmdline.h" #include "fd.h" +#include "string.h" #include "error.h" #include "stdout.h" /** the gengetopt args info struct */ struct recv_args_info conf; -/** always log to stderr */ -INIT_STDERR_LOGGING(conf.loglevel_arg); +static int loglevel; +/** Always log to stderr. */ +INIT_STDERR_LOGGING(loglevel); /** init array of error codes used by para_recv */ INIT_RECV_ERRLISTS; @@ -85,6 +87,7 @@ int main(int argc, char *argv[]) PARA_EMERG_LOG("parse failed\n"); goto out; } + loglevel = get_loglevel_by_name(conf.loglevel_arg); r = &receivers[receiver_num]; rn.receiver = r; ret = r->open(&rn);