The patch below seems to help. OK to commit? I'm looking at you, Stephan;)

--tml

diff --git a/codemaker/source/javamaker/javatype.cxx
b/codemaker/source/javamaker/javatype.cxx
index 1453122..f297980 100644
--- a/codemaker/source/javamaker/javatype.cxx
+++ b/codemaker/source/javamaker/javatype.cxx
@@ -2447,7 +2447,10 @@ void addConstant(
                 rtl::OString(
                     RTL_CONSTASCII_STRINGPARAM("Bad type
information"))); //TODO
         }
-        valueIndex = classFile->addIntegerInfo(fieldValue.m_value.aByte);
+        if (fieldValue.m_value.aByte < 0x80)
+            valueIndex = classFile->addIntegerInfo(fieldValue.m_value.aByte);
+        else
+            valueIndex = classFile->addIntegerInfo(-256 + (int)
fieldValue.m_value.aByte);
         break;

     case codemaker::UnoType::SORT_SHORT:
_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to