From 1986ffca2f9eccbc05318ddd39c05b44d742c332 Mon Sep 17 00:00:00 2001 From: armink Date: Fri, 4 Jan 2019 22:45:58 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E4=BF=AE=E5=A4=8D=E3=80=91elog=5Fstrc?= =?UTF-8?q?py=20=E5=8F=AF=E8=83=BD=E5=AD=98=E5=9C=A8=E5=86=85=E5=AD=98?= =?UTF-8?q?=E5=86=99=E7=A9=BF=E7=9A=84=E9=97=AE=E9=A2=98=EF=BC=88PS:?= =?UTF-8?q?=E4=B9=8B=E5=89=8D=E5=BA=94=E7=94=A8=E5=B1=82=E5=B7=B2=E8=A7=84?= =?UTF-8?q?=E9=81=BF=EF=BC=89=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: armink --- easylogger/src/elog_utils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/easylogger/src/elog_utils.c b/easylogger/src/elog_utils.c index d33573f..165d855 100644 --- a/easylogger/src/elog_utils.c +++ b/easylogger/src/elog_utils.c @@ -1,7 +1,7 @@ /* * This file is part of the EasyLogger Library. * - * Copyright (c) 2015-2017, Armink, + * Copyright (c) 2015-2018, Armink, * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the @@ -46,7 +46,7 @@ size_t elog_strcpy(size_t cur_len, char *dst, const char *src) { while (*src != 0) { /* make sure destination has enough space */ - if (cur_len++ <= ELOG_LINE_BUF_SIZE) { + if (cur_len++ < ELOG_LINE_BUF_SIZE) { *dst++ = *src++; } else { break;