Skip to content

Commit

Permalink
Fix logic comparing log level with threshold level.
Browse files Browse the repository at this point in the history
  • Loading branch information
sobomax committed Mar 4, 2020
1 parent 51e2f1f commit 94c8429
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rtpp_log_obj.c
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ rtpp_log_obj_write_early(struct rtpp_log *self, const char *fname, int lnum,
struct rtpp_log_priv *pvt;

PUB2PVT(self, pvt);
if (level < pvt->level)
if (level > pvt->level)
return;
fprintf(stderr, "%s: ", fname);
va_start(ap, fmt);
Expand All @@ -179,7 +179,7 @@ rtpp_log_obj_ewrite_early(struct rtpp_log *self, const char *fname, int lnum,
struct rtpp_log_priv *pvt;

PUB2PVT(self, pvt);
if (level < pvt->level)
if (level > pvt->level)
return;
fprintf(stderr, "%s: ", fname);
va_start(ap, fmt);
Expand Down

0 comments on commit 94c8429

Please sign in to comment.