aboutsummaryrefslogtreecommitdiff
path: root/src/util/common_logging.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2019-10-31 13:03:48 +0100
committerChristian Grothoff <christian@grothoff.org>2019-10-31 13:03:48 +0100
commit7e3cf5f461eb4fbb7581672bf0835da07c378136 (patch)
treebdc3874b7894242b095b892f1ed3e81a4d4f06c0 /src/util/common_logging.c
parent01b480d6d026e0c537dc284a7e7df2c0320a3528 (diff)
downloadgnunet-7e3cf5f461eb4fbb7581672bf0835da07c378136.tar.gz
gnunet-7e3cf5f461eb4fbb7581672bf0835da07c378136.zip
tighten formatting rules
Diffstat (limited to 'src/util/common_logging.c')
-rw-r--r--src/util/common_logging.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/src/util/common_logging.c b/src/util/common_logging.c
index 3ff9bf18e..d13f3a7fa 100644
--- a/src/util/common_logging.c
+++ b/src/util/common_logging.c
@@ -401,6 +401,8 @@ setup_log_file (const struct tm *tm)
401 GNUNET_stderr = altlog; 401 GNUNET_stderr = altlog;
402 return GNUNET_OK; 402 return GNUNET_OK;
403} 403}
404
405
404#endif 406#endif
405 407
406 408
@@ -504,7 +506,7 @@ GNUNET_get_log_call_status (int caller_level,
504 { 506 {
505 ld = &logdefs[i]; 507 ld = &logdefs[i];
506 if (((! force_only) || ld->force) && 508 if (((! force_only) || ld->force) &&
507 ((line >= ld->from_line) &&(line <= ld->to_line) ) && 509 ((line >= ld->from_line) && (line <= ld->to_line) ) &&
508 (0 == regexec (&ld->component_regex, comp, 0, NULL, 0)) && 510 (0 == regexec (&ld->component_regex, comp, 0, NULL, 0)) &&
509 (0 == regexec (&ld->file_regex, file, 0, NULL, 0)) && 511 (0 == regexec (&ld->file_regex, file, 0, NULL, 0)) &&
510 (0 == regexec (&ld->function_regex, function, 0, NULL, 0))) 512 (0 == regexec (&ld->function_regex, function, 0, NULL, 0)))
@@ -693,6 +695,8 @@ parse_all_definitions ()
693 parse_definitions ("GNUNET_LOG", 0); 695 parse_definitions ("GNUNET_LOG", 0);
694 gnunet_log_parsed = GNUNET_YES; 696 gnunet_log_parsed = GNUNET_YES;
695} 697}
698
699
696#endif 700#endif
697 701
698 702
@@ -823,8 +827,7 @@ output_message (enum GNUNET_ErrorType kind,
823 * interactively, yet the same message shouldn't look 827 * interactively, yet the same message shouldn't look
824 * this way if the output is going to logfiles or robots 828 * this way if the output is going to logfiles or robots
825 * instead. 829 * instead.
826 */ 830 */fprintf (GNUNET_stderr, "* %s", msg);
827 fprintf (GNUNET_stderr, "* %s", msg);
828 } 831 }
829 else if (GNUNET_YES == current_async_scope.have_scope) 832 else if (GNUNET_YES == current_async_scope.have_scope)
830 { 833 {
@@ -1545,7 +1548,8 @@ GNUNET_async_scope_get (struct GNUNET_AsyncScopeSave *scope_ret)
1545/** 1548/**
1546 * Initializer 1549 * Initializer
1547 */ 1550 */
1548void __attribute__ ((constructor)) GNUNET_util_cl_init () 1551void __attribute__ ((constructor))
1552GNUNET_util_cl_init ()
1549{ 1553{
1550 GNUNET_stderr = stderr; 1554 GNUNET_stderr = stderr;
1551} 1555}
@@ -1554,9 +1558,11 @@ void __attribute__ ((constructor)) GNUNET_util_cl_init ()
1554/** 1558/**
1555 * Destructor 1559 * Destructor
1556 */ 1560 */
1557void __attribute__ ((destructor)) GNUNET_util_cl_fini () 1561void __attribute__ ((destructor))
1562GNUNET_util_cl_fini ()
1558{ 1563{
1559 1564
1560} 1565}
1561 1566
1567
1562/* end of common_logging.c */ 1568/* end of common_logging.c */