Hi,

I found a few instances of bugs in the engima sources which broke compilation with a C++11 compiler, mainly related to illegal conversions. Patches attached.

This occurred when building with Xerces-C 3.2.0 with C++11 support for char16_t strings enabled.


Regards,
Roger
--- src/lev/Proxy.cc.orig	2017-09-03 15:54:50 UTC
+++ src/lev/Proxy.cc
@@ -933,7 +933,7 @@ namespace enigma { namespace lev {
                     } else if (haveLocalCopy) {
                         // plain file
                         basic_ifstream<char> ifs(absExtPath.c_str(), ios::binary | ios::in);
-                        if (ifs != NULL)
+                        if (ifs)
                             Readfile(ifs, extCode);
                         else
                             haveLocalCopy = false;
--- src/Value.cc.orig	2017-09-03 15:39:37 UTC
+++ src/Value.cc
@@ -146,10 +146,10 @@ namespace enigma {
                 val.str[0] = 0;
                 break;
             case BOOL :
-                val.dval[0] = false;
+                val.dval[0] = 0;
                 break;
             case OBJECT :
-                val.dval[0] = (double) NULL;
+                val.dval[0] = 0;
                 break;
             case NAMEDOBJECT:
                 ASSERT(false, XLevelRuntime, "Value: illegal type usage");
_______________________________________________
Enigma-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/enigma-devel

Reply via email to