From 504c1d13cc715382d96c2eca3968e38a511368c8 Mon Sep 17 00:00:00 2001 From: cxl Date: Thu, 9 Mar 2017 11:43:56 +0000 Subject: [PATCH] RichText: Fixed to achieve compatibility with older CLANG git-svn-id: svn://ultimatepp.org/upp/trunk@10928 f0d560ea-af0d-0410-9eb7-867de7ffcac7 --- uppsrc/Core/SSL/SSL.h | 4 ++++ uppsrc/Core/SSL/init | 6 ++++++ uppsrc/RichEdit/init | 4 ++++ uppsrc/RichText/Table.h | 4 ++++ uppsrc/RichText/init | 5 +++++ 5 files changed, 23 insertions(+) create mode 100644 uppsrc/Core/SSL/init create mode 100644 uppsrc/RichEdit/init create mode 100644 uppsrc/RichText/init diff --git a/uppsrc/Core/SSL/SSL.h b/uppsrc/Core/SSL/SSL.h index 2e2234fb3..a16399a3a 100644 --- a/uppsrc/Core/SSL/SSL.h +++ b/uppsrc/Core/SSL/SSL.h @@ -46,7 +46,11 @@ public: bool IsEmpty() const { return !bio; } bool Set(BIO *b) { Clear(); return !!(bio = b); } +#if OPENSSL_VERSION_NUMBER >= 0x10100000L bool Create(const BIO_METHOD *meth) { return Set(BIO_new(meth)); } +#else + bool Create(BIO_METHOD *meth) { return Set(BIO_new(meth)); } +#endif void Clear() { if(bio) { BIO_free(bio); bio = NULL; } } bool OpenBuffer(const char *data, int length); diff --git a/uppsrc/Core/SSL/init b/uppsrc/Core/SSL/init new file mode 100644 index 000000000..34d17724c --- /dev/null +++ b/uppsrc/Core/SSL/init @@ -0,0 +1,6 @@ +#ifndef _Core_SSL_icpp_init_stub +#define _Core_SSL_icpp_init_stub +#define BLITZ_INDEX__ F92bd8f18f9eb3ff16ad250c0ea8df0e9 +#include "Init.icpp" +#undef BLITZ_INDEX__ +#endif diff --git a/uppsrc/RichEdit/init b/uppsrc/RichEdit/init new file mode 100644 index 000000000..ac907a798 --- /dev/null +++ b/uppsrc/RichEdit/init @@ -0,0 +1,4 @@ +#ifndef _RichEdit_icpp_init_stub +#define _RichEdit_icpp_init_stub +#include "CtrlLib/init" +#endif diff --git a/uppsrc/RichText/Table.h b/uppsrc/RichText/Table.h index e06834ec7..c7c966077 100644 --- a/uppsrc/RichText/Table.h +++ b/uppsrc/RichText/Table.h @@ -110,6 +110,9 @@ private: PaintRow& operator[](int i) { return row[i]; } const PaintRow& operator[](int i) const { return row[i]; } + + rval_default(Layout); // Old CLANG requires this + Layout() {} }; struct TabLayout : Layout { @@ -123,6 +126,7 @@ private: Rect next_page; Rect header_page; + rval_default(TabLayout); // Old CLANG requires this TabLayout() {} }; diff --git a/uppsrc/RichText/init b/uppsrc/RichText/init new file mode 100644 index 000000000..1a3716e18 --- /dev/null +++ b/uppsrc/RichText/init @@ -0,0 +1,5 @@ +#ifndef _RichText_icpp_init_stub +#define _RichText_icpp_init_stub +#include "plugin\png/init" +#include "Draw/init" +#endif