From: popo Date: Fri, 27 May 2011 03:37:10 +0000 (+0000) Subject: use "WARNING" and "ERROR" for warning messages and error messages respectively. X-Git-Tag: v190~18 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5df16eac25535f8161cf35842cd1d3a16bb166ce;p=liblinear use "WARNING" and "ERROR" for warning messages and error messages respectively. --- diff --git a/linear.cpp b/linear.cpp index 1523703..76e81d6 100644 --- a/linear.cpp +++ b/linear.cpp @@ -1885,7 +1885,7 @@ static void train_one(const problem *prob, const parameter *param, double *w, do solve_l2r_lr_dual(prob, w, eps, Cp, Cn); break; default: - fprintf(stderr, "Error: unknown solver_type\n"); + fprintf(stderr, "ERROR: unknown solver_type\n"); break; } } diff --git a/train.c b/train.c index 4920313..c5fa1d8 100644 --- a/train.c +++ b/train.c @@ -94,7 +94,7 @@ int main(int argc, char **argv) if(error_msg) { - fprintf(stderr,"Error: %s\n",error_msg); + fprintf(stderr,"ERROR: %s\n",error_msg); exit(1); } diff --git a/tron.cpp b/tron.cpp index bff5078..b54bedf 100644 --- a/tron.cpp +++ b/tron.cpp @@ -135,18 +135,18 @@ void TRON::tron(double *w) } if (f < -1.0e+32) { - info("warning: f < -1.0e+32\n"); + info("WARNING: f < -1.0e+32\n"); break; } if (fabs(actred) <= 0 && prered <= 0) { - info("warning: actred and prered <= 0\n"); + info("WARNING: actred and prered <= 0\n"); break; } if (fabs(actred) <= 1.0e-12*fabs(f) && fabs(prered) <= 1.0e-12*fabs(f)) { - info("warning: actred and prered too small\n"); + info("WARNING: actred and prered too small\n"); break; } }