From 7ad10ba73418d71b1b46868b026983b615fbd42f Mon Sep 17 00:00:00 2001 From: Jonathan Hoffstadt Date: Thu, 26 Sep 2024 19:59:32 -0500 Subject: [PATCH] fix: pl_log console issue --- pl_log.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pl_log.h b/pl_log.h index 5d8fcdb..5057e14 100644 --- a/pl_log.h +++ b/pl_log.h @@ -12,8 +12,8 @@ */ // library version -#define PL_LOG_VERSION "0.5.2" -#define PL_LOG_VERSION_NUM 00502 +#define PL_LOG_VERSION "0.5.3" +#define PL_LOG_VERSION_NUM 00503 /* Index of this file: @@ -851,13 +851,13 @@ pl__get_log_channels(uint32_t* puChannelCount) #define PL__LOG_LEVEL_MACRO(level, prefix, prefixSize) \ plLogChannel* tPChannel = &gptLogContext->atChannels[uID]; \ - plLogEntry* ptEntry = pl__get_new_log_entry(uID); \ if(tPChannel->uLevel < level + 1) \ { \ if(tPChannel->tType & PL_CHANNEL_TYPE_CONSOLE) \ printf(prefix " (%s) %s\n", tPChannel->pcName, pcMessage); \ if((tPChannel->tType & PL_CHANNEL_TYPE_CYCLIC_BUFFER) || (tPChannel->tType & PL_CHANNEL_TYPE_BUFFER)) \ { \ + plLogEntry* ptEntry = pl__get_new_log_entry(uID); \ const size_t szNewSize = strlen(pcMessage) + 10; \ pl__log_buffer_may_grow(tPChannel, (int)szNewSize); \ ptEntry->uOffset = tPChannel->uBufferSize; \