[ooo-build-commit] Branch 'ooo/master' - 3 commits - bridges/source bridges/test cpputools/source io/inc io/source io/test javaunohelper/com javaunohelper/test jurt/com jurt/demo jurt/test jurt/workbench offapi/com offapi/prj offapi/util offuh/prj pyuno/source pyuno/zipcore remotebridges/source ridljar/com ridljar/test sal/osl ure/source

Jan Holesovsky kendy at kemper.freedesktop.org
Wed Sep 16 20:01:04 PDT 2009


 bridges/source/cpp_uno/gcc3_macosx_powerpc/uno2cpp.cxx                               |    3 
 bridges/test/com/sun/star/lib/TestBed.java                                           |    4 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug107753_Test.java            |   14 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug108825_Test.java            |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug110892_Test.java            |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug111153_Test.java            |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug51323_Test.java             |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug92174_Test.java             |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug97697_Test.java             |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug98508_Test.java             |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/MethodIdTest.java              |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/PolyStructTest.java            |    2 
 bridges/test/com/sun/star/lib/uno/bridges/java_remote/StopMessageDispatcherTest.java |    2 
 bridges/test/java_uno/acquire/TestAcquire.java                                       |    4 
 bridges/test/java_uno/any/TestRemote.java                                            |    2 
 bridges/test/java_uno/equals/TestEquals.java                                         |   40 --
 bridges/test/java_uno/nativethreadpool/Relay.java                                    |    2 
 bridges/test/testclient.java                                                         |    4 
 cpputools/source/regcomplazy/regcomplazy.cxx                                         |    2 
 io/inc/makefile.mk                                                                   |    6 
 io/source/TextInputStream/makefile.mk                                                |    2 
 io/source/TextOutputStream/makefile.mk                                               |    2 
 io/source/acceptor/makefile.mk                                                       |    3 
 io/source/connector/makefile.mk                                                      |    2 
 io/source/stm/makefile.mk                                                            |    4 
 io/test/makefile.mk                                                                  |    2 
 io/test/stm/makefile.mk                                                              |    2 
 javaunohelper/com/sun/star/comp/helper/Bootstrap.java                                |   20 -
 javaunohelper/com/sun/star/comp/helper/ComponentContext.java                         |   12 
 javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java                   |    2 
 javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java                      |    4 
 javaunohelper/com/sun/star/comp/juhtest/SmoketestCommandEnvironment.java             |    2 
 javaunohelper/com/sun/star/lib/uno/helper/Factory.java                               |    2 
 javaunohelper/com/sun/star/lib/uno/helper/InterfaceContainer.java                    |    2 
 javaunohelper/com/sun/star/lib/uno/helper/PropertySet.java                           |    2 
 javaunohelper/com/sun/star/lib/uno/helper/PropertySetMixin.java                      |   94 ++---
 javaunohelper/test/com/sun/star/comp/helper/Bootstrap_Test.java                      |    4 
 javaunohelper/test/com/sun/star/comp/helper/ComponentContext_Test.java               |    2 
 javaunohelper/test/com/sun/star/comp/helper/SharedLibraryLoader_Test.java            |   10 
 javaunohelper/test/com/sun/star/lib/uno/helper/ComponentBase_Test.java               |    6 
 javaunohelper/test/com/sun/star/lib/uno/helper/Factory_Test.java                     |    8 
 jurt/com/sun/star/comp/bridgefactory/BridgeFactory.java                              |    8 
 jurt/com/sun/star/comp/loader/FactoryHelper.java                                     |    4 
 jurt/com/sun/star/comp/loader/JavaLoader.java                                        |    2 
 jurt/com/sun/star/comp/servicemanager/ServiceManager.java                            |   18 -
 jurt/com/sun/star/comp/urlresolver/UrlResolver.java                                  |    4 
 jurt/com/sun/star/uno/WeakReference.java                                             |    4 
 jurt/demo/com/sun/star/demo/DemoServer.java                                          |    4 
 jurt/demo/com/sun/star/demo/TestOffice.java                                          |   18 -
 jurt/test/com/sun/star/comp/bridgefactory/BridgeFactory_Test.java                    |    4 
 jurt/test/com/sun/star/lib/uno/bridges/java_remote/java_remote_bridge_Test.java      |    6 
 jurt/workbench/com/sun/star/comp/urlresolver/UrlResolver_Test.java                   |    6 
 offapi/com/sun/star/modules.idl                                                      |    3 
 offapi/com/sun/star/office/XAnnotation.idl                                           |  105 ++++++
 offapi/com/sun/star/office/XAnnotationAccess.idl                                     |   75 ++++
 offapi/com/sun/star/office/XAnnotationEnumeration.idl                                |   74 ++++
 offapi/com/sun/star/office/makefile.mk                                               |   51 ++
 offapi/prj/build.lst                                                                 |    3 
 offapi/util/makefile.mk                                                              |    1 
 offuh/prj/d.lst                                                                      |    4 
 pyuno/source/loader/makefile.mk                                                      |    6 
 pyuno/source/module/makefile.mk                                                      |    5 
 pyuno/zipcore/makefile.mk                                                            |    7 
 remotebridges/source/bridge/makefile.mk                                              |    2 
 remotebridges/source/dynamicloader/makefile.mk                                       |    2 
 remotebridges/source/factory/makefile.mk                                             |    2 
 remotebridges/source/unourl_resolver/makefile.mk                                     |    2 
 ridljar/com/sun/star/uno/UnoRuntime.java                                             |    5 
 ridljar/test/com/sun/star/uno/UnoRuntime_Test.java                                   |    8 
 sal/osl/unx/process.c                                                                |  175 ++++------
 sal/osl/unx/signal.c                                                                 |   92 +++++
 ure/source/uretest/JavaClient.java                                                   |   10 
 72 files changed, 699 insertions(+), 299 deletions(-)

New commits:
commit 782b9f804ebb7035d570735cf1935f9845a17996
Author: Jens-Heiner Rechtien <hr at openoffice.org>
Date:   Wed Sep 16 14:37:52 2009 +0000

    CWS-TOOLING: integrate CWS sb113
    2009-09-01 sb #i76393# second attempt at properly #ifdef-ing previous HG commit d598efdbf012
    2009-08-28 sb #i102469# change back <T extends XInterface> to just <T> on queryInterface, to avoid binary incompatibility (method changing its signature from (Ljava/lang/Class;Ljava/lang/Object;)Ljava/lang/Object; to (Ljava/lang/Class;Ljava/lang/Object;)Lcom/sun/star/uno/XInterface;)
    2009-08-28 sb #i76393# properly #ifdef previous HG commit d598efdbf012
    2009-08-27 sb #i94421# work around compiler error (based on a patch supplied by cloph)
    2009-08-26 sb merged in DEV300_m56
    2009-08-26 sb #i76393# on Linux, include dynamic section offset in crash report so as to be able to map "prelinked" callstacks back to original (patch by cmc)
    2009-08-26 sb #i88162# remove unnecessary whitespace lines from per-locale xcu files (patch by tora)
    2009-08-17 Juergen Schmidt #i104292# set context classloader after create new custom UNO loader
    2009-08-17 Juergen Schmidt #i103749# integrate patch
    2009-08-14 sb #i103269# cherry-picked ssh://hg@hg.services.openoffice.org/cws/sb111 -r 5124ebd5edd1 ("#i101955# changed encoding of XML file content from erroneous ISO-8859-1 to UTF-8")
    2009-08-12 sb #i102469# fixed mis-applications of UnoRuntime.queryInterface (detected via the simplified UnoRuntime.queryInterface, the HG changeset 29de35fc9554) to use AnyConverter instead; changed qadevOOo's lib.MultiMethodTest.before to allow throwing arbitrary exceptions, to cater for IllegalArgumentException thrown by AnyConverter
    2009-08-12 sb #i104178# drop extra libxml2-config script from libxmlsec
    2009-08-10 sb #i101754# simplified osl_getProcessInfo for LINUX (patch by cmc)
    2009-08-10 sb #i95018# avoid closing -1 fds (patch supplied by cmc)
    2009-08-10 sb #i103585# removed (apparently unnecessary) zlib support from libxml2; in turn, removed zlib dependencies from libxmlsec, libxslt, and redland (assuming those were transitive dependencies brought in by direct dependencies on libxml2)
    2009-08-10 sb #i102469# simplified UnoRuntime.queryInterface using Java 5 generics; adapted URE-related modules accordingly
    2009-08-10 sb #i101213# adapted setsolar env (solenv/config/) to set PYTHONPATH (and not set PYTHONHOME) in accordance with configure env (set_soenv.in); fixed testtools/source/bridgetest/pyuno (which now should work everywhere out of the box, thanks to the fixed setsolar PYTHONPATH)
    2009-08-10 sb cherry-picked ssh://hg@hg.services.openoffice.org/cws/sb111 -r ea8de6d9396b ("#i101955# work in progress for a .hgignore file, continued")

