From 7f88e85c9b754025cf07955af659f26aec3c1a7c Mon Sep 17 00:00:00 2001 From: Sven Strickroth Date: Sun, 11 Jun 2017 19:01:25 +0200 Subject: [PATCH] Add make-compile-vs2013.patch Signed-off-by: Sven Strickroth --- ext/scintilla/make-compile-vs2013.patch | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 ext/scintilla/make-compile-vs2013.patch diff --git a/ext/scintilla/make-compile-vs2013.patch b/ext/scintilla/make-compile-vs2013.patch new file mode 100644 index 000000000..b39a32726 --- /dev/null +++ b/ext/scintilla/make-compile-vs2013.patch @@ -0,0 +1,29 @@ + ext/scintilla/src/UniqueString.h | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/ext/scintilla/src/UniqueString.h b/ext/scintilla/src/UniqueString.h +index a5c64e053..a32a17a80 100644 +--- a/ext/scintilla/src/UniqueString.h ++++ b/ext/scintilla/src/UniqueString.h +@@ -13,7 +13,7 @@ + namespace Scintilla { + #endif + +-using UniqueString = std::unique_ptr; ++using UniqueString = std::unique_ptr; + + /// Equivalent to strdup but produces a std::unique_ptr allocation to go + /// into collections. +@@ -22,9 +22,9 @@ inline UniqueString UniqueStringCopy(const char *text) { + return UniqueString(); + } + const size_t len = strlen(text); +- char *sNew = new char[len + 1]; +- std::copy(text, text + len + 1, sNew); +- return UniqueString(sNew); ++ auto sNew = std::make_unique(len + 1); ++ std::copy(text, text + len + 1, sNew.get()); ++ return sNew; + } + + #ifdef SCI_NAMESPACE -- 2.11.4.GIT