From 8ad56e8eda4a63e9a81c275e4eb26e9239237ad4 Mon Sep 17 00:00:00 2001
From: gcontini <1121667+gcontini@users.noreply.github.com>
Date: 周六, 28 11月 2020 09:31:41 +0800
Subject: [PATCH] replace strncpy with a more safe alternative

---
 src/library/ini/SimpleIni.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/library/ini/SimpleIni.h b/src/library/ini/SimpleIni.h
index ac703b2..7142085 100644
--- a/src/library/ini/SimpleIni.h
+++ b/src/library/ini/SimpleIni.h
@@ -223,7 +223,7 @@
 # include <iostream>
 #endif // SI_SUPPORT_IOSTREAMS
 
-#ifdef _DEBUG
+#ifndef NDEBUG
 # ifndef assert
 #  include <cassert>
 # endif
@@ -2488,7 +2488,7 @@
 
         bNeedNewLine = true;
     }
-    
+
     // Append new empty line
     a_oOutput.Write(SI_NEWLINE_A);
 

--
Gitblit v1.9.1