diff --git a/bridges/source/cpp_uno/gcc3_macosx_powerpc/uno2cpp.cxx b/bridges/source/cpp_uno/gcc3_macosx_powerpc/uno2cpp.cxx
index 50731e6..3e20790 100644
--- a/bridges/source/cpp_uno/gcc3_macosx_powerpc/uno2cpp.cxx
+++ b/bridges/source/cpp_uno/gcc3_macosx_powerpc/uno2cpp.cxx
@@ -110,6 +110,9 @@ static void callVirtualMethod(
      /* set up a pointer to the stack parameter area */
      __asm__ ( "addi %0,r1,24" : "=r" (p) : /* no inputs */ );
 
+     // #i94421#, work around compiler error:
+     volatile long * pCopy = p;
+     (void) pCopy; // avoid warning about unused variable
 
      // never called
      // if (! pAdjustedThisPtr )CPPU_CURRENT_NAMESPACE::dummy_can_throw_anything("xxx"); // address something
diff --git a/bridges/test/com/sun/star/lib/TestBed.java b/bridges/test/com/sun/star/lib/TestBed.java
index d72f82a..565bc7f 100644
--- a/bridges/test/com/sun/star/lib/TestBed.java
+++ b/bridges/test/com/sun/star/lib/TestBed.java
@@ -130,7 +130,7 @@ public final class TestBed {
             throws com.sun.star.uno.Exception
         {
             XConnector connector = Connector.create(context);
-            XBridgeFactory factory = (XBridgeFactory) UnoRuntime.queryInterface(
+            XBridgeFactory factory = UnoRuntime.queryInterface(
                 XBridgeFactory.class,
                 context.getServiceManager().createInstanceWithContext(
                     "com.sun.star.bridge.BridgeFactory", context));
@@ -169,7 +169,7 @@ public final class TestBed {
                     = Bootstrap.createInitialComponentContext(null);
                 XAcceptor acceptor = Acceptor.create(context);
                 XBridgeFactory factory
-                    = (XBridgeFactory) UnoRuntime.queryInterface(
+                    = UnoRuntime.queryInterface(
                         XBridgeFactory.class,
                         context.getServiceManager().createInstanceWithContext(
                             "com.sun.star.bridge.BridgeFactory", context));
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug107753_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug107753_Test.java
index 14bce92..00c7468 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug107753_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug107753_Test.java
@@ -68,22 +68,19 @@ public final class Bug107753_Test extends ComplexTestCase {
 
         protected boolean run(XComponentContext context) throws Throwable {
             boolean success = true;
-            XTransport transport = (XTransport) UnoRuntime.queryInterface(
+            XTransport transport = UnoRuntime.queryInterface(
                 XTransport.class, getBridge(context).getInstance("Transport"));
 
             Object obj1a = new XType1() {};
-            XType1 obj1b = (XType1) UnoRuntime.queryInterface(XType1.class,
-                                                              obj1a);
+            XType1 obj1b = UnoRuntime.queryInterface(XType1.class, obj1a);
             success &= test("obj1a == obj1b", obj1a == obj1b);
 
             Object obj2a = new XType2() {};
-            XType2 obj2b = (XType2) UnoRuntime.queryInterface(XType2.class,
-                                                              obj2a);
+            XType2 obj2b = UnoRuntime.queryInterface(XType2.class, obj2a);
             success &= test("obj2a == obj2b", obj2a == obj2b);
 
             Object obj3a = transport.getType1();
-            XType1 obj3b = (XType1) UnoRuntime.queryInterface(XType1.class,
-                                                              obj3a);
+            XType1 obj3b = UnoRuntime.queryInterface(XType1.class, obj3a);
             success &= test(
                 "obj3a != obj3b; only meaningful as long as different proxy"
                 + " instances are used for different UNO interfaces of one UNO"
@@ -91,8 +88,7 @@ public final class Bug107753_Test extends ComplexTestCase {
                 obj3a != obj3b);
 
             Object obj4a = transport.getType2();
-            XType2 obj4b = (XType2) UnoRuntime.queryInterface(XType2.class,
-                                                              obj4a);
+            XType2 obj4b = UnoRuntime.queryInterface(XType2.class, obj4a);
             success &= test(
                 "obj4a != obj4b; only meaningful as long as different proxy"
                 + " instances are used for different UNO interfaces of one UNO"
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug108825_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug108825_Test.java
index 7b189e8..bc94566 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug108825_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug108825_Test.java
@@ -68,7 +68,7 @@ public final class Bug108825_Test extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTest test = (XTest) UnoRuntime.queryInterface(
+            XTest test = UnoRuntime.queryInterface(
                 XTest.class, getBridge(context).getInstance("Test"));
             // Send the XObject that is held on the server side amidst two
             // dummies that are not held on the server side; then wait for the
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug110892_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug110892_Test.java
index c257870..9d9b19a 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug110892_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug110892_Test.java
@@ -71,7 +71,7 @@ public final class Bug110892_Test extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTest test = (XTest) UnoRuntime.queryInterface(
+            XTest test = UnoRuntime.queryInterface(
                 XTest.class, getBridge(context).getInstance("Test"));
             test.start(new ClientObject());
             synchronized (lock) {
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug111153_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug111153_Test.java
index 4566386..fb64112 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug111153_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug111153_Test.java
@@ -63,7 +63,7 @@ public final class Bug111153_Test extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTransport t = (XTransport) UnoRuntime.queryInterface(
+            XTransport t = UnoRuntime.queryInterface(
                 XTransport.class, getBridge(context).getInstance("Transport"));
             XDerived d = new XDerived() {};
             t.setDerived(d);
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug51323_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug51323_Test.java
index 0a674c8..265027b 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug51323_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug51323_Test.java
@@ -67,7 +67,7 @@ public final class Bug51323_Test extends ComplexTestCase {
         protected boolean run(XComponentContext context) throws Throwable {
             XConnection connection =
                 Connector.create(context).connect(getConnectionDescription());
-            XBridgeFactory factory = (XBridgeFactory) UnoRuntime.queryInterface(
+            XBridgeFactory factory = UnoRuntime.queryInterface(
                 XBridgeFactory.class,
                 context.getServiceManager().createInstanceWithContext(
                     "com.sun.star.bridge.BridgeFactory", context));
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug92174_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug92174_Test.java
index cccc206..4855c34 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug92174_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug92174_Test.java
@@ -55,7 +55,7 @@ public final class Bug92174_Test extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTransport t = (XTransport) UnoRuntime.queryInterface(
+            XTransport t = UnoRuntime.queryInterface(
                 XTransport.class, getBridge(context).getInstance("Transport"));
             t.setDerived(new XDerived() {
                     public void fn() {}
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug97697_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug97697_Test.java
index d54e2e5..62c5b03 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug97697_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug97697_Test.java
@@ -72,7 +72,7 @@ public final class Bug97697_Test extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTransport transport = (XTransport) UnoRuntime.queryInterface(
+            XTransport transport = UnoRuntime.queryInterface(
                 XTransport.class, getBridge(context).getInstance("Transport"));
             try {
                 transport.getAny();
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug98508_Test.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug98508_Test.java
index 516e069..fe1b6cb 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug98508_Test.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/Bug98508_Test.java
@@ -76,7 +76,7 @@ public final class Bug98508_Test extends ComplexTestCase {
 
         protected boolean run(XComponentContext context) throws Throwable {
             Test98508Interface ifc
-                = (Test98508Interface) UnoRuntime.queryInterface(
+                = UnoRuntime.queryInterface(
                     Test98508Interface.class,
                     getBridge(context).getInstance(""));
             try {
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/MethodIdTest.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/MethodIdTest.java
index 3309096..ac146bd 100755
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/MethodIdTest.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/MethodIdTest.java
@@ -64,7 +64,7 @@ public final class MethodIdTest extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTest t = (XTest) UnoRuntime.queryInterface(
+            XTest t = UnoRuntime.queryInterface(
                 XTest.class, getBridge(context).getInstance("Test"));
             return t.f129() == 129;
         }
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/PolyStructTest.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/PolyStructTest.java
index 31d479a..1336706 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/PolyStructTest.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/PolyStructTest.java
@@ -61,7 +61,7 @@ public final class PolyStructTest extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            TestTransport t = (TestTransport) UnoRuntime.queryInterface(
+            TestTransport t = UnoRuntime.queryInterface(
                 TestTransport.class, getBridge(context).getInstance(""));
 
             assertEquals(
diff --git a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/StopMessageDispatcherTest.java b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/StopMessageDispatcherTest.java
index 8a3c67b..5edb1d9 100644
--- a/bridges/test/com/sun/star/lib/uno/bridges/java_remote/StopMessageDispatcherTest.java
+++ b/bridges/test/com/sun/star/lib/uno/bridges/java_remote/StopMessageDispatcherTest.java
@@ -63,7 +63,7 @@ public final class StopMessageDispatcherTest extends ComplexTestCase {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTest test = (XTest) UnoRuntime.queryInterface(
+            XTest test = UnoRuntime.queryInterface(
                 XTest.class, getBridge(context).getInstance("Test"));
             Thread[] threads = new Thread[101];
             int n = Thread.enumerate(threads);
diff --git a/bridges/test/java_uno/acquire/TestAcquire.java b/bridges/test/java_uno/acquire/TestAcquire.java
index da2eaaa..780a3ce 100644
--- a/bridges/test/java_uno/acquire/TestAcquire.java
+++ b/bridges/test/java_uno/acquire/TestAcquire.java
@@ -71,7 +71,7 @@ public final class TestAcquire {
     private static void execClient(XComponentContext context, String url)
         throws Exception
     {
-        XTest test = (XTest) UnoRuntime.queryInterface(
+        XTest test = UnoRuntime.queryInterface(
             XTest.class, UnoUrlResolver.create(context).resolve(url));
 
         WaitUnreachable u;
@@ -184,7 +184,7 @@ public final class TestAcquire {
         throws Exception
     {
         XAcceptor acceptor = Acceptor.create(context);
-        XBridgeFactory factory = (XBridgeFactory) UnoRuntime.queryInterface(
+        XBridgeFactory factory = UnoRuntime.queryInterface(
             XBridgeFactory.class,
             context.getServiceManager().createInstanceWithContext(
                 "com.sun.star.bridge.BridgeFactory", context));
diff --git a/bridges/test/java_uno/any/TestRemote.java b/bridges/test/java_uno/any/TestRemote.java
index bb059fd..3a7c773 100644
--- a/bridges/test/java_uno/any/TestRemote.java
+++ b/bridges/test/java_uno/any/TestRemote.java
@@ -49,7 +49,7 @@ public final class TestRemote {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTransport transport = (XTransport) UnoRuntime.queryInterface(
+            XTransport transport = UnoRuntime.queryInterface(
                 XTransport.class, getBridge(context).getInstance("Transport"));
             return TestAny.test(transport, true);
         }
diff --git a/bridges/test/java_uno/equals/TestEquals.java b/bridges/test/java_uno/equals/TestEquals.java
index 022e424..d1f2d0d 100644
--- a/bridges/test/java_uno/equals/TestEquals.java
+++ b/bridges/test/java_uno/equals/TestEquals.java
@@ -91,10 +91,10 @@ public final class TestEquals {
         }
 
         protected boolean run(XComponentContext context) throws Throwable {
-            XTestFrame f = (XTestFrame) UnoRuntime.queryInterface(
+            XTestFrame f = UnoRuntime.queryInterface(
                 XTestFrame.class, getBridge(context).getInstance("TestFrame"));
             XAcceptor acceptor = Acceptor.create(context);
-            XBridgeFactory factory = (XBridgeFactory) UnoRuntime.queryInterface(
+            XBridgeFactory factory = UnoRuntime.queryInterface(
                 XBridgeFactory.class,
                 context.getServiceManager().createInstanceWithContext(
                     "com.sun.star.bridge.BridgeFactory", context));
@@ -160,17 +160,15 @@ public final class TestEquals {
                             public void run() {
                                 try {
                                     Object test1Aa = object1;
-                                    XBase test1Ab = (XBase)
-                                        UnoRuntime.queryInterface(
-                                            XBase.class, test1Aa);
-                                    XDerived test1Ac = (XDerived)
+                                    XBase test1Ab = UnoRuntime.queryInterface(
+                                        XBase.class, test1Aa);
+                                    XDerived test1Ac =
                                         UnoRuntime.queryInterface(
                                             XDerived.class, test1Aa);
                                     Object test2Aa = object2;
-                                    XBase test2Ab = (XBase)
-                                        UnoRuntime.queryInterface(
-                                            XBase.class, test2Aa);
-                                    XDerived test2Ac = (XDerived)
+                                    XBase test2Ab = UnoRuntime.queryInterface(
+                                        XBase.class, test2Aa);
+                                    XDerived test2Ac =
                                         UnoRuntime.queryInterface(
                                             XDerived.class, test2Aa);
 
@@ -182,16 +180,14 @@ public final class TestEquals {
                                             null, params);
                                     XMultiComponentFactory factory
                                         = context.getServiceManager();
-                                    XImplementationLoader loader
-                                        = (XImplementationLoader)
+                                    XImplementationLoader loader =
                                         UnoRuntime.queryInterface(
                                             XImplementationLoader.class,
                                             factory.createInstanceWithContext(
                                                 "com.sun.star.loader."
                                                 + "SharedLibrary",
                                                 context));
-                                    XSingleComponentFactory factory2
-                                        = (XSingleComponentFactory)
+                                    XSingleComponentFactory factory2 =
                                         UnoRuntime.queryInterface(
                                             XSingleComponentFactory.class,
                                             loader.activate(
@@ -199,7 +195,7 @@ public final class TestEquals {
                                                 + "testequals.impl",
                                                 "", "../lib/testequals.uno",
                                                 null));
-                                    XTestInterface test = (XTestInterface)
+                                    XTestInterface test =
                                         UnoRuntime.queryInterface(
                                             XTestInterface.class,
                                             factory2.createInstanceWithContext(
@@ -211,17 +207,15 @@ public final class TestEquals {
                                         PROTOCOL_DESCRIPTION);
 
                                     Object test1Ba = test.get(INSTANCE1);
-                                    XBase test1Bb = (XBase)
-                                        UnoRuntime.queryInterface(
-                                            XBase.class, test1Ba);
-                                    XDerived test1Bc = (XDerived)
+                                    XBase test1Bb = UnoRuntime.queryInterface(
+                                        XBase.class, test1Ba);
+                                    XDerived test1Bc =
                                         UnoRuntime.queryInterface(
                                             XDerived.class, test1Ba);
                                     Object test2Ba = test.get(INSTANCE2);
-                                    XBase test2Bb = (XBase)
-                                        UnoRuntime.queryInterface(
-                                            XBase.class, test2Ba);
-                                    XDerived test2Bc = (XDerived)
+                                    XBase test2Bb = UnoRuntime.queryInterface(
+                                        XBase.class, test2Ba);
+                                    XDerived test2Bc =
                                         UnoRuntime.queryInterface(
                                             XDerived.class, test2Ba);
 
diff --git a/bridges/test/java_uno/nativethreadpool/Relay.java b/bridges/test/java_uno/nativethreadpool/Relay.java
index 576ca2d..f291c22 100644
--- a/bridges/test/java_uno/nativethreadpool/Relay.java
+++ b/bridges/test/java_uno/nativethreadpool/Relay.java
@@ -63,7 +63,7 @@ public final class Relay implements XRelay, XSource {
         final XAcceptor acceptor = Acceptor.create(context);
         final XBridgeFactory factory;
         try {
-            factory = (XBridgeFactory) UnoRuntime.queryInterface(
+            factory = UnoRuntime.queryInterface(
                 XBridgeFactory.class,
                 context.getServiceManager().createInstanceWithContext(
                     "com.sun.star.bridge.BridgeFactory", context));
diff --git a/bridges/test/testclient.java b/bridges/test/testclient.java
index 7ff477c..989b6b8 100644
--- a/bridges/test/testclient.java
+++ b/bridges/test/testclient.java
@@ -121,7 +121,7 @@ public class testclient
 
                 
                 XConnector xConnector =
-                    ( XConnector ) UnoRuntime.queryInterface( XConnector.class , x );
+                    UnoRuntime.queryInterface( XConnector.class , x );
                 
                 XConnection xConnection = xConnector.connect(args[0]);
             
@@ -138,7 +138,7 @@ public class testclient
                     
                     System.out.println( "after building bridge" );
 //  				Object rInitialObject = m_bridge.mapInterfaceFrom(rootOid, XInterface.class);
-//  				XTestFactory rFactory = (XTestFactory )
+//  				XTestFactory rFactory =
 //  					UnoRuntime.queryInterface(XTestFactory.class,rInitialObject );
                     
 //  				XCallMe callMerFactory->
diff --git a/cpputools/source/regcomplazy/regcomplazy.cxx b/cpputools/source/regcomplazy/regcomplazy.cxx
index a607f4f..6c6940e 100755
--- a/cpputools/source/regcomplazy/regcomplazy.cxx
+++ b/cpputools/source/regcomplazy/regcomplazy.cxx
@@ -131,6 +131,8 @@ SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv)
                 sBuffer.append(pBuffer, readSize);
             }            
         }
+    fclose(fDescr);
+    fDescr = 0; // just to be sure noone tries to use the file ever after
     }
     
     OString sDescr = sBuffer.makeStringAndClear();
diff --git a/javaunohelper/com/sun/star/comp/helper/Bootstrap.java b/javaunohelper/com/sun/star/comp/helper/Bootstrap.java
index a640e81..4c30cbb 100644
--- a/javaunohelper/com/sun/star/comp/helper/Bootstrap.java
+++ b/javaunohelper/com/sun/star/comp/helper/Bootstrap.java
@@ -67,7 +67,7 @@ import java.util.Random;
     Other services can be inserted into the service manager by
     using its XSet interface:
     <pre>
-        XSet xSet = (XSet)UnoRuntime.queryInterface( XSet.class, aMultiComponentFactory );
+        XSet xSet = UnoRuntime.queryInterface( XSet.class, aMultiComponentFactory );
         // insert the service manager
         xSet.insert( aSingleComponentFactory );
     </pre>
@@ -108,20 +108,20 @@ public class Bootstrap {
     static public XComponentContext createInitialComponentContext( Hashtable context_entries )
         throws Exception
     {
-        XImplementationLoader xImpLoader = (XImplementationLoader)UnoRuntime.queryInterface(
+        XImplementationLoader xImpLoader = UnoRuntime.queryInterface(
             XImplementationLoader.class, new JavaLoader() );
         
         // Get the factory of the ServiceManager
-        XSingleComponentFactory smgr_fac = (XSingleComponentFactory)UnoRuntime.queryInterface(
+        XSingleComponentFactory smgr_fac = UnoRuntime.queryInterface(
             XSingleComponentFactory.class, xImpLoader.activate(
                 "com.sun.star.comp.servicemanager.ServiceManager", null, null, null ) );
         
         // Create an instance of the ServiceManager
-        XMultiComponentFactory xSMgr = (XMultiComponentFactory)UnoRuntime.queryInterface(
+        XMultiComponentFactory xSMgr = UnoRuntime.queryInterface(
             XMultiComponentFactory.class, smgr_fac.createInstanceWithContext( null ) );
         
         // post init loader
-        XInitialization xInit = (XInitialization)UnoRuntime.queryInterface(
+        XInitialization xInit = UnoRuntime.queryInterface(
             XInitialization.class, xImpLoader );
         Object[] args = new Object [] { xSMgr };
         xInit.initialize( args );
@@ -137,12 +137,12 @@ public class Bootstrap {
         XComponentContext xContext = new ComponentContext( context_entries, null );
         
         // post init smgr
-        xInit = (XInitialization)UnoRuntime.queryInterface(
+        xInit = UnoRuntime.queryInterface(
             XInitialization.class, xSMgr );
         args = new Object [] { null, xContext }; // no registry, default context
         xInit.initialize( args );
         
-        XSet xSet = (XSet)UnoRuntime.queryInterface( XSet.class, xSMgr );
+        XSet xSet = UnoRuntime.queryInterface( XSet.class, xSMgr );
         // insert the service manager
         xSet.insert( smgr_fac );
         // and basic jurt factories
@@ -159,7 +159,7 @@ public class Bootstrap {
      */
     static public XMultiServiceFactory createSimpleServiceManager() throws Exception
     {
-        return (XMultiServiceFactory)UnoRuntime.queryInterface(
+        return UnoRuntime.queryInterface(
             XMultiServiceFactory.class, createInitialComponentContext( null ).getServiceManager() );
     }
     
@@ -206,7 +206,7 @@ public class Bootstrap {
             NativeLibraryLoader.loadLibrary( Bootstrap.class.getClassLoader(), "juh" );
             m_loaded_juh = true;
         }
-        return (XComponentContext)UnoRuntime.queryInterface(
+        return UnoRuntime.queryInterface(
             XComponentContext.class,
             cppuhelper_bootstrap(
                 ini_file, pairs, Bootstrap.class.getClassLoader() ) );
@@ -283,7 +283,7 @@ public class Bootstrap {
                 try {
                     // try to connect to office
                     Object context = xUrlResolver.resolve( sConnect );
-                    xContext = (XComponentContext) UnoRuntime.queryInterface(
+                    xContext = UnoRuntime.queryInterface(
                         XComponentContext.class, context);
                     if ( xContext == null )
                         throw new BootstrapException( "no component context!" );
diff --git a/javaunohelper/com/sun/star/comp/helper/ComponentContext.java b/javaunohelper/com/sun/star/comp/helper/ComponentContext.java
index 13bc4ce..7c1ce45 100644
--- a/javaunohelper/com/sun/star/comp/helper/ComponentContext.java
+++ b/javaunohelper/com/sun/star/comp/helper/ComponentContext.java
@@ -101,7 +101,7 @@ public class ComponentContext implements XComponentContext, XComponent
             {
                 o = ((ComponentContextEntry)o).m_value;
             }
-            m_xSMgr = (XMultiComponentFactory)UnoRuntime.queryInterface(
+            m_xSMgr = UnoRuntime.queryInterface(
                 XMultiComponentFactory.class, o );
         }
         if (m_xSMgr != null)
@@ -114,7 +114,7 @@ public class ComponentContext implements XComponentContext, XComponent
         }
         
         // listen for delegate
-        XComponent xComp = (XComponent)UnoRuntime.queryInterface(
+        XComponent xComp = UnoRuntime.queryInterface(
             XComponent.class, m_xDelegate );
         if (xComp != null)
         {
@@ -154,7 +154,7 @@ public class ComponentContext implements XComponentContext, XComponent
                         else
                         {
                             XSingleComponentFactory xCompFac =
-                                (XSingleComponentFactory)UnoRuntime.queryInterface(
+                                UnoRuntime.queryInterface(
                                     XSingleComponentFactory.class, entry.m_lateInit );
                             if (xCompFac != null)
                             {
@@ -185,7 +185,7 @@ public class ComponentContext implements XComponentContext, XComponent
                             else // inited in the meantime
                             {
                                 // dispose fresh service instance
-                                XComponent xComp = (XComponent)UnoRuntime.queryInterface(
+                                XComponent xComp = UnoRuntime.queryInterface(
                                     XComponent.class, xInstance );
                                 if (xComp != null)
                                 {
@@ -253,7 +253,7 @@ public class ComponentContext implements XComponentContext, XComponent
                     o = ((ComponentContextEntry)o).m_value;
                 }
                 
-                XComponent xComp = (XComponent)UnoRuntime.queryInterface( XComponent.class, o );
+                XComponent xComp = UnoRuntime.queryInterface( XComponent.class, o );
                 if (xComp != null)
                 {
                     if (name.equals( TDMGR_NAME ))
@@ -272,7 +272,7 @@ public class ComponentContext implements XComponentContext, XComponent
         // smgr
         if (m_bDisposeSMgr)
         {
-            XComponent xComp = (XComponent)UnoRuntime.queryInterface(
+            XComponent xComp = UnoRuntime.queryInterface(
                 XComponent.class, m_xSMgr );
             if (xComp != null)
             {
diff --git a/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java b/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java
index 65973be..e2187d8 100644
--- a/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java
+++ b/javaunohelper/com/sun/star/comp/helper/RegistryServiceFactory.java
@@ -124,7 +124,7 @@ public class RegistryServiceFactory {
         Object obj = createRegistryServiceFactory(
             writeRegistryFile, readRegistryFile, readOnly,
             RegistryServiceFactory.class.getClassLoader() );
-        return (XMultiServiceFactory) UnoRuntime.queryInterface(
+        return UnoRuntime.queryInterface(
             XMultiServiceFactory.class, obj );	
     }
 
diff --git a/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java b/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java
index c132ca4..8cfa52b 100644
--- a/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java
+++ b/javaunohelper/com/sun/star/comp/helper/SharedLibraryLoader.java
@@ -85,7 +85,7 @@ public class SharedLibraryLoader {
                 XMultiServiceFactory smgr, 
                 XRegistryKey regKey )
     {
-        return (XSingleServiceFactory) UnoRuntime.queryInterface(
+        return UnoRuntime.queryInterface(
                     XSingleServiceFactory.class, 
                     component_getFactory(
                         DEFAULT_LIBRARY, DEFAULT_IMPLEMENTATION, smgr, regKey,
@@ -110,7 +110,7 @@ public class SharedLibraryLoader {
                 XMultiServiceFactory smgr, 
                 XRegistryKey regKey )
     {
-        return (XSingleServiceFactory) UnoRuntime.queryInterface(
+        return UnoRuntime.queryInterface(
                     XSingleServiceFactory.class, 
                     component_getFactory(
                         libName, impName, smgr, regKey,
diff --git a/javaunohelper/com/sun/star/comp/juhtest/SmoketestCommandEnvironment.java b/javaunohelper/com/sun/star/comp/juhtest/SmoketestCommandEnvironment.java
index a4da541..7cffca6 100644
--- a/javaunohelper/com/sun/star/comp/juhtest/SmoketestCommandEnvironment.java
+++ b/javaunohelper/com/sun/star/comp/juhtest/SmoketestCommandEnvironment.java
@@ -119,7 +119,6 @@ class InteractionImpl implements com.sun.star.task.XInteractionHandler
             if (approve)
             {
                 com.sun.star.task.XInteractionApprove xApprove =
-                    (com.sun.star.task.XInteractionApprove)
                     UnoRuntime.queryInterface(com.sun.star.task.XInteractionApprove.class, conts[i]);
                 if (xApprove != null)
                     xApprove.select();
@@ -129,7 +128,6 @@ class InteractionImpl implements com.sun.star.task.XInteractionHandler
             else if (abort)
             {
                 com.sun.star.task.XInteractionAbort xAbort =
-                    (com.sun.star.task.XInteractionAbort)
                     UnoRuntime.queryInterface(com.sun.star.task.XInteractionAbort.class, conts[i]);
                 if (xAbort != null)
                     xAbort.select();
diff --git a/javaunohelper/com/sun/star/lib/uno/helper/Factory.java b/javaunohelper/com/sun/star/lib/uno/helper/Factory.java
index 6925046..8f2cd60 100644
--- a/javaunohelper/com/sun/star/lib/uno/helper/Factory.java
+++ b/javaunohelper/com/sun/star/lib/uno/helper/Factory.java
@@ -210,7 +210,7 @@ public class Factory
         throws com.sun.star.uno.Exception
     {
         Object inst = instantiate( xContext );
-        XInitialization xInit = (XInitialization)UnoRuntime.queryInterface(
+        XInitialization xInit = UnoRuntime.queryInterface(
             XInitialization.class, inst );
         if (null == xInit)
         {
diff --git a/javaunohelper/com/sun/star/lib/uno/helper/InterfaceContainer.java b/javaunohelper/com/sun/star/lib/uno/helper/InterfaceContainer.java
index 59a109e..2c23ebc 100644
--- a/javaunohelper/com/sun/star/lib/uno/helper/InterfaceContainer.java
+++ b/javaunohelper/com/sun/star/lib/uno/helper/InterfaceContainer.java
@@ -715,7 +715,7 @@ public class InterfaceContainer implements Cloneable
                 try
                 {
                     Object o= aIt.next();
-                    XEventListener evtListener= (XEventListener) UnoRuntime.queryInterface(
+                    XEventListener evtListener= UnoRuntime.queryInterface(
                     XEventListener.class, o);
                     if( evtListener != null )
                         evtListener.disposing( evt );
diff --git a/javaunohelper/com/sun/star/lib/uno/helper/PropertySet.java b/javaunohelper/com/sun/star/lib/uno/helper/PropertySet.java
index edd37e4..bbf144e 100644
--- a/javaunohelper/com/sun/star/lib/uno/helper/PropertySet.java
+++ b/javaunohelper/com/sun/star/lib/uno/helper/PropertySet.java
@@ -671,7 +671,7 @@ XMultiPropertySet
                             // We try to get an XInterface of setVal and set an XInterface type.
                             if (setVal instanceof XInterface)   
                             {
-                                XInterface xint= (XInterface) UnoRuntime.queryInterface(XInterface.class, setVal);
+                                XInterface xint= UnoRuntime.queryInterface(XInterface.class, setVal);
                                 if (xint != null)
                                     convObj= new Any(new Type(XInterface.class), xint);
                             }
diff --git a/javaunohelper/com/sun/star/lib/uno/helper/PropertySetMixin.java b/javaunohelper/com/sun/star/lib/uno/helper/PropertySetMixin.java
index a8b0eb2..70615b6 100644
--- a/javaunohelper/com/sun/star/lib/uno/helper/PropertySetMixin.java
+++ b/javaunohelper/com/sun/star/lib/uno/helper/PropertySetMixin.java
@@ -143,13 +143,13 @@ public final class PropertySetMixin {
         idlClass = getReflection(type.getTypeName());
         XTypeDescription ifc;
         try {
-            ifc = (XTypeDescription) UnoRuntime.queryInterface(
+            ifc = UnoRuntime.queryInterface(
                 XTypeDescription.class,
-                (((XHierarchicalNameAccess) UnoRuntime.queryInterface(
-                      XHierarchicalNameAccess.class,
-                      context.getValueByName(
-                          "/singletons/com.sun.star.reflection."
-                          + "theTypeDescriptionManager"))).
+                (UnoRuntime.queryInterface(
+                    XHierarchicalNameAccess.class,
+                    context.getValueByName(
+                        "/singletons/com.sun.star.reflection."
+                        + "theTypeDescriptionManager")).
                  getByHierarchicalName(type.getTypeName())));
         } catch (NoSuchElementException e) {
             throw new RuntimeException(
@@ -585,7 +585,7 @@ public final class PropertySetMixin {
     private XIdlClass getReflection(String typeName) {
         XIdlReflection refl;
         try {
-            refl = (XIdlReflection) UnoRuntime.queryInterface(
+            refl = UnoRuntime.queryInterface(
                 XIdlReflection.class,
                 context.getServiceManager().createInstanceWithContext(
                     "com.sun.star.reflection.CoreReflection", context));
@@ -599,8 +599,7 @@ public final class PropertySetMixin {
         try {
             return refl.forName(typeName);
         } finally {
-            XComponent comp = (XComponent) UnoRuntime.queryInterface(
-                XComponent.class, refl);
+            XComponent comp = UnoRuntime.queryInterface(XComponent.class, refl);
             if (comp != null) {
                 comp.dispose();
             }
@@ -610,9 +609,8 @@ public final class PropertySetMixin {
     private void initProperties(
         XTypeDescription type, HashMap map, ArrayList handleNames, HashSet seen)
     {
-        XInterfaceTypeDescription2 ifc = (XInterfaceTypeDescription2)
-            UnoRuntime.queryInterface(
-                XInterfaceTypeDescription2.class, resolveTypedefs(type));
+        XInterfaceTypeDescription2 ifc = UnoRuntime.queryInterface(
+            XInterfaceTypeDescription2.class, resolveTypedefs(type));
         if (seen.add(ifc.getName())) {
             XTypeDescription[] bases = ifc.getBaseTypes();
             for (int i = 0; i < bases.length; ++i) {
@@ -622,11 +620,10 @@ public final class PropertySetMixin {
             for (int i = 0; i < members.length; ++i) {
                 if (members[i].getTypeClass() == TypeClass.INTERFACE_ATTRIBUTE)
                 {
-                    XInterfaceAttributeTypeDescription2 attr
-                        = ((XInterfaceAttributeTypeDescription2)
-                           UnoRuntime.queryInterface(
-                               XInterfaceAttributeTypeDescription2.class,
-                               members[i]));
+                    XInterfaceAttributeTypeDescription2 attr =
+                        UnoRuntime.queryInterface(
+                            XInterfaceAttributeTypeDescription2.class,
+                            members[i]);
                     short attrAttribs = 0;
                     if (attr.isBound()) {
                         attrAttribs |= PropertyAttribute.BOUND;
@@ -685,7 +682,7 @@ public final class PropertySetMixin {
                             break;
                         }
                         attrAttribs |= n;
-                        t = ((XStructTypeDescription) UnoRuntime.queryInterface(
+                        t = (UnoRuntime.queryInterface(
                                  XStructTypeDescription.class, t)).
                             getTypeArguments()[0];
                     }
@@ -747,14 +744,14 @@ public final class PropertySetMixin {
                 object, illegalArgumentPosition);
 
         }
-        XIdlField2 f = (XIdlField2) UnoRuntime.queryInterface(
+        XIdlField2 f = UnoRuntime.queryInterface(
             XIdlField2.class, idlClass.getField(name));
         Object[] o = new Object[] {
                 new Any(type, UnoRuntime.queryInterface(type, object)) };
         Object v = wrapValue(
             value,
-            ((XIdlField2) UnoRuntime.queryInterface(
-                XIdlField2.class, idlClass.getField(name))).getType(),
+            UnoRuntime.queryInterface(
+                XIdlField2.class, idlClass.getField(name)).getType(),
             (p.property.Attributes & PropertyAttribute.MAYBEAMBIGUOUS) != 0,
             isAmbiguous,
             (p.property.Attributes & PropertyAttribute.MAYBEDEFAULT) != 0,
@@ -807,7 +804,7 @@ public final class PropertySetMixin {
         if (p == null) {
             throw new UnknownPropertyException(name, object);
         }
-        XIdlField2 field = (XIdlField2) UnoRuntime.queryInterface(
+        XIdlField2 field = UnoRuntime.queryInterface(
             XIdlField2.class, idlClass.getField(name));
         Object value;
         try {
@@ -848,12 +845,12 @@ public final class PropertySetMixin {
                 XIdlClass ambiguous = getReflection(typeName);
                 try {
                     isAmbiguous = AnyConverter.toBoolean(
-                        ((XIdlField2) UnoRuntime.queryInterface(
+                        UnoRuntime.queryInterface(
                             XIdlField2.class,
-                            ambiguous.getField("IsAmbiguous"))).get(value));
-                    value = ((XIdlField2) UnoRuntime.queryInterface(
-                                 XIdlField2.class,
-                                 ambiguous.getField("Value"))).get(value);
+                            ambiguous.getField("IsAmbiguous")).get(value));
+                    value = UnoRuntime.queryInterface(
+                        XIdlField2.class,
+                        ambiguous.getField("Value")).get(value);
                 } catch (com.sun.star.lang.IllegalArgumentException e) {
                     throw new RuntimeException(
                         "unexpected"
@@ -867,12 +864,12 @@ public final class PropertySetMixin {
                 XIdlClass defaulted = getReflection(typeName);
                 try {
                     isDefaulted = AnyConverter.toBoolean(
-                        ((XIdlField2) UnoRuntime.queryInterface(
+                        UnoRuntime.queryInterface(
                             XIdlField2.class,
-                            defaulted.getField("IsDefaulted"))).get(value));
-                    value = ((XIdlField2) UnoRuntime.queryInterface(
-                                 XIdlField2.class,
-                                 defaulted.getField("Value"))).get(value);
+                            defaulted.getField("IsDefaulted")).get(value));
+                    value = UnoRuntime.queryInterface(
+                        XIdlField2.class,
+                        defaulted.getField("Value")).get(value);
                 } catch (com.sun.star.lang.IllegalArgumentException e) {
                     throw new RuntimeException(
                         "unexpected"
@@ -886,16 +883,16 @@ public final class PropertySetMixin {
                 XIdlClass optional = getReflection(typeName);
                 try {
                     boolean present = AnyConverter.toBoolean(
-                        ((XIdlField2) UnoRuntime.queryInterface(
+                        UnoRuntime.queryInterface(
                             XIdlField2.class,
-                            optional.getField("IsPresent"))).get(value));
+                            optional.getField("IsPresent")).get(value));
                     if (!present) {
                         value = Any.VOID;
                         break;
                     }
-                    value = ((XIdlField2) UnoRuntime.queryInterface(
-                                 XIdlField2.class,
-                                 optional.getField("Value"))).get(value);
+                    value = UnoRuntime.queryInterface(
+                        XIdlField2.class,
+                        optional.getField("Value")).get(value);
                 } catch (com.sun.star.lang.IllegalArgumentException e) {
                     throw new RuntimeException(
                         "unexpected"
@@ -932,15 +929,15 @@ public final class PropertySetMixin {
             Object[] strct = new Object[1];
             type.createObject(strct);
             try {
-                XIdlField2 field = (XIdlField2) UnoRuntime.queryInterface(
+                XIdlField2 field = UnoRuntime.queryInterface(
                     XIdlField2.class, type.getField("Value"));
                 field.set(
                     strct,
                     wrapValue(
                         value, field.getType(), false, false, wrapDefaulted,
                         isDefaulted, wrapOptional));
-                ((XIdlField2) UnoRuntime.queryInterface(
-                    XIdlField2.class, type.getField("IsAmbiguous"))).set(
+                UnoRuntime.queryInterface(
+                    XIdlField2.class, type.getField("IsAmbiguous")).set(
                         strct, new Boolean(isAmbiguous));
             } catch (com.sun.star.lang.IllegalArgumentException e) {
                 throw new RuntimeException(
@@ -959,15 +956,15 @@ public final class PropertySetMixin {
             Object[] strct = new Object[1];
             type.createObject(strct);
             try {
-                XIdlField2 field = (XIdlField2) UnoRuntime.queryInterface(
+                XIdlField2 field = UnoRuntime.queryInterface(
                     XIdlField2.class, type.getField("Value"));
                 field.set(
                     strct,
                     wrapValue(
                         value, field.getType(), wrapAmbiguous, isAmbiguous,
                         false, false, wrapOptional));
-                ((XIdlField2) UnoRuntime.queryInterface(
-                    XIdlField2.class, type.getField("IsDefaulted"))).set(
+                UnoRuntime.queryInterface(
+                    XIdlField2.class, type.getField("IsDefaulted")).set(
                         strct, new Boolean(isDefaulted));
             } catch (com.sun.star.lang.IllegalArgumentException e) {
                 throw new RuntimeException(
@@ -986,11 +983,11 @@ public final class PropertySetMixin {
             type.createObject(strct);
             boolean present = !AnyConverter.isVoid(value);
             try {
-                ((XIdlField2) UnoRuntime.queryInterface(
-                    XIdlField2.class, type.getField("IsPresent"))).set(
+                UnoRuntime.queryInterface(
+                    XIdlField2.class, type.getField("IsPresent")).set(
                         strct, new Boolean(present));
                 if (present) {
-                    XIdlField2 field = (XIdlField2) UnoRuntime.queryInterface(
+                    XIdlField2 field = UnoRuntime.queryInterface(
                         XIdlField2.class, type.getField("Value"));
                     field.set(
                         strct,
@@ -1018,9 +1015,8 @@ public final class PropertySetMixin {
 
     private static XTypeDescription resolveTypedefs(XTypeDescription type) {
         while (type.getTypeClass() == TypeClass.TYPEDEF) {
-            type = ((XIndirectTypeDescription) UnoRuntime.queryInterface(
-                        XIndirectTypeDescription.class, type)).
-                getReferencedType();
+            type = UnoRuntime.queryInterface(
+                XIndirectTypeDescription.class, type).getReferencedType();
         }
         return type;
     }
diff --git a/javaunohelper/test/com/sun/star/comp/helper/Bootstrap_Test.java b/javaunohelper/test/com/sun/star/comp/helper/Bootstrap_Test.java
index a0aedfa..05b123d 100644
--- a/javaunohelper/test/com/sun/star/comp/helper/Bootstrap_Test.java
+++ b/javaunohelper/test/com/sun/star/comp/helper/Bootstrap_Test.java
@@ -62,7 +62,7 @@ public class Bootstrap_Test {
                     "no /singletons/com.sun.star.reflection.theTypeDescriptionManager!" );
             }
             
-            XMultiServiceFactory msf = (XMultiServiceFactory)UnoRuntime.queryInterface(
+            XMultiServiceFactory msf = UnoRuntime.queryInterface(
                 XMultiServiceFactory.class, xContext.getServiceManager() );
             String services[] = msf.getAvailableServiceNames();
             System.out.println("Available services are:");
@@ -74,7 +74,7 @@ public class Bootstrap_Test {
                 for ( int i=0; i<services.length; i++ )
                     System.out.println(services[i]);
 
-            XComponent xComp = (XComponent)UnoRuntime.queryInterface(
+            XComponent xComp = UnoRuntime.queryInterface(
                 XComponent.class, xContext );
             xComp.dispose();
             
diff --git a/javaunohelper/test/com/sun/star/comp/helper/ComponentContext_Test.java b/javaunohelper/test/com/sun/star/comp/helper/ComponentContext_Test.java
index 1ac41a1..84c02ba 100644
--- a/javaunohelper/test/com/sun/star/comp/helper/ComponentContext_Test.java
+++ b/javaunohelper/test/com/sun/star/comp/helper/ComponentContext_Test.java
@@ -88,7 +88,7 @@ public class ComponentContext_Test {
                 System.err.println( "### bootstrap context test failed: 2!" );
             }
             
-            XComponent xComp = (XComponent)UnoRuntime.queryInterface(
+            XComponent xComp = UnoRuntime.queryInterface(
                 XComponent.class, xInitialContext );
             xComp.dispose();
         }
diff --git a/javaunohelper/test/com/sun/star/comp/helper/SharedLibraryLoader_Test.java b/javaunohelper/test/com/sun/star/comp/helper/SharedLibraryLoader_Test.java
index 14e2d35..ee876e5 100644
--- a/javaunohelper/test/com/sun/star/comp/helper/SharedLibraryLoader_Test.java
+++ b/javaunohelper/test/com/sun/star/comp/helper/SharedLibraryLoader_Test.java
@@ -91,7 +91,7 @@ public class SharedLibraryLoader_Test {
             if ( ! test_getSharedLibraryLoaderFactory() )
                 return false;
         
-        sharedLibraryLoader = (XImplementationLoader) UnoRuntime.queryInterface( 
+        sharedLibraryLoader = UnoRuntime.queryInterface( 
                 XImplementationLoader.class, sharedLibraryLoaderFactory.createInstance() );
         
         System.out.print("Test - ");
@@ -115,11 +115,11 @@ public class SharedLibraryLoader_Test {
         
         System.err.println("- get the native ServiceManger factory");
         XSingleServiceFactory aSMgrFac = 
-            (XSingleServiceFactory) UnoRuntime.queryInterface( XSingleServiceFactory.class, 
+            UnoRuntime.queryInterface( XSingleServiceFactory.class, 
                         sharedLibraryLoader.activate(NATIVE_SERVICE_MANAGER_IMP_NAME, null, NATIVE_SERVICE_MANAGER_LIB_NAME, null));
         
         System.err.println("- instantiate the native ServiceManger");
-        nativeServiceManager =  (XMultiServiceFactory) UnoRuntime.queryInterface( XMultiServiceFactory.class, aSMgrFac.createInstance() );
+        nativeServiceManager = UnoRuntime.queryInterface( XMultiServiceFactory.class, aSMgrFac.createInstance() );
         
         System.out.print("Test - ");
         System.out.println(nativeServiceManager == null? "failed" : "successfull");
@@ -141,12 +141,12 @@ public class SharedLibraryLoader_Test {
 
         System.err.println("- get factory of the Registry");
         XSingleServiceFactory aRegFac = 
-            (XSingleServiceFactory) UnoRuntime.queryInterface( XSingleServiceFactory.class, 
+            UnoRuntime.queryInterface( XSingleServiceFactory.class, 
                         sharedLibraryLoader.activate(NATIVE_REGISTRY_IMP_NAME, null, NATIVE_REGISTRY_LIB_NAME, null)
             );
         System.err.println("- instantiate the Registry");
         simpleRegistry = 
-            (XSimpleRegistry) UnoRuntime.queryInterface( XSimpleRegistry.class, aRegFac.createInstance() );
+            UnoRuntime.queryInterface( XSimpleRegistry.class, aRegFac.createInstance() );
         System.out.print("Test - ");
         System.out.println(simpleRegistry == null? "failed" : "successfull");
         System.out.println("*******************************************************************");
diff --git a/javaunohelper/test/com/sun/star/lib/uno/helper/ComponentBase_Test.java b/javaunohelper/test/com/sun/star/lib/uno/helper/ComponentBase_Test.java
index 9b4c502..3ece246 100644
--- a/javaunohelper/test/com/sun/star/lib/uno/helper/ComponentBase_Test.java
+++ b/javaunohelper/test/com/sun/star/lib/uno/helper/ComponentBase_Test.java
@@ -67,9 +67,9 @@ public class ComponentBase_Test
         comp.addEventListener(obj1);
         comp.addEventListener(obj2);
         comp.addEventListener(obj3);
-        comp.addEventListener((XEventListener) UnoRuntime.queryInterface(XEventListener.class, proxyObj1Weak1));
-        comp.addEventListener((XEventListener) UnoRuntime.queryInterface(XEventListener.class, proxyObj3Weak2));
-        comp.addEventListener((XEventListener) UnoRuntime.queryInterface(XEventListener.class, proxyObj3TypeProv));
+        comp.addEventListener(UnoRuntime.queryInterface(XEventListener.class, proxyObj1Weak1));
+        comp.addEventListener(UnoRuntime.queryInterface(XEventListener.class, proxyObj3Weak2));
+        comp.addEventListener(UnoRuntime.queryInterface(XEventListener.class, proxyObj3TypeProv));
         obj1.nDisposingCalled = 0;
         obj2.nDisposingCalled = 0;
         obj3.nDisposingCalled = 0;
diff --git a/javaunohelper/test/com/sun/star/lib/uno/helper/Factory_Test.java b/javaunohelper/test/com/sun/star/lib/uno/helper/Factory_Test.java
index e3eda37..14f66b3 100644
--- a/javaunohelper/test/com/sun/star/lib/uno/helper/Factory_Test.java
+++ b/javaunohelper/test/com/sun/star/lib/uno/helper/Factory_Test.java
@@ -120,7 +120,7 @@ public class Factory_Test
     //==============================================================================================
     static void service_info_test( Object inst )
     {
-        XServiceInfo xInfo = (XServiceInfo)UnoRuntime.queryInterface( XServiceInfo.class, inst );
+        XServiceInfo xInfo = UnoRuntime.queryInterface( XServiceInfo.class, inst );
         
         if (! xInfo.getImplementationName().equals( m_impl_name ))
         {
@@ -159,7 +159,7 @@ public class Factory_Test
         
             // bootstrap service manager
             XMultiServiceFactory xMgr = RegistryServiceFactory.create( rdb );
-            XPropertySet xProps = (XPropertySet)UnoRuntime.queryInterface(
+            XPropertySet xProps = UnoRuntime.queryInterface(
                 XPropertySet.class, xMgr );
             XComponentContext xContext = (XComponentContext)AnyConverter.toObject(
                 new Type( XComponentContext.class ), xProps.getPropertyValue( "DefaultContext" ) );
@@ -172,7 +172,7 @@ public class Factory_Test
                 new Type( XSimpleRegistry.class ), xProps.getPropertyValue( "Registry" ) );
             // register impl
             XImplementationRegistration xImpReg =
-                (XImplementationRegistration)UnoRuntime.queryInterface(
+                UnoRuntime.queryInterface(
                     XImplementationRegistration.class,
                     xContext.getServiceManager().createInstanceWithContext(
                         "com.sun.star.registry.ImplementationRegistration", xContext ) );
@@ -196,7 +196,7 @@ public class Factory_Test
                         m_supported_services[ nPos ], xContext ) );
             }
 
-            XComponent xComp = (XComponent)UnoRuntime.queryInterface( XComponent.class, xContext );
+            XComponent xComp = UnoRuntime.queryInterface( XComponent.class, xContext );
             xComp.dispose();
         }
         catch (Exception exc)
diff --git a/jurt/com/sun/star/comp/bridgefactory/BridgeFactory.java b/jurt/com/sun/star/comp/bridgefactory/BridgeFactory.java
index 4b312ce..4b86c7e 100644
--- a/jurt/com/sun/star/comp/bridgefactory/BridgeFactory.java
+++ b/jurt/com/sun/star/comp/bridgefactory/BridgeFactory.java
@@ -134,7 +134,7 @@ public class BridgeFactory implements XBridgeFactory/*, XEventListener*/ {
         if (hasName) {
             IBridge iBridges[] = UnoRuntime.getBridges();
             for(int i = 0; i < iBridges.length; ++ i) {
-                XBridge xBridge = (XBridge)UnoRuntime.queryInterface(XBridge.class, iBridges[i]);
+                XBridge xBridge = UnoRuntime.queryInterface(XBridge.class, iBridges[i]);
 
                 if(xBridge != null) {
                     if(xBridge.getName().equals(sName))
@@ -148,7 +148,7 @@ public class BridgeFactory implements XBridgeFactory/*, XEventListener*/ {
         try {
             IBridge iBridge = UnoRuntime.getBridgeByName("java", context, "remote", context, hasName ? new Object[]{sProtocol, aConnection, anInstanceProvider, sName} : new Object[]{sProtocol, aConnection, anInstanceProvider});
 
-            xBridge = (XBridge)UnoRuntime.queryInterface(XBridge.class, iBridge);
+            xBridge = UnoRuntime.queryInterface(XBridge.class, iBridge);
         }
         catch(Exception exception) {
             throw new com.sun.star.lang.IllegalArgumentException(exception.getMessage());
@@ -171,7 +171,7 @@ public class BridgeFactory implements XBridgeFactory/*, XEventListener*/ {
 
         IBridge iBridges[] = UnoRuntime.getBridges();
         for(int i = 0; i < iBridges.length; ++ i) {
-            xBridge = (XBridge)UnoRuntime.queryInterface(XBridge.class, iBridges[i]);
+            xBridge = UnoRuntime.queryInterface(XBridge.class, iBridges[i]);
 
             if(xBridge != null) {
                 if(xBridge.getName().equals(sName))
@@ -199,7 +199,7 @@ public class BridgeFactory implements XBridgeFactory/*, XEventListener*/ {
 
         IBridge iBridges[] = UnoRuntime.getBridges();
         for(int i = 0; i < iBridges.length; ++ i) {
-            XBridge xBridge = (XBridge)UnoRuntime.queryInterface(XBridge.class, iBridges[i]);
+            XBridge xBridge = UnoRuntime.queryInterface(XBridge.class, iBridges[i]);
 
             if(xBridge != null)
                 vector.addElement(xBridge);
diff --git a/jurt/com/sun/star/comp/loader/FactoryHelper.java b/jurt/com/sun/star/comp/loader/FactoryHelper.java
index bf164ae..a0aa001 100644
--- a/jurt/com/sun/star/comp/loader/FactoryHelper.java
+++ b/jurt/com/sun/star/comp/loader/FactoryHelper.java
@@ -174,7 +174,7 @@ public class FactoryHelper {
         {
             if (xContext != null)
             {
-                return (XMultiServiceFactory)UnoRuntime.queryInterface(
+                return UnoRuntime.queryInterface(
                     XMultiServiceFactory.class, xContext.getServiceManager() );
             }
             else
@@ -302,7 +302,7 @@ public class FactoryHelper {
                 Object instance = _constructor.newInstance( args );
                 if (bInitCall)
                 {
-                    XInitialization xInitialization = (XInitialization)UnoRuntime.queryInterface(
+                    XInitialization xInitialization = UnoRuntime.queryInterface(
                         XInitialization.class, instance );
                     if (xInitialization != null)
                     {
diff --git a/jurt/com/sun/star/comp/loader/JavaLoader.java b/jurt/com/sun/star/comp/loader/JavaLoader.java
index 3f20e8e..af15029 100644
--- a/jurt/com/sun/star/comp/loader/JavaLoader.java
+++ b/jurt/com/sun/star/comp/loader/JavaLoader.java
@@ -102,7 +102,7 @@ public class JavaLoader implements XImplementationLoader,
             {
                 if (m_xMacroExpander == null)
                 {
-                    XPropertySet xProps = (XPropertySet)
+                    XPropertySet xProps =
                         UnoRuntime.queryInterface(
                             XPropertySet.class, multiServiceFactory );
                     if (xProps == null)
diff --git a/jurt/com/sun/star/comp/servicemanager/ServiceManager.java b/jurt/com/sun/star/comp/servicemanager/ServiceManager.java
index 1ebc0c3..42ba36a 100644
--- a/jurt/com/sun/star/comp/servicemanager/ServiceManager.java
+++ b/jurt/com/sun/star/comp/servicemanager/ServiceManager.java
@@ -158,7 +158,7 @@ public class ServiceManager implements XMultiServiceFactory,
         if (loaderObj == null)
             throw new com.sun.star.uno.Exception("Can get an instance of com.sun.star.loader.Java");
             
-        return (XImplementationLoader) UnoRuntime.queryInterface( XImplementationLoader.class, loaderObj );
+        return UnoRuntime.queryInterface( XImplementationLoader.class, loaderObj );
     }
 
     /**
@@ -380,7 +380,7 @@ public class ServiceManager implements XMultiServiceFactory,
         Object fac = queryServiceFactory( rServiceSpecifier );
         if (fac != null)
         {
-            XSingleComponentFactory xCompFac = (XSingleComponentFactory)UnoRuntime.queryInterface(
+            XSingleComponentFactory xCompFac = UnoRuntime.queryInterface(
                 XSingleComponentFactory.class, fac );
             if (xCompFac != null)
             {
@@ -388,7 +388,7 @@ public class ServiceManager implements XMultiServiceFactory,
             }
             else
             {
-                XSingleServiceFactory xServiceFac = (XSingleServiceFactory)UnoRuntime.queryInterface(
+                XSingleServiceFactory xServiceFac = UnoRuntime.queryInterface(
                     XSingleServiceFactory.class, fac );
                 if (xServiceFac != null)
                 {
@@ -422,7 +422,7 @@ public class ServiceManager implements XMultiServiceFactory,
         Object fac = queryServiceFactory( rServiceSpecifier );
         if (fac != null)
         {
-            XSingleComponentFactory xCompFac = (XSingleComponentFactory)UnoRuntime.queryInterface(
+            XSingleComponentFactory xCompFac = UnoRuntime.queryInterface(
                 XSingleComponentFactory.class, fac );
             if (xCompFac != null)
             {
@@ -430,7 +430,7 @@ public class ServiceManager implements XMultiServiceFactory,
             }
             else
             {
-                XSingleServiceFactory xServiceFac = (XSingleServiceFactory)UnoRuntime.queryInterface(
+                XSingleServiceFactory xServiceFac = UnoRuntime.queryInterface(
                     XSingleServiceFactory.class, fac );
                 if (xServiceFac != null)
                 {
@@ -528,7 +528,7 @@ public class ServiceManager implements XMultiServiceFactory,
             if (object == null) 
                 throw new com.sun.star.uno.RuntimeException("The parameter must not been null");
             
-            XServiceInfo xServiceInfo = (XServiceInfo) UnoRuntime.queryInterface(XServiceInfo.class, object);
+            XServiceInfo xServiceInfo = UnoRuntime.queryInterface(XServiceInfo.class, object);
             
             if (xServiceInfo != null) {
                 return UnoRuntime.areSame(factoriesByImplNames.get(xServiceInfo.getImplementationName()), object);
@@ -552,7 +552,7 @@ public class ServiceManager implements XMultiServiceFactory,
         if (object == null) throw new com.sun.star.lang.IllegalArgumentException();
         
         XServiceInfo xServiceInfo = 
-                (XServiceInfo) UnoRuntime.queryInterface(XServiceInfo.class, object);
+                UnoRuntime.queryInterface(XServiceInfo.class, object);
         
         if (xServiceInfo == null) 
             throw new com.sun.star.lang.IllegalArgumentException(
@@ -606,7 +606,7 @@ public class ServiceManager implements XMultiServiceFactory,
             );
         
         XServiceInfo xServiceInfo = 
-            (XServiceInfo) UnoRuntime.queryInterface(XServiceInfo.class, object);
+            UnoRuntime.queryInterface(XServiceInfo.class, object);
         
         if (xServiceInfo == null)
             throw new com.sun.star.lang.IllegalArgumentException(
@@ -614,7 +614,7 @@ public class ServiceManager implements XMultiServiceFactory,
             );
         
         XSingleServiceFactory xSingleServiceFactory = 
-            (XSingleServiceFactory) UnoRuntime.queryInterface(XSingleServiceFactory.class, object);
+            UnoRuntime.queryInterface(XSingleServiceFactory.class, object);
         
         if (xSingleServiceFactory == null) 
             throw new com.sun.star.lang.IllegalArgumentException(
diff --git a/jurt/com/sun/star/comp/urlresolver/UrlResolver.java b/jurt/com/sun/star/comp/urlresolver/UrlResolver.java
index 8a9635d..82d5e52 100644
--- a/jurt/com/sun/star/comp/urlresolver/UrlResolver.java
+++ b/jurt/com/sun/star/comp/urlresolver/UrlResolver.java
@@ -102,7 +102,7 @@ public class UrlResolver {
             Object rootObject = null;
             XBridgeFactory xBridgeFactory= null;
             try {
-                xBridgeFactory = (XBridgeFactory)UnoRuntime.queryInterface(XBridgeFactory.class, 
+                xBridgeFactory = UnoRuntime.queryInterface(XBridgeFactory.class, 
                                                                           _xMultiServiceFactory.createInstance("com.sun.star.bridge.BridgeFactory"));
             } catch (com.sun.star.uno.Exception e) {
                 throw new com.sun.star.uno.RuntimeException(e.getMessage());
@@ -117,7 +117,7 @@ public class UrlResolver {
                         throw new com.sun.star.uno.RuntimeException(e.getMessage());
                 }
                 
-                XConnector connector_xConnector = (XConnector)UnoRuntime.queryInterface(XConnector.class, connector);
+                XConnector connector_xConnector = UnoRuntime.queryInterface(XConnector.class, connector);
                 
                 // connect to the server
                 XConnection xConnection = connector_xConnector.connect(conDcp);
diff --git a/jurt/com/sun/star/uno/WeakReference.java b/jurt/com/sun/star/uno/WeakReference.java
index a06cbc3..f8be0cd 100644
--- a/jurt/com/sun/star/uno/WeakReference.java
+++ b/jurt/com/sun/star/uno/WeakReference.java
@@ -61,7 +61,7 @@ public class WeakReference
             Object weakImpl= obj.get();
             if (weakImpl != null)
             {
-                XWeak weak= (XWeak) UnoRuntime.queryInterface(XWeak.class, weakImpl);
+                XWeak weak= UnoRuntime.queryInterface(XWeak.class, weakImpl);
                 if (weak != null)
                 {
                     XAdapter adapter= (XAdapter) weak.queryAdapter();
@@ -77,7 +77,7 @@ public class WeakReference
      */
     public WeakReference(Object obj)
     {
-        XWeak weak= (XWeak) UnoRuntime.queryInterface(XWeak.class, obj);
+        XWeak weak= UnoRuntime.queryInterface(XWeak.class, obj);
         if (weak != null)
         {
             XAdapter adapter= (XAdapter) weak.queryAdapter();
diff --git a/jurt/demo/com/sun/star/demo/DemoServer.java b/jurt/demo/com/sun/star/demo/DemoServer.java
index 49afc8c..c39d86c 100644
--- a/jurt/demo/com/sun/star/demo/DemoServer.java
+++ b/jurt/demo/com/sun/star/demo/DemoServer.java
@@ -92,12 +92,12 @@ public class DemoServer {
         ServiceManager serviceManager = new ServiceManager();
         serviceManager.addFactories(neededServices);
 
-        XAcceptor xAcceptor = (XAcceptor)UnoRuntime.queryInterface(XAcceptor.class, serviceManager.createInstance("com.sun.star.connection.Acceptor"));
+        XAcceptor xAcceptor = UnoRuntime.queryInterface(XAcceptor.class, serviceManager.createInstance("com.sun.star.connection.Acceptor"));
 
         System.err.println("waiting for connect...");
         XConnection xConnection = xAcceptor.accept(conDcp);
 
-        XBridgeFactory xBridgeFactory = (XBridgeFactory)UnoRuntime.queryInterface(XBridgeFactory.class, serviceManager.createInstance("com.sun.star.bridge.BridgeFactory"));
+        XBridgeFactory xBridgeFactory = UnoRuntime.queryInterface(XBridgeFactory.class, serviceManager.createInstance("com.sun.star.bridge.BridgeFactory"));
         XBridge xBridge = xBridgeFactory.createBridge(conDcp + ";" + protDcp, protDcp, xConnection, new InstanceProvider());
 
     }
diff --git a/jurt/demo/com/sun/star/demo/TestOffice.java b/jurt/demo/com/sun/star/demo/TestOffice.java
index d8f46ee..4a74bf4 100644
--- a/jurt/demo/com/sun/star/demo/TestOffice.java
+++ b/jurt/demo/com/sun/star/demo/TestOffice.java
@@ -76,7 +76,7 @@ public class TestOffice {
         {
             byte bytes[][] = new byte[1][];
 
-            XInputStream rIn = (XInputStream)UnoRuntime.queryInterface(XInputStream.class, rOut);
+            XInputStream rIn = UnoRuntime.queryInterface(XInputStream.class, rOut);
             if(rIn.available() != 10)
                 System.err.println("wrong bytes available\n");
 
@@ -90,11 +90,11 @@ public class TestOffice {
 
 
     static void testWriter(XComponent rCmp) throws IOException {
-        XTextDocument rTextDoc = (XTextDocument)UnoRuntime.queryInterface(XTextDocument.class, rCmp);
+        XTextDocument rTextDoc = UnoRuntime.queryInterface(XTextDocument.class, rCmp);
 
-        XText rText = (XText)UnoRuntime.queryInterface(XText.class, rTextDoc.getText());
-        XTextCursor rCursor = (XTextCursor)UnoRuntime.queryInterface(XTextCursor.class, rText.createTextCursor());
-        XTextRange rRange = (XTextRange)UnoRuntime.queryInterface(XTextRange.class, rCursor);
+        XText rText = UnoRuntime.queryInterface(XText.class, rTextDoc.getText());
+        XTextCursor rCursor = UnoRuntime.queryInterface(XTextCursor.class, rText.createTextCursor());
+        XTextRange rRange = UnoRuntime.queryInterface(XTextRange.class, rCursor);
 
         byte pcText[] = new byte[1024];
         pcText[0] = 0;
@@ -112,7 +112,7 @@ public class TestOffice {
     }
 
     static void testDocument(XMultiServiceFactory rSmgr) throws com.sun.star.uno.Exception, IOException {
-        XComponentLoader rLoader = (XComponentLoader)UnoRuntime.queryInterface(XComponentLoader.class, rSmgr.createInstance("com.sun.star.frame.Desktop"));
+        XComponentLoader rLoader = UnoRuntime.queryInterface(XComponentLoader.class, rSmgr.createInstance("com.sun.star.frame.Desktop"));
 
         String urls[] = new String[] {
             "private:factory/swriter",
@@ -148,13 +148,13 @@ public class TestOffice {
     }
 
     static void doSomething(Object r) throws com.sun.star.uno.Exception, IOException {
-        XNamingService rName = (XNamingService)UnoRuntime.queryInterface(XNamingService.class, r);
+        XNamingService rName = UnoRuntime.queryInterface(XNamingService.class, r);
 
         if(rName != null) {
             System.err.println("got the remote naming service !");
             Object rXsmgr = rName.getRegisteredObject("StarOffice.ServiceManager");
             
-            XMultiServiceFactory rSmgr = (XMultiServiceFactory)UnoRuntime.queryInterface(XMultiServiceFactory.class, rXsmgr);
+            XMultiServiceFactory rSmgr = UnoRuntime.queryInterface(XMultiServiceFactory.class, rXsmgr);
             if(rSmgr != null) {
                 System.err.println("got the remote service manager !");
 //  				testPipe(rSmgr);
@@ -183,7 +183,7 @@ public class TestOffice {
         smgr.addFactories(neededServices);
 
         Object  resolver  = smgr.createInstance("com.sun.star.bridge.UnoUrlResolver" );
-        XUnoUrlResolver resolver_xUnoUrlResolver = (XUnoUrlResolver)UnoRuntime.queryInterface(XUnoUrlResolver.class, resolver);
+        XUnoUrlResolver resolver_xUnoUrlResolver = UnoRuntime.queryInterface(XUnoUrlResolver.class, resolver);
 
           Object rInitialObject = resolver_xUnoUrlResolver.resolve(argv[0]);
 
diff --git a/jurt/test/com/sun/star/comp/bridgefactory/BridgeFactory_Test.java b/jurt/test/com/sun/star/comp/bridgefactory/BridgeFactory_Test.java
index f2c8b87..404ba71 100644
--- a/jurt/test/com/sun/star/comp/bridgefactory/BridgeFactory_Test.java
+++ b/jurt/test/com/sun/star/comp/bridgefactory/BridgeFactory_Test.java
@@ -75,7 +75,7 @@ public final class BridgeFactory_Test extends ComplexTestCase {
         assure("", UnoRuntime.areSame(xBridge, xBridges[0]));
 
         // dispose the bridge
-        XComponent xComponent = (XComponent)UnoRuntime.queryInterface(XComponent.class, xBridge);
+        XComponent xComponent = UnoRuntime.queryInterface(XComponent.class, xBridge);
         xComponent.dispose();
 
 
@@ -103,7 +103,7 @@ public final class BridgeFactory_Test extends ComplexTestCase {
                && UnoRuntime.areSame(xBridge_new, xBridges[0]));
 
         // dispose the new bridge
-        XComponent xComponent_new = (XComponent)UnoRuntime.queryInterface(XComponent.class, xBridge_new);
+        XComponent xComponent_new = UnoRuntime.queryInterface(XComponent.class, xBridge_new);
         xComponent_new.dispose();
     }
 }
diff --git a/jurt/test/com/sun/star/lib/uno/bridges/java_remote/java_remote_bridge_Test.java b/jurt/test/com/sun/star/lib/uno/bridges/java_remote/java_remote_bridge_Test.java
index 86fdc07..7a12742 100644
--- a/jurt/test/com/sun/star/lib/uno/bridges/java_remote/java_remote_bridge_Test.java
+++ b/jurt/test/com/sun/star/lib/uno/bridges/java_remote/java_remote_bridge_Test.java
@@ -132,17 +132,17 @@ public final class java_remote_bridge_Test extends ComplexTestCase {
             proxyBXInterface[i] = (XInterface) bridgeB.getInstance(name);
 
             // map object:
-            proxyBTestInterface[i] = (TestInterface) UnoRuntime.queryInterface(
+            proxyBTestInterface[i] = UnoRuntime.queryInterface(
                 TestInterface.class, proxyBXInterface[i]);
             proxyBTestInterface[i].function();
 
             // remap object once:
-            TestInterface remapped = (TestInterface) UnoRuntime.queryInterface(
+            TestInterface remapped = UnoRuntime.queryInterface(
                 TestInterface.class, proxyBXInterface[i]);
             remapped.function();
 
             // remap object twice:
-            remapped = (TestInterface) UnoRuntime.queryInterface(
+            remapped = UnoRuntime.queryInterface(
                 TestInterface.class, proxyBXInterface[i]);
             remapped.function();
         }
diff --git a/jurt/workbench/com/sun/star/comp/urlresolver/UrlResolver_Test.java b/jurt/workbench/com/sun/star/comp/urlresolver/UrlResolver_Test.java
index 1269dc8..6511913 100644
--- a/jurt/workbench/com/sun/star/comp/urlresolver/UrlResolver_Test.java
+++ b/jurt/workbench/com/sun/star/comp/urlresolver/UrlResolver_Test.java
@@ -58,19 +58,19 @@ public class UrlResolver_Test
             Object initialObject = urlResolver.resolve(
                 "uno:socket,host=localhost,port=8100;urp;StarOffice.ServiceManager" );
 
-            XMultiComponentFactory  xOfficeFactory= (XMultiComponentFactory) UnoRuntime.queryInterface(
+            XMultiComponentFactory  xOfficeFactory= UnoRuntime.queryInterface(
                 XMultiComponentFactory.class, initialObject );
 
             // retrieve the component context (it's not yet exported from the office)
             // Query for the XPropertySet interface.
-            XPropertySet xProperySet = ( XPropertySet ) UnoRuntime.queryInterface(
+            XPropertySet xProperySet = UnoRuntime.queryInterface(
                 XPropertySet.class, xOfficeFactory);
 
             // Get the default context from the office server.
             Object oDefaultContext = xProperySet.getPropertyValue( "DefaultContext" );
 
             // Query for the interface XComponentContext.
-            XComponentContext xOfficeComponentContext = ( XComponentContext ) UnoRuntime.queryInterface(
+            XComponentContext xOfficeComponentContext = UnoRuntime.queryInterface(
                 XComponentContext.class, oDefaultContext );
 
             // now create the desktop service
diff --git a/ridljar/com/sun/star/uno/UnoRuntime.java b/ridljar/com/sun/star/uno/UnoRuntime.java
index ab2cc98..cbee8e3 100644
--- a/ridljar/com/sun/star/uno/UnoRuntime.java
+++ b/ridljar/com/sun/star/uno/UnoRuntime.java
@@ -179,8 +179,9 @@ public class UnoRuntime {
      * otherwise <code>null</code>
      * @see #queryInterface(Type, Object)
      */
-    public static Object queryInterface(Class zInterface, Object object) {
-        return queryInterface(new Type(zInterface), object);
+    @SuppressWarnings("unchecked")
+    public static <T> T queryInterface(Class<T> zInterface, Object object) {
+        return (T) queryInterface(new Type(zInterface), object);
     }
 
     /**
diff --git a/ridljar/test/com/sun/star/uno/UnoRuntime_Test.java b/ridljar/test/com/sun/star/uno/UnoRuntime_Test.java
index 0a5c7af..12f3d12 100644
--- a/ridljar/test/com/sun/star/uno/UnoRuntime_Test.java
+++ b/ridljar/test/com/sun/star/uno/UnoRuntime_Test.java
@@ -54,7 +54,7 @@ public final class UnoRuntime_Test extends ComplexTestCase {
 
         // Test if a delegator object has the same OID as its creator:
         Test4 test4 = new Test4();
-        Ifc ifc = (Ifc) UnoRuntime.queryInterface(Ifc.class, test4);
+        Ifc ifc = UnoRuntime.queryInterface(Ifc.class, test4);
         assure(
             "Test4",
             UnoRuntime.generateOid(test4).equals(UnoRuntime.generateOid(ifc)));
@@ -64,19 +64,19 @@ public final class UnoRuntime_Test extends ComplexTestCase {
         // Test if a query for an interface which is not supported returns null:
         assure(
             "Test1",
-            (Ifc) UnoRuntime.queryInterface(Ifc.class, new Test1()) == null);
+            UnoRuntime.queryInterface(Ifc.class, new Test1()) == null);
 
         // Test if a query for an interface which is supported through
         // IQueryInterface succeeds:
         assure(
             "Test2",
-            (Ifc) UnoRuntime.queryInterface(Ifc.class, new Test2()) != null);
+            UnoRuntime.queryInterface(Ifc.class, new Test2()) != null);
 
         // Test if a query for an interface which is directly supported (through
         // inheritance) succeeds:
         assure(
             "Test3",
-            (Ifc) UnoRuntime.queryInterface(Ifc.class, new Test3()) != null);
+            UnoRuntime.queryInterface(Ifc.class, new Test3()) != null);
     }
 
     public void test_areSame() {
diff --git a/sal/osl/unx/process.c b/sal/osl/unx/process.c
index 2eaea19..946103a 100644
--- a/sal/osl/unx/process.c
+++ b/sal/osl/unx/process.c
@@ -466,7 +466,7 @@ static void ChildStatusProc(void *pData)
     if ((pid = fork()) == 0)
     {
         /* Child */
-        close(channel[0]);
+        if (channel[0] != -1) close(channel[0]);
 
         if ((data.m_uid != (uid_t)-1) && ((data.m_uid != getuid()) || (data.m_gid != getgid())))
         {
@@ -500,32 +500,32 @@ static void ChildStatusProc(void *pData)
             /* Connect std IO to pipe ends */
 
             /* Write end of stdInput not used in child process */
-            close( stdInput[1] );
+            if (stdInput[1] != -1) close( stdInput[1] );
 
             /* Read end of stdOutput not used in child process */
-            close( stdOutput[0] );
+            if (stdOutput[0] != -1) close( stdOutput[0] );
 
             /* Read end of stdError not used in child process */
-            close( stdError[0] );
+            if (stdError[0] != -1) close( stdError[0] );
 
             /* Redirect pipe ends to std IO */
 
             if ( stdInput[0] != STDIN_FILENO )
             {
                 dup2( stdInput[0], STDIN_FILENO );
-                close( stdInput[0] );
+                if (stdInput[0] != -1) close( stdInput[0] );
             }
 
             if ( stdOutput[1] != STDOUT_FILENO )
             {
                 dup2( stdOutput[1], STDOUT_FILENO );
-                close( stdOutput[1] );
+                if (stdOutput[1] != -1) close( stdOutput[1] );
             }
 
             if ( stdError[1] != STDERR_FILENO )
             {
                 dup2( stdError[1], STDERR_FILENO );
-                close( stdError[1] );
+                if (stdError[1] != -1) close( stdError[1] );
             }
 
             pid=execv(data.m_pszArgs[0], (sal_Char **)data.m_pszArgs);
@@ -539,7 +539,7 @@ static void ChildStatusProc(void *pData)
         /* if we reach here, something went wrong */
         write(channel[1], &errno, sizeof(errno));
 
-        close(channel[1]);
+        if (channel[1] != -1) close(channel[1]);
 
         _exit(255);
     }
@@ -547,12 +547,12 @@ static void ChildStatusProc(void *pData)
     {   /* Parent  */
         int   status;
 
-        close(channel[1]);
+        if (channel[1] != -1) close(channel[1]);
 
         /* Close unused pipe ends */
-        close( stdInput[0] );
-        close( stdOutput[1] );
-        close( stdError[1] );
+        if (stdInput[0] != -1) close( stdInput[0] );
+        if (stdOutput[1] != -1) close( stdOutput[1] );
+        if (stdError[1] != -1) close( stdError[1] );
 
         while (((i = read(channel[0], &status, sizeof(status))) < 0))
         {
@@ -560,7 +560,7 @@ static void ChildStatusProc(void *pData)
                 break;
         }
 
-        close(channel[0]);
+        if (channel[0] != -1) close(channel[0]);
 
 
         if ((pid > 0) && (i == 0))
@@ -646,9 +646,9 @@ static void ChildStatusProc(void *pData)
             if ( pdata->m_pErrorRead )
                 *pdata->m_pErrorRead = NULL;
 
-            close( stdInput[1] );
-            close( stdOutput[0] );
-            close( stdError[0] );
+            if (stdInput[1] != -1) close( stdInput[1] );
+            if (stdOutput[0] != -1) close( stdOutput[0] );
+            if (stdError[0] != -1) close( stdError[0] );
 
             //if pid > 0 then a process was created, even if it later failed
             //e.g. bash searching for a command to execute, and we still
@@ -1124,15 +1124,6 @@ struct osl_procStat
     unsigned long nswap;      /* ? */
     unsigned long cnswap;     /* ? */
 
-    /* from 'statm' */
-    long size;                /* numbers of pages in memory */
-    long resident;            /* number of resident pages */
-    long share;               /* number of shared pages */
-    long trs;                 /* text resident size */
-    long lrs;                 /* library resident size */
-    long drs;                 /* data resident size */
-    long dt;                  /* ditry pages */
-
     /* from 'status' */
     int ruid;                 /* real uid */
     int euid;                 /* effective uid */
@@ -1155,9 +1146,10 @@ struct osl_procStat
  osl_getProcStat
  *********************************************/
  
-void osl_getProcStat(pid_t pid, struct osl_procStat* procstat)
+sal_Bool osl_getProcStat(pid_t pid, struct osl_procStat* procstat)
 {
     int fd = 0;
+    sal_Bool bRet = sal_False;
     char name[PATH_MAX + 1];
     snprintf(name, sizeof(name), "/proc/%u/stat", pid);
 
@@ -1166,11 +1158,13 @@ void osl_getProcStat(pid_t pid, struct osl_procStat* procstat)
         char* tmp=0;
         char prstatbuf[512];
         memset(prstatbuf,0,512);
-        read(fd,prstatbuf,511);
+        bRet = read(fd,prstatbuf,511) == 511;
 
         close(fd);
         /*printf("%s\n\n",prstatbuf);*/
 
+        if (!bRet)
+            return sal_False;
 
         tmp = strrchr(prstatbuf, ')');
         *tmp = '\0';
@@ -1198,57 +1192,35 @@ void osl_getProcStat(pid_t pid, struct osl_procStat* procstat)
                &procstat->wchan,     &procstat->nswap,   &procstat->cnswap
             );
     }
-}
-
-/**********************************************
- osl_getProcStatm
- *********************************************/
- 
-void osl_getProcStatm(pid_t pid, struct osl_procStat* procstat)
-{
-    int fd = 0;
-    char name[PATH_MAX + 1];
-    snprintf(name, sizeof(name), "/proc/%u/statm", pid);
-
-    if ((fd = open(name,O_RDONLY)) >=0 )
-    {
-        char prstatmbuf[512];
-        memset(prstatmbuf,0,512);
-        read(fd,prstatmbuf,511);
-
-        close(fd);
-
-        /*		printf("\n\n%s\n\n",prstatmbuf);*/
-
-        sscanf(prstatmbuf,"%li %li %li %li %li %li %li",
-               &procstat->size, &procstat->resident, &procstat->share,
-               &procstat->trs,  &procstat->lrs,      &procstat->drs,
-               &procstat->dt
-            );
-    }
+    return bRet;
 }
 
 /**********************************************
  osl_getProcStatus
  *********************************************/
  
-void osl_getProcStatus(pid_t pid, struct osl_procStat* procstat)
+sal_Bool osl_getProcStatus(pid_t pid, struct osl_procStat* procstat)
 {
     int fd = 0;
     char name[PATH_MAX + 1];
     snprintf(name, sizeof(name), "/proc/%u/status", pid);
 
+    sal_Bool bRet = sal_False;
+
     if ((fd = open(name,O_RDONLY)) >=0 )
     {
         char* tmp=0;
         char prstatusbuf[512];
         memset(prstatusbuf,0,512);
-        read(fd,prstatusbuf,511);
+        bRet = read(fd,prstatusbuf,511) == 511;
 
         close(fd);
 
         /*		printf("\n\n%s\n\n",prstatusbuf);*/
 
+        if (!bRet)
+            return sal_False;
+
         tmp = strstr(prstatusbuf,"Uid:");
         if(tmp)
         {
@@ -1290,6 +1262,7 @@ void osl_getProcStatus(pid_t pid, struct osl_procStat* procstat)
                 );
         }
     }
+    return bRet;
 }
 
 #endif
@@ -1439,56 +1412,54 @@ oslProcessError SAL_CALL osl_getProcessInfo(oslProcess Process, oslProcessData F
 
 #elif defined(LINUX)
 
-/*		int fd = 0;*/
-        struct osl_procStat procstat;
-        memset(&procstat,0,sizeof(procstat));
-
-        osl_getProcStat(pid, &procstat);
-        osl_getProcStatm(pid, &procstat);
-        osl_getProcStatus(pid, &procstat);
-
-        if ( Fields & osl_Process_CPUTIMES)
+        if ( (Fields & osl_Process_CPUTIMES) || (Fields & osl_Process_HEAPUSAGE) )
         {
-            /*
-             *  mfe:
-             *  We calculate only time of the process proper.
-             *  Threads are processes, we do not consider their time here!
-             *  (For this, cutime and cstime should be used, it seems not
-             *   to work in 2.0.36)
-             */
-
-            long clktck;
-            unsigned long hz;
-            unsigned long userseconds;
-            unsigned long systemseconds;
-
-            clktck = sysconf(_SC_CLK_TCK);
-            if (clktck < 0) {
-                return osl_Process_E_Unknown;
-            }
-            hz = (unsigned long) clktck;
+            struct osl_procStat procstat;
+            memset(&procstat,0,sizeof(procstat));
+
+            if ( (Fields & osl_Process_CPUTIMES) && osl_getProcStat(pid, &procstat) )
+            {
+                /*
+                 *  mfe:
+                 *  We calculate only time of the process proper.
+                 *  Threads are processes, we do not consider their time here!
+                 *  (For this, cutime and cstime should be used, it seems not
+                 *   to work in 2.0.36)
+                 */
+
+                long clktck;
+                unsigned long hz;
+                unsigned long userseconds;
+                unsigned long systemseconds;
+
+                clktck = sysconf(_SC_CLK_TCK);
+                if (clktck < 0) {
+                    return osl_Process_E_Unknown;
+                }
+                hz = (unsigned long) clktck;
 
-            userseconds = procstat.utime/hz;
-            systemseconds = procstat.stime/hz;
+                userseconds = procstat.utime/hz;
+                systemseconds = procstat.stime/hz;
 
-            pInfo->UserTime.Seconds   = userseconds;
-            pInfo->UserTime.Nanosec   = procstat.utime - (userseconds * hz);
-            pInfo->SystemTime.Seconds = systemseconds;
-            pInfo->SystemTime.Nanosec = procstat.stime - (systemseconds * hz);
+                 pInfo->UserTime.Seconds   = userseconds;
+                pInfo->UserTime.Nanosec   = procstat.utime - (userseconds * hz);
+                pInfo->SystemTime.Seconds = systemseconds;
+                pInfo->SystemTime.Nanosec = procstat.stime - (systemseconds * hz);
+    
+                pInfo->Fields |= osl_Process_CPUTIMES;
+            }
 
-            pInfo->Fields |= osl_Process_CPUTIMES;
-        }
+            if ( (Fields & osl_Process_HEAPUSAGE) && osl_getProcStatus(pid, &procstat) )
+            {
+                /*
+                 *  mfe:
+                 *  vm_data (found in status) shows the size of the data segment
+                 *  it a rough approximation of the core heap size
+                 */
+                pInfo->HeapUsage = procstat.vm_data*1024;
 
-        if (Fields & osl_Process_HEAPUSAGE)
-        {
-            /*
-             *  mfe:
-             *  vm_data (found in status) shows the size of the data segment
-             *  it a rough approximation of the core heap size
-             */
-            pInfo->HeapUsage = procstat.vm_data*1024;
-
-            pInfo->Fields |= osl_Process_HEAPUSAGE;
+                pInfo->Fields |= osl_Process_HEAPUSAGE;
+            }
         }
 
         return (pInfo->Fields == Fields) ? osl_Process_E_None : osl_Process_E_Unknown;
diff --git a/sal/osl/unx/signal.c b/sal/osl/unx/signal.c
index 4b7dd6b..38d509f 100644
--- a/sal/osl/unx/signal.c
+++ b/sal/osl/unx/signal.c
@@ -46,6 +46,7 @@
 
 #ifdef LINUX
 #include <execinfo.h>
+#include <link.h>
 #define INCLUDE_BACKTRACE
 #define STACKTYPE "Linux"
 #endif
@@ -392,6 +393,88 @@ static int fputs_xml( const char *string, FILE *stream )
 
 #define REPORTENV_PARAM		"-crashreportenv:"
 
+#if defined SAL_ENABLE_CRASH_REPORT && defined INCLUDE_BACKTRACE && \
+    defined LINUX
+
+typedef struct
+{
+    const char *name;
+    ElfW(Off) offset;
+} dynamic_entry;
+
+static int
+callback(struct dl_phdr_info *info, size_t size, void *data)
+{
+    const ElfW(Phdr) *pDynamic = NULL;
+
+    if (size == sizeof(struct dl_phdr_info))
+    {
+        int i;
+        for (i = 0; i < info->dlpi_phnum; ++i)
+        {
+            if (info->dlpi_phdr[i].p_type == PT_DYNAMIC)
+            {
+                pDynamic = &(info->dlpi_phdr[i]);
+                break;
+            }
+        }
+    }
+
+    if (pDynamic)
+    {
+        char buffer[100];
+        int len;
+        char exe[PATH_MAX];
+        const char *dsoname = info->dlpi_name;
+
+        dynamic_entry* entry = (dynamic_entry*)data;
+
+        if (strcmp(dsoname, "") == 0)
+        { 
+            snprintf(buffer, sizeof(buffer), "/proc/%d/exe", getpid());
+            if ((len = readlink(buffer, exe, PATH_MAX)) != -1)
+            {
+                exe[len] = '\0';
+                dsoname = exe;
+            }
+        }
+
+        if (strcmp(dsoname, entry->name) == 0)
+        {
+            entry->offset = pDynamic->p_offset;
+            return 1;
+        }
+    }
+    return 0;
+}
+
+/* Get the location of the .dynamic section offset for the given elf file.
+ * i.e. same as the "Offset" value shown for DYNAMIC from readelf -l foo 
+ *
+ * We want to know this value so that if the binaries have been modifed
+ * by prelink then we can still process the call stack on server side 
+ * by comparing this value to that of an "un-prelinked but known to be
+ * otherwise equivalent" version of those binaries and adjust the call 
+ * stack addresses by the differences between .dynamic addresses so as 
+ * to be able to map the prelinked addresses back to the unprelinked 
+ * addresses
+ *
+ * cmc at openoffice.org
+ */
+static ElfW(Off)
+dynamic_section_offset(const char *name)
+{
+    dynamic_entry entry;
+
+    entry.name = name;
+    entry.offset = 0;
+
+    dl_iterate_phdr(callback, &entry);
+
+    return entry.offset;
+}
+#endif
+
 static int ReportCrash( int Signal )
 {
 #ifdef SAL_ENABLE_CRASH_REPORT
@@ -572,6 +655,11 @@ static int ReportCrash( int Signal )
 
                             if ( dl_info.dli_fbase && dl_info.dli_fname )
                             {
+#ifdef LINUX
+                                ElfW(Off) dynamic_offset = dynamic_section_offset(dl_info.dli_fname);
+                                fprintf( stackout, " 0x%" SAL_PRI_SIZET "x:", dynamic_offset);
+#endif
+
                                 fprintf( stackout, " %s + 0x%" SAL_PRI_PTRDIFFT "x",
                                     dl_info.dli_fname,
                                     (char*)stackframes[iFrame] - (char*)dl_info.dli_fbase
@@ -583,6 +671,10 @@ static int ReportCrash( int Signal )
 
                                 if ( dli_fdir )
                                     fprintf( xmlout, " path=\"%s\"", dli_fdir );
+
+#ifdef LINUX
+                                fprintf( xmlout, " dynamicoffset=\"0x%" SAL_PRI_SIZET "x\"", dynamic_offset );
+#endif
                             }
                             else
                                 fprintf( stackout, " ????????" );
diff --git a/ure/source/uretest/JavaClient.java b/ure/source/uretest/JavaClient.java
index c7fb64e..3caadf8 100644
--- a/ure/source/uretest/JavaClient.java
+++ b/ure/source/uretest/JavaClient.java
@@ -50,7 +50,7 @@ public final class JavaClient {
         if (manager == null) {
             throw new NullPointerException("no service manager");
         }
-        XBridgeFactory factory = (XBridgeFactory) UnoRuntime.queryInterface(
+        XBridgeFactory factory = UnoRuntime.queryInterface(
             XBridgeFactory.class,
             manager.createInstanceWithContext(
                 "com.sun.star.bridge.BridgeFactory", context));
@@ -63,11 +63,9 @@ public final class JavaClient {
             Connector.create(context).connect(
                 url.getConnectionAndParametersAsString()),
             null);
-        Data d =
-            ((XServer) UnoRuntime.queryInterface(
-                XServer.class, bridge.getInstance(url.getRootOid()))).getData();
-        ((XComponent) UnoRuntime.queryInterface(XComponent.class, bridge)).
-            dispose();
+        Data d = UnoRuntime.queryInterface(
+            XServer.class, bridge.getInstance(url.getRootOid())).getData();
+        UnoRuntime.queryInterface(XComponent.class, bridge).dispose();
         if (!d.m1.equals("Hello") || d.m2 != 42) {
             throw new RuntimeException("Data object contains bad values");
         }
commit 268aee4a0457adbd76a62ac3da04d151552146fd
Author: Ivo Hinkelmann <ihi at openoffice.org>
Date:   Wed Sep 16 13:55:36 2009 +0000

    CWS-TOOLING: integrate CWS impressnotes01
    2009-09-11 13:52:41 +0200 cl  r276061 : CWS-TOOLING: rebase CWS impressnotes01 to trunk at 276043 (milestone: DEV300:m58)
    2009-09-10 15:44:57 +0200 cl  r276039 : #i103139# continued work on the impress annotation feature
    2009-09-10 14:52:31 +0200 cl  r276032 : #i103139# continued work on the impress annotation feature
    2009-09-10 14:50:32 +0200 cl  r276031 : #i103139# continued work on the impress annotation feature
    2009-09-10 14:48:29 +0200 cl  r276030 : #i103139# continued work on the impress annotation feature
    2009-09-10 11:36:11 +0200 cl  r276027 : #i103139# continued work on the impress annotation feature
    2009-09-09 20:22:41 +0200 cl  r276018 : #i103139# continued work on the impress annotation feature
    2009-09-09 20:21:45 +0200 cl  r276017 : #i103139# continued work on the impress annotation feature
    2009-09-09 19:32:29 +0200 sj  r276015 : #i103139# added import of comments (ppt binary)
    2009-09-09 19:31:07 +0200 sj  r276014 : #i103139# added import of comments (ppt binary)
    2009-09-09 19:16:41 +0200 cl  r276011 : #i103139# continued work on the impress annotation feature
    2009-09-09 19:15:19 +0200 cl  r276010 : #i103139# continued work on the impress annotation feature
    2009-09-09 16:27:19 +0200 cl  r276001 : #i104579# fixed isEmptyPresObj()
    2009-09-09 15:12:02 +0200 cl  r275997 : #i103139# continued work on the impress annotation feature
    2009-09-09 15:06:29 +0200 sj  r275996 : #i103139# added import of comments (ppt binary)
    2009-09-09 14:53:01 +0200 cl  r275995 : #i103139# continued work on the impress annotation feature
    2009-09-09 14:51:32 +0200 cl  r275994 : #i103139# continued work on the impress annotation feature
    2009-09-09 12:11:17 +0200 cl  r275982 : #i103139# continued work on the impress annotation feature
    2009-09-09 11:47:55 +0200 cl  r275981 : #i103139# continued work on the impress annotation feature
    2009-09-09 11:47:23 +0200 cl  r275980 : #i103139# continued work on the impress annotation feature
    2009-09-09 11:44:47 +0200 cl  r275978 : #i104315# added missing tab pages
    2009-09-08 16:04:44 +0200 cl  r275936 : #i103139# continued work on the impress annotation feature
    2009-09-08 16:03:28 +0200 cl  r275935 : #i103139# continued work on the impress annotation feature
    2009-09-08 11:45:47 +0200 cl  r275920 : #i103139# continued work on the impress annotation feature
    2009-09-08 11:41:51 +0200 cl  r275919 : #i103139# continued work on the impress annotation feature
    2009-09-07 18:30:55 +0200 cl  r275910 : #i103139# continued work on the impress annotation feature
    2009-09-07 18:29:37 +0200 cl  r275909 : #i103139# continued work on the impress annotation feature
    2009-09-07 17:25:43 +0200 cl  r275905 : #i103139# continued work on the impress annotation feature
    2009-09-07 12:00:28 +0200 cl  r275884 : #i103139# continued work on the impress annotation feature
    2009-09-06 14:14:00 +0200 cl  r275859 : #i103139# continued work on the impress annotation feature
    2009-09-05 20:57:24 +0200 cl  r275854 : #i103139# continued work on the impress annotation feature
    2009-09-05 20:56:29 +0200 cl  r275853 : #i103139# continued work on the impress annotation feature
    2009-09-05 20:55:27 +0200 cl  r275852 : #i103139# continued work on the impress annotation feature
    2009-09-05 20:11:42 +0200 cl  r275851 : #i103139# continued work on the impress annotation feature
    2009-09-05 20:11:09 +0200 cl  r275850 : #i103139# continued work on the impress annotation feature
    2009-09-05 17:43:33 +0200 cl  r275845 : #i103139# continued work on the impress annotation feature
    2009-09-05 17:04:41 +0200 cl  r275843 : #i103139# continued work on the impress annotation feature
    2009-09-05 17:03:26 +0200 cl  r275842 : #i103139# continued work on the impress annotation feature
    2009-09-05 17:02:53 +0200 cl  r275841 : #i103139# continued work on the impress annotation feature
    2009-09-05 13:15:04 +0200 pl  r275839 : #i104823# WB_NEEDSFOCUS
    2009-09-05 13:14:41 +0200 pl  r275838 : #i104823# WB_NEEDSFOCUS
    2009-09-04 17:48:21 +0200 cl  r275826 : #i103139# continued work on the impress annotation feature
    2009-09-04 17:35:03 +0200 cl  r275825 : #i103139# continued work on the impress annotation feature
    2009-09-04 17:15:46 +0200 cl  r275824 : #i103139# continued work on the impress annotation feature
    2009-09-04 17:12:54 +0200 cl  r275823 : #i103139# continued work on the impress annotation feature
    2009-09-04 17:05:23 +0200 cl  r275822 : #i103139# continued work on the impress annotation feature
    2009-09-04 16:48:28 +0200 cl  r275820 : #i103139# continued work on the impress annotation feature
    2009-09-04 16:44:02 +0200 cl  r275818 : #i103139# continued work on the impress annotation feature
    2009-09-04 16:43:23 +0200 cl  r275817 : #i103139# continued work on the impress annotation feature
    2009-09-04 16:06:04 +0200 cl  r275812 : #i103139# continued work on the impress annotation feature
    2009-09-04 16:05:45 +0200 cl  r275811 : #i103139# continued work on the impress annotation feature
    2009-09-04 15:04:33 +0200 cl  r275806 : #i103139# continued work on the impress annotation feature
    2009-09-04 11:43:14 +0200 cl  r275795 : #i103139# continued work on the impress annotation feature
    2009-09-04 11:27:10 +0200 cl  r275793 : #i103139# continued work on the impress annotation feature
    2009-09-04 11:10:02 +0200 cl  r275792 : #i103139# continued work on the impress annotation feature
    2009-09-04 11:07:05 +0200 cl  r275790 : #i103139# continued work on the impress annotation feature
    2009-09-04 11:05:01 +0200 cl  r275789 : #i103139# continued work on the impress annotation feature
    2009-09-04 10:55:51 +0200 cl  r275785 : #i103139# renamed notes to comments
    2009-09-04 10:54:57 +0200 cl  r275784 : #i103139# renamed notes to comments
    2009-09-03 20:37:35 +0200 cl  r275772 : #i103139# continued work on the impress annotation feature
    2009-09-03 20:35:31 +0200 cl  r275771 : #i103139# continued work on the impress annotation feature
    2009-09-01 18:17:55 +0200 cl  r275680 : #i103139# continued work on the impress annotation feature
    2009-09-01 18:15:08 +0200 cl  r275678 : #i103139# continued work on the impress annotation feature
    2009-09-01 18:13:38 +0200 cl  r275677 : #i103139#
    continued work on the impress annotation feature
    2009-08-18 12:35:42 +0200 cl  r275089 : fixed merge error
    2009-08-18 11:39:58 +0200 cl  r275086 : CWS-TOOLING: rebase CWS impressnotes01 to trunk at 275001 (milestone: DEV300:m55)
    2009-07-30 13:45:10 +0200 cl  r274481 : fixed merge errrors
    2009-07-30 13:41:21 +0200 cl  r274480 : fixed merge errrors
    2009-07-30 13:39:40 +0200 cl  r274478 : fixed merge errrors
    2009-07-22 18:07:30 +0200 cl  r274256 : CWS-TOOLING: rebase CWS impressnotes01 to trunk at 273858 (milestone: DEV300:m52)
    2009-07-21 17:21:31 +0200 cl  r274208 : merging
    2009-07-20 14:28:34 +0200 cl  r274137 : #i103139# annotation support for impress
    2009-07-20 14:28:04 +0200 cl  r274136 : #i103139# annotation support for impress
    2009-07-20 14:27:20 +0200 cl  r274135 : #i103139# annotation support for impress
    2009-07-20 14:21:17 +0200 cl  r274134 : #i103139# annotation support for impress
    2009-07-20 14:20:56 +0200 cl  r274133 : #i103139# annotation support for impress
    2009-07-20 14:20:09 +0200 cl  r274132 : #i103139# annotation support for impress
    2009-07-20 14:19:00 +0200 cl  r274131 : #i103139# annotation support for impress
    2009-07-20 14:17:50 +0200 cl  r274130 : #i103139# annotation support for impress
    2009-07-20 14:12:24 +0200 cl  r274129 : #i103139# annotation support for impress
    2009-07-20 13:52:03 +0200 cl  r274128 : #i103139# annotation support for impress
    2009-07-20 13:51:11 +0200 cl  r274127 : #i103139# annotation support for impress
    2009-07-20 13:48:59 +0200 cl  r274126 : #i103139# annotation support for impress
    2009-07-20 13:43:56 +0200 cl  r274125 : #i103139# annotation support for impress
    2009-07-20 13:31:55 +0200 cl  r274123 : #i103139# annotation support for impress
    2009-07-20 13:30:45 +0200 cl  r274122 : #i103139# annotation support for impress

diff --git a/offapi/com/sun/star/modules.idl b/offapi/com/sun/star/modules.idl
index b58f0ec..34485e6 100644
--- a/offapi/com/sun/star/modules.idl
+++ b/offapi/com/sun/star/modules.idl
@@ -90,6 +90,9 @@ module datatransfer {};
 /// Office document related interfaces.
 module document {};
 
+/// Office document content related interfaces.
+module office {};
+
 /// Drawing and shape specific interfaces.
 module drawing {};
 
diff --git a/offapi/com/sun/star/office/XAnnotation.idl b/offapi/com/sun/star/office/XAnnotation.idl
new file mode 100644
index 0000000..8f56cc1
--- /dev/null
+++ b/offapi/com/sun/star/office/XAnnotation.idl
@@ -0,0 +1,105 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ * 
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: XGalleryItem.idl,v $
+ * $Revision: 1.4 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org.  If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_office_XAnnotation_idl__
+#define __com_sun_star_office_XAnnotation_idl__
+
+#ifndef __com_sun_star_beans_XPropertySet_idl__
+#include <com/sun/star/beans/XPropertySet.idl>
+#endif
+
+#ifndef __com_sun_star_beans_XMultiPropertySet_idl__
+#include <com/sun/star/beans/XMultiPropertySet.idl>
+#endif
+
+#ifndef __com_sun_star_util_DateTime_idl__ 
+#include <com/sun/star/util/DateTime.idl>
+#endif
+
+#ifndef __com_sun_star_text_XText_idl__
+#include <com/sun/star/text/XText.idl>
+#endif
+
+#ifndef __com_sun_star_geometry_RealPoint2D_idl__
+#include <com/sun/star/geometry/RealPoint2D.idl>
+#endif
+
+#ifndef __com_sun_star_geometry_RealSize2D_idl__
+#include <com/sun/star/geometry/RealSize2D.idl>
+#endif
+
+#ifndef __com_sun_star_lang_XComponent_idl__
+#include <com/sun/star/lang/XComponent.idl>
+#endif
+
+//=============================================================================
+
+module com {  module sun {  module star {  module office {
+
+//=============================================================================
+
+/** This interface gives access to an annotation inside a document.
+ */
+interface XAnnotation
+{
+    /** All attributes are also available as properties. */
+    interface ::com::sun::star::beans::XPropertySet;
+
+    /** manages the lifetime of this annotation, should only be used
+        by the owner of the annotation which should be the document itself. */
+    interface ::com::sun::star::lang::XComponent;
+
+    /** a reference to the document content this annotation is anchored to. */
+    [attribute, readonly] any Anchor;
+    
+    /** this is an optional position that gives the user interface a hint where
+        the annotation should be rendered. This could be an offset to the
+        annotations anchor. */
+    [attribute] ::com::sun::star::geometry::RealPoint2D Position;
+
+    /** this is an optional size that gives the user interface a hint how
+        large the annotation should be rendered. */
+    [attribute] ::com::sun::star::geometry::RealSize2D Size;
+
+    /** stores the full name of the author who created this annotation. */
+    [attribute] string Author;
+
+    /** stores the date and time this annotation was last edited. */
+    [attribute] ::com::sun::star::util::DateTime DateTime;
+
+    /** gives access to the annotations text. */
+    [attribute, readonly] ::com::sun::star::text::XText TextRange;
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
diff --git a/offapi/com/sun/star/office/XAnnotationAccess.idl b/offapi/com/sun/star/office/XAnnotationAccess.idl
new file mode 100644
index 0000000..7d48fc6
--- /dev/null
+++ b/offapi/com/sun/star/office/XAnnotationAccess.idl
@@ -0,0 +1,75 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ * 
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: XGalleryItem.idl,v $
+ * $Revision: 1.4 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org.  If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef __com_sun_star_office_XAnnotationAccess_idl__
+#define __com_sun_star_office_XAnnotationAccess_idl__
+
+#ifndef __com_sun_star_office_XAnnotationEnumeration_idl__ 
+#include <com/sun/star/office/XAnnotationEnumeration.idl>
+#endif
+
+#ifndef __com_sun_star_lang_IllegalArgumentException_idl__
+#include <com/sun/star/office/IllegalArgumentException.idl>
+#endif
+
+#ifndef __com_sun_star_office_XAnnotation_idl__
+#include <com/sun/star/office/XAnnotation.idl>
+#endif
+
+//=============================================================================
+
+module com {  module sun {  module star {  module office {
+
+//=============================================================================
+
+/** This interface gives access to the annotation for a document content.
+ */
+interface XAnnotationAccess
+{    
+    /** creates a new annotation and inserts it into the document content.
+    */
+    XAnnotation createAndInsertAnnotation();
+
+    /** removes the annotation from this document content.
+    */
+    void removeAnnotation( [in] XAnnotation annotation ) raises ( com::sun::star::lang::IllegalArgumentException );
+
+    /** @returns		 
+            a new enumeration object for this annotation container.
+            It returns NULL if there are no objects in this container.
+     */
+    XAnnotationEnumeration createAnnotationEnumeration(); 
+};
+
+//=============================================================================
+
+}; }; }; };
+
+#endif
diff --git a/offapi/com/sun/star/office/XAnnotationEnumeration.idl b/offapi/com/sun/star/office/XAnnotationEnumeration.idl
new file mode 100644
index 0000000..20758b2
--- /dev/null
+++ b/offapi/com/sun/star/office/XAnnotationEnumeration.idl
@@ -0,0 +1,74 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ * 
+ * Copyright 2008 by Sun Microsystems, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * $RCSfile: XEnumeration.idl,v $
+ * $Revision: 1.12 $
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org.  If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+#ifndef __com_sun_star_office_XAnnotationEnumeration_idl__ 
+#define __com_sun_star_office_XAnnotationEnumeration_idl__ 
+ 
+#ifndef __com_sun_star_office_XAnnotation_idl__ 
+#include <com/sun/star/office/XAnnotation.idl> 
+#endif 
+ 
+#ifndef __com_sun_star_container_NoSuchElementException_idl__ 
+#include <com/sun/star/container/NoSuchElementException.idl> 
+#endif 
+  
+//============================================================================= 
+ 
+module com {  module sun {  module star {  module office {  
+ 
+//============================================================================= 
+ 
+/** An enumeration for a set of annotations.
+ */
+interface XAnnotationEnumeration
+{ 
+    //------------------------------------------------------------------------- 
+     
+    /** tests whether this enumeration contains more elements.
+     */
+    boolean hasMoreElements(); 
+ 
+    //------------------------------------------------------------------------- 
+     
+    /** @returns      
+            the next element of this enumeration.  
+                 
+        @throws  NoSuchElementException   
+            if no more elements exist. 
+    */
+    XAnnotation nextElement() 
+            raises( com::sun::star::container::NoSuchElementException ); 
+ 
+}; 
+ 
+//============================================================================= 
+ 
+}; }; }; };  
+ 
+#endif 
diff --git a/offapi/com/sun/star/office/makefile.mk b/offapi/com/sun/star/office/makefile.mk
new file mode 100644
index 0000000..404c23c
--- /dev/null
+++ b/offapi/com/sun/star/office/makefile.mk
@@ -0,0 +1,51 @@
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# 
+# Copyright 2008 by Sun Microsystems, Inc.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# $RCSfile: makefile.mk,v $
+#
+# $Revision: 1.5 $
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org.  If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+
+PRJ=..$/..$/..$/..
+PRJNAME=offapi
+TARGET=cssoffice
+PACKAGE=com$/sun$/star$/office
+
+# --- Settings -----------------------------------------------------
+
+.INCLUDE :  $(PRJ)$/util$/makefile.pmk
+
+# ------------------------------------------------------------------------
+
+IDLFILES=\
+    XAnnotation.idl\
+    XAnnotationEnumeration.idl\
+    XAnnotationAccess.idl
+
+# ------------------------------------------------------------------
+
+.INCLUDE :  target.mk
+.INCLUDE :  $(PRJ)$/util$/target.pmk
diff --git a/offapi/prj/build.lst b/offapi/prj/build.lst
index 6b4a0b9..6ddea01 100644
--- a/offapi/prj/build.lst
+++ b/offapi/prj/build.lst
@@ -103,5 +103,6 @@ oa	offapi\com\sun\star\xml\wrapper		    nmake	-	all	oa_wrapper oa_sax NULL
 oa	offapi\com\sun\star\geometry		    nmake	-	all	oa_geometry NULL
 oa	offapi\com\sun\star\rendering	        nmake	-	all oa_rendering oa_geometry NULL
 oa	offapi\com\sun\star\rdf	                nmake	-	all oa_rdf  oa_datatransfer oa_text NULL
+oa	offapi\com\sun\star\office              nmake	-	all oa_office oa_text NULL
 oa	offapi\drafts\com\sun\star\form         nmake	-	all	oa_drafts_form NULL
-oa  offapi\util                             nmake   -   all oa_util oa_auth oa_awt oa_awttree oa_awtgrid oa_chart oa_chart2 oa_chart2_data oa_config oa_configbootstrap oa_configbackend oa_configbackend_xml oa_datatrans_clip oa_datatrans_dnd oa_datatransfer oa_docu oa_draw oa_draw_framework oa_embed oa_fcomp oa_finsp oa_fcontr oa_fieldmaster oa_form oa_xforms oa_formula oa_frame oa_i18n oa_inst oa_ldap oa_ling2 oa_logging oa_mail oa_media oa_mozilla oa_packages oa_manifest oa_zippackage oa_plug oa_pres oa_animations oa_putil oa_resrc oa_sax oa_xml_input oa_scan oa_sdb oa_sdbtools oa_sdbapp oa_sdbc oa_sdbcx oa_setup oa_sheet oa_style oa_svg oa_sync oa_sync2 oa_system oa_table oa_task oa_text oa_textfield oa_docinfo oa_ucb oa_view oa_xml oa_xml_dom oa_xml_xpath oa_xml_views oa_xml_events oa_image oa_xsd oa_inspection oa_ui oa_ui_dialogs oa_accessibility oa_form_binding oa_form_validation oa_form_submission oa_fruntime oa_geometry oa_rendering oa_sfprovider oa_sfbrowse oa_drafts_form oa_deployment oa_deploymenttest oa_deployment_ui oa_frame_status oa_gallery oa_graphic oa_security oa_crypto_sax oa_crypto oa_csax oa_wrapper oa_script oa_smarttags oa_report oa_reportins oa_reportmeta oa_rdf oa_oooimprovement NULL
+oa  offapi\util                             nmake   -   all oa_util oa_auth oa_awt oa_awttree oa_awtgrid oa_chart oa_chart2 oa_chart2_data oa_config oa_configbootstrap oa_configbackend oa_configbackend_xml oa_datatrans_clip oa_datatrans_dnd oa_datatransfer oa_docu oa_draw oa_draw_framework oa_embed oa_fcomp oa_finsp oa_fcontr oa_fieldmaster oa_form oa_xforms oa_formula oa_frame oa_i18n oa_inst oa_ldap oa_ling2 oa_logging oa_mail oa_media oa_mozilla oa_packages oa_manifest oa_zippackage oa_plug oa_pres oa_animations oa_putil oa_resrc oa_sax oa_xml_input oa_scan oa_sdb oa_sdbtools oa_sdbapp oa_sdbc oa_sdbcx oa_setup oa_sheet oa_style oa_svg oa_sync oa_sync2 oa_system oa_table oa_task oa_text oa_textfield oa_docinfo oa_ucb oa_view oa_xml oa_xml_dom oa_xml_xpath oa_xml_views oa_xml_events oa_image oa_xsd oa_inspection oa_ui oa_ui_dialogs oa_accessibility oa_form_binding oa_form_validation oa_form_submission oa_fruntime oa_geometry oa_rendering oa_sfprovider oa_sfbrowse oa_drafts_form oa_deployment oa_deploymenttest oa_deployment_ui oa_frame_status oa_gallery oa_graphic oa_security oa_crypto_sax oa_crypto oa_csax oa_wrapper oa_script oa_smarttags oa_report oa_reportins oa_reportmeta oa_rdf oa_oooimprovement oa_office NULL
diff --git a/offapi/util/makefile.mk b/offapi/util/makefile.mk
index fcf3e4b..b0fa7a3 100644
--- a/offapi/util/makefile.mk
+++ b/offapi/util/makefile.mk
@@ -144,6 +144,7 @@ UNOIDLDBFILES= \
     $(UCR)$/cssreport.db \
     $(UCR)$/cssrptins.db \
     $(UCR)$/cssrptmeta.db \
+    $(UCR)$/cssoffice.db \
     $(UCR)$/cssrdf.db
 
 
diff --git a/offuh/prj/d.lst b/offuh/prj/d.lst
index 0e85b26..bedbc8d 100644
--- a/offuh/prj/d.lst
+++ b/offuh/prj/d.lst
@@ -51,6 +51,7 @@ mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\lang
 mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\linguistic2
 mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\logging
 mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\oooimprovement
+mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\office
 mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\mail
 mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\media
 mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\packages
@@ -226,6 +227,8 @@ mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\rdf
 ..\%__SRC%\inc\offuh\com\sun\star\linguistic2\*.hpp %_DEST%\inc%_EXT%\offuh\com\sun\star\linguistic2\*.hpp
 ..\%__SRC%\inc\offuh\com\sun\star\logging\*.hdl %_DEST%\inc%_EXT%\offuh\com\sun\star\logging\*.hdl
 ..\%__SRC%\inc\offuh\com\sun\star\logging\*.hpp %_DEST%\inc%_EXT%\offuh\com\sun\star\logging\*.hpp
+..\%__SRC%\inc\offuh\com\sun\star\office\*.hpp %_DEST%\inc%_EXT%\offuh\com\sun\star\office\*.hpp
+..\%__SRC%\inc\offuh\com\sun\star\office\*.hdl %_DEST%\inc%_EXT%\offuh\com\sun\star\office\*.hdl
 ..\%__SRC%\inc\offuh\com\sun\star\oooimprovement\*.hdl %_DEST%\inc%_EXT%\offuh\com\sun\star\oooimprovement\*.hdl
 ..\%__SRC%\inc\offuh\com\sun\star\oooimprovement\*.hpp %_DEST%\inc%_EXT%\offuh\com\sun\star\oooimprovement\*.hpp
 ..\%__SRC%\inc\offuh\com\sun\star\mail\*.hpp %_DEST%\inc%_EXT%\offuh\com\sun\star\mail\*.hpp
@@ -371,4 +374,3 @@ mkdir: %_DEST%\inc%_EXT%\offuh\com\sun\star\rdf
 
 ..\%__SRC%\inc\offuh\com\sun\star\rdf\*.hpp %_DEST%\inc%_EXT%\offuh\com\sun\star\rdf\*.hpp
 ..\%__SRC%\inc\offuh\com\sun\star\rdf\*.hdl %_DEST%\inc%_EXT%\offuh\com\sun\star\rdf\*.hdl
-
commit 5b20b25be19b27c31a0c7e455b730e605830f76e
Author: Ivo Hinkelmann <ihi at openoffice.org>
Date:   Wed Sep 16 11:45:54 2009 +0000

    CWS-TOOLING: integrate CWS l10nframework01

diff --git a/io/inc/makefile.mk b/io/inc/makefile.mk
index 7a15edc..ce9aa90 100644
--- a/io/inc/makefile.mk
+++ b/io/inc/makefile.mk
@@ -36,16 +36,18 @@ TARGET=inc
 # --- Settings -----------------------------------------------------
 
 .INCLUDE :  settings.mk
-
+.IF "$(L10N_framework)"==""
 # --- Files --------------------------------------------------------
 # --- Targets -------------------------------------------------------
+.ENDIF 		# L10N_framework
 
 .INCLUDE :  target.mk
-
+.IF "$(L10N_framework)"==""
 .IF "$(ENABLE_PCH)"!=""
 ALLTAR : \
     $(SLO)$/precompiled.pch \
     $(SLO)$/precompiled_ex.pch
     
 .ENDIF			# "$(ENABLE_PCH)"!=""
+.ENDIF 		# L10N_framework
 
diff --git a/io/source/TextInputStream/makefile.mk b/io/source/TextInputStream/makefile.mk
index fcca36f..1fb5aa3 100644
--- a/io/source/TextInputStream/makefile.mk
+++ b/io/source/TextInputStream/makefile.mk
@@ -37,6 +37,7 @@ ENABLE_EXCEPTIONS=TRUE
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 
 SLOFILES= \
@@ -59,5 +60,6 @@ SHL1RPATH=      URELIB
 DEF1NAME=		$(SHL1TARGET)
 
 # --- Targets ------------------------------------------------------
+.ENDIF 		# L10N_framework
 
 .INCLUDE :	target.mk
diff --git a/io/source/TextOutputStream/makefile.mk b/io/source/TextOutputStream/makefile.mk
index 5359458..7a4c0d6 100644
--- a/io/source/TextOutputStream/makefile.mk
+++ b/io/source/TextOutputStream/makefile.mk
@@ -37,6 +37,7 @@ ENABLE_EXCEPTIONS=TRUE
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 # ------------------------------------------------------------------
 
@@ -60,5 +61,6 @@ SHL1RPATH=      URELIB
 DEF1NAME=		$(SHL1TARGET)
 
 # --- Targets ------------------------------------------------------
+.ENDIF 		# L10N_framework
 
 .INCLUDE :	target.mk
diff --git a/io/source/acceptor/makefile.mk b/io/source/acceptor/makefile.mk
index b537b20..843f262 100644
--- a/io/source/acceptor/makefile.mk
+++ b/io/source/acceptor/makefile.mk
@@ -40,6 +40,7 @@ COMPRDB=$(SOLARBINDIR)$/udkapi.rdb
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 # ------------------------------------------------------------------
 
@@ -71,4 +72,6 @@ SHL1DEF=		$(MISC)$/$(SHL1TARGET).def
 DEF1NAME=		$(SHL1TARGET)
 
 # --- Targets ------------------------------------------------------
+.ENDIF 		# L10N_framework
+
 .INCLUDE :	target.mk
diff --git a/io/source/connector/makefile.mk b/io/source/connector/makefile.mk
index d726ac4..471f6b9 100644
--- a/io/source/connector/makefile.mk
+++ b/io/source/connector/makefile.mk
@@ -40,6 +40,7 @@ COMPRDB=$(SOLARBINDIR)$/udkapi.rdb
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 # ------------------------------------------------------------------
 
@@ -71,5 +72,6 @@ SHL1DEF=		$(MISC)$/$(SHL1TARGET).def
 DEF1NAME=		$(SHL1TARGET)
 
 # --- Targets ------------------------------------------------------
+.ENDIF 		# L10N_framework
 
 .INCLUDE :	target.mk
diff --git a/io/source/stm/makefile.mk b/io/source/stm/makefile.mk
index e4b8ad3..43b6f25 100644
--- a/io/source/stm/makefile.mk
+++ b/io/source/stm/makefile.mk
@@ -32,6 +32,7 @@ PRJ=..$/..
 
 PRJNAME=io
 TARGET = streams.uno
+
 ENABLE_EXCEPTIONS=TRUE
 NO_BSYMBOLIC=TRUE
 COMP1TYPELIST = stm
@@ -39,6 +40,7 @@ COMPRDB=$(SOLARBINDIR)$/udkapi.rdb
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 # --- Files --------------------------------------------------------
 UNOUCRDEP=$(SOLARBINDIR)$/udkapi.rdb
@@ -73,5 +75,7 @@ DEF1NAME=		$(SHL1TARGET)
 
 
 # --- Targets ------------------------------------------------------
+.ENDIF 		# L10N_framework
+
 .INCLUDE :	target.mk
 
diff --git a/io/test/makefile.mk b/io/test/makefile.mk
index af032ba..b7acf67 100644
--- a/io/test/makefile.mk
+++ b/io/test/makefile.mk
@@ -41,6 +41,7 @@ ENABLE_EXCEPTIONS=TRUE
 # --- Settings -----------------------------------------------------
 
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 # --- Files --------------------------------------------------------
 
 OBJFILES=	$(OBJ)$/testcomponent.obj \
@@ -90,5 +91,6 @@ $(BIN)$/applicat.rdb: $(SOLARBINDIR)$/udkapi.rdb
     rm -f $@
     regmerge $@ / $?
 
+.ENDIF 		# L10N_framework
 
 .INCLUDE :  target.mk
diff --git a/io/test/stm/makefile.mk b/io/test/stm/makefile.mk
index cb5f6b0..01d334e 100644
--- a/io/test/stm/makefile.mk
+++ b/io/test/stm/makefile.mk
@@ -37,6 +37,7 @@ ENABLE_EXCEPTIONS=TRUE
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 # --- Files --------------------------------------------------------
 UNOUCRDEP=$(SOLARBINDIR)$/udkapi.rdb
 UNOUCRRDB=$(SOLARBINDIR)$/udkapi.rdb
@@ -97,5 +98,6 @@ DEF1EXPORTFILE=	exports.dxp
 
 
 # --- Targets ------------------------------------------------------
+.ENDIF 		# L10N_framework
 
 .INCLUDE :	target.mk
diff --git a/pyuno/source/loader/makefile.mk b/pyuno/source/loader/makefile.mk
index 11ece47..6acb867 100644
--- a/pyuno/source/loader/makefile.mk
+++ b/pyuno/source/loader/makefile.mk
@@ -37,7 +37,7 @@ ENABLE_EXCEPTIONS=TRUE
 # --- Settings -----------------------------------------------------
 
 .INCLUDE :  settings.mk
-
+.IF "$(L10N_framework)"==""
 DLLPRE = 
 
 #-------------------------------------------------------------------
@@ -101,9 +101,10 @@ COMPONENTS= \
 ALL : ALLTAR \
     $(DLLDEST)$/pythonloader.py	\
     $(DLLDEST)$/pyuno_services.rdb
+.ENDIF # L10N_framework
 
 .INCLUDE :  target.mk
-
+.IF "$(L10N_framework)"==""
 $(DLLDEST)$/%.py: %.py
     cp $? $@
 
@@ -115,4 +116,5 @@ $(DLLDEST)$/pyuno_services.rdb : makefile.mk $(DLLDEST)$/$(DLLPRE)$(TARGET)$(DLL
     cd $(DLLDEST) && $(REGCOMP) -register -r pyuno_services.tmp -wop $(foreach,i,$(COMPONENTS) -c $(i))
 .ENDIF    # "$(GUI)$(COM)"=="WNTGCC" 
     cd $(DLLDEST) && mv pyuno_services.tmp pyuno_services.rdb
+.ENDIF # L10N_framework
 
diff --git a/pyuno/source/module/makefile.mk b/pyuno/source/module/makefile.mk
index cb1ef41..2357d00 100644
--- a/pyuno/source/module/makefile.mk
+++ b/pyuno/source/module/makefile.mk
@@ -39,6 +39,7 @@ LINKFLAGSDEFS = # do not fail with missing symbols
 # --- Settings -----------------------------------------------------
 
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 #-------------------------------------------------------------------
 
 .IF "$(OS)$(CPU)$(COMEX)" == "SOLARISS4"
@@ -128,10 +129,11 @@ ALLTAR : \
     $(DLLDEST)$/unohelper.py	\
     $(PYUNO_MODULE)			\
     $(MISC)$/$(PYUNORC)		
+.ENDIF 
 .ENDIF
 
 .INCLUDE :  target.mk
-
+.IF "$(L10N_framework)"==""
 $(DLLDEST)$/%.py: %.py
     cp $? $@
 
@@ -163,4 +165,5 @@ $(MISC)$/$(PYUNORC) : pyuno
 $(MISC)$/pyuno.flt : pyuno.flt
     -rm -f $@
     cat $? > $@
+.ENDIF # L10N_framework
 
diff --git a/pyuno/zipcore/makefile.mk b/pyuno/zipcore/makefile.mk
index f46106d..a820c1a 100755
--- a/pyuno/zipcore/makefile.mk
+++ b/pyuno/zipcore/makefile.mk
@@ -36,7 +36,7 @@ TARGET=zipcore
 LIBTARGET=NO
 
 .INCLUDE : settings.mk
-
+.IF "$(L10N_framework)"==""
 UWINAPILIB =
 
 .IF "$(SYSTEM_PYTHON)" == "YES" || "$(GUI)" == "OS2"
@@ -74,6 +74,7 @@ APP1RPATH = BRAND
 OBJFILES = $(OBJ)$/python.obj
 .ENDIF
 
+
 .INCLUDE: target.mk
 
 ALLTAR: \
@@ -129,3 +130,7 @@ $(DESTROOT)$/bin$/python$(EXECPOST) : $(SOLARBINDIR)$/python$(EXECPOST)
 .ENDIF
 
 .ENDIF
+.ELSE
+ivo:
+    $(ECHO)
+.ENDIF # L10N_framework
diff --git a/remotebridges/source/bridge/makefile.mk b/remotebridges/source/bridge/makefile.mk
index ef02b1b..75b5f3a 100644
--- a/remotebridges/source/bridge/makefile.mk
+++ b/remotebridges/source/bridge/makefile.mk
@@ -38,6 +38,7 @@ COMP1TYPELIST = remotebridge
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 # ------------------------------------------------------------------
 
@@ -61,6 +62,7 @@ SHL1DEF=		$(MISC)$/$(SHL1TARGET).def
 SHL1RPATH=      URELIB
 
 DEF1NAME=		$(SHL1TARGET)
+.ENDIF 		# L10N_framework
 
 # --- Targets ------------------------------------------------------
 .INCLUDE :	target.mk
diff --git a/remotebridges/source/dynamicloader/makefile.mk b/remotebridges/source/dynamicloader/makefile.mk
index 1a4364c..95a80e1 100755
--- a/remotebridges/source/dynamicloader/makefile.mk
+++ b/remotebridges/source/dynamicloader/makefile.mk
@@ -39,6 +39,7 @@ COMP1TYPELIST = dynamicloader
 # --- Settings -----------------------------------------------------
 
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 
 # ------------------------------------------------------------------
@@ -65,6 +66,7 @@ SHL1DEF=$(MISC)$/$(SHL1TARGET).def
 
 DEF1NAME=	$(SHL1TARGET)
 
+.ENDIF 		# L10N_framework
 
 # --- Targets ------------------------------------------------------
 
diff --git a/remotebridges/source/factory/makefile.mk b/remotebridges/source/factory/makefile.mk
index 280ed38..97eb024 100644
--- a/remotebridges/source/factory/makefile.mk
+++ b/remotebridges/source/factory/makefile.mk
@@ -38,6 +38,7 @@ COMP1TYPELIST = brdgfctr
 
 # --- Settings -----------------------------------------------------
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 # ------------------------------------------------------------------
 
@@ -61,6 +62,7 @@ SHL1DEF=		$(MISC)$/$(SHL1TARGET).def
 SHL1RPATH=      URELIB
 
 DEF1NAME=		$(SHL1TARGET)
+.ENDIF 		# L10N_framework
 
 # --- Targets ------------------------------------------------------
 
diff --git a/remotebridges/source/unourl_resolver/makefile.mk b/remotebridges/source/unourl_resolver/makefile.mk
index bb005dc..81f8b1c 100644
--- a/remotebridges/source/unourl_resolver/makefile.mk
+++ b/remotebridges/source/unourl_resolver/makefile.mk
@@ -38,6 +38,7 @@ COMP1TYPELIST = uuresolver
 # --- Settings -----------------------------------------------------
 
 .INCLUDE :  settings.mk
+.IF "$(L10N_framework)"==""
 DLLPRE =
 
 # ------------------------------------------------------------------
@@ -60,6 +61,7 @@ SHL1DEF=	$(MISC)$/$(SHL1TARGET).def
 SHL1RPATH=  URELIB
 
 DEF1NAME=	$(SHL1TARGET)
+.ENDIF 		# L10N_framework
 
 # --- Targets ------------------------------------------------------
 


More information about the ooo-build-commit mailing list