From ba36c3ee7f3c807ac07b04bb181a742eae865a60 Mon Sep 17 00:00:00 2001 From: hunt Date: Fri, 1 Jul 2005 19:40:50 +0000 Subject: [PATCH] 2005-07-01 Martin Hunt * string.c (_stp_string_init): CAll stp_error() on bad init. * list.c (_stp_list_clear): Call _stp_warn(). --- runtime/ChangeLog | 5 +++++ runtime/io.c | 6 +++--- runtime/list.c | 2 +- runtime/string.c | 2 +- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/runtime/ChangeLog b/runtime/ChangeLog index 718716244..3cf6d3aec 100644 --- a/runtime/ChangeLog +++ b/runtime/ChangeLog @@ -1,5 +1,10 @@ 2005-07-01 Martin Hunt + * string.c (_stp_string_init): CAll stp_error() on bad + init. + + * list.c (_stp_list_clear): Call _stp_warn(). + * probes.c: Convert all _stp_log() calls to either stp_warn() or dbug(). diff --git a/runtime/io.c b/runtime/io.c index dd74eea88..d59b511aa 100644 --- a/runtime/io.c +++ b/runtime/io.c @@ -12,6 +12,9 @@ #include "transport/transport.c" +void _stp_print_flush (void); +void _stp_string_cat_cstr (String str1, const char *str2); + /** @file io.c * @brief I/O for printing warnings, errors and debug messages. */ @@ -28,9 +31,6 @@ static char _stp_lbuf[NR_CPUS][STP_LOG_BUF_LEN + 1]; enum code { INFO=0, WARN, ERROR, DBUG }; -void _stp_print_flush (void); -void _stp_string_cat_cstr (String str1, const char *str2); - static void _stp_vlog (enum code type, char *func, int line, const char *fmt, va_list args) { int num, ret; diff --git a/runtime/list.c b/runtime/list.c index fb5e670b5..4643634bc 100644 --- a/runtime/list.c +++ b/runtime/list.c @@ -70,7 +70,7 @@ void _stp_list_clear(MAP map) } if (map->num != 0) { - _stp_log ("ERROR: list is supposed to be empty (has %d)\n", map->num); + _stp_warn ("list is supposed to be empty (has %d)\n", map->num); } } diff --git a/runtime/string.c b/runtime/string.c index 6ef261904..ef715b402 100644 --- a/runtime/string.c +++ b/runtime/string.c @@ -26,7 +26,7 @@ String _stp_string_init (int num) String str; if (num >= STP_NUM_STRINGS || num < 0) { - _stp_log ("_stp_string_init internal error: requested string exceeded allocated number or was negative"); + _stp_error ("_stp_string_init internal error: requested string exceeded allocated number or was negative"); return NULL; } str = &_stp_string[num][smp_processor_id()]; -- 2.43.5