To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=104182
                 Issue #|104182
                 Summary|[XComponent]->dispose() not executed after a period of
                        | time
               Component|Word processor
                 Version|OOo 3.1
                Platform|PC
                     URL|
              OS/Version|Windows XP
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|programming
             Assigned to|writerneedsconfirm
             Reported by|mraladin





------- Additional comments from [email protected] Wed Aug 12 09:48:34 
+0000 2009 -------
Problemdescription:

I created some environment for OpenOffice.

The following (WORKING) code i run just one time for getting the needed
pointers/references:

(i found advices everywhere on the internet 'cause the documentation of
the c++ UNO Part is not useful / not helping me much)
--------------------------------------------------------------

Reference<XComponentContext>            xCompContext;
Reference<XMultiComponentFactory>       xMultiComFac;
Reference<XInterface>                   desktopservice;
Reference<XComponentLoader>             xCompLoader;
Reference<XMultiServiceFactory>         xMultiSerFac;
Reference<XInterface>                   xDispatchHelper;
Reference<XDesktop>                     xDesktop;

xCompContext = Reference<XComponentContext>(cppu::bootstrap()); 
xMultiComFac = xCompContext->getServiceManager();
desktopservice = xMultiComFac->createInstanceWithContext(
 OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Desktop")),
 xCompContext
);

xDispatchHelper = xMultiComFac->createInstanceWithContext(
 OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.DispatchHelper")),
 xCompContext
);
                
xMultiSerFac = (*new Reference<XMultiServiceFactory>(xMultiComFac,UNO_QUERY));
xCompLoader = (*new Reference<XComponentLoader>(desktopservice,UNO_QUERY));
xDesktop = (*new Reference<XDesktop>(desktopservice,UNO_QUERY));

--------------------------------------------------------------


After i have the pointers / references, 
i am creating only a XWriter Document

repeating code for every document (i have somehow 400.000 + - some more
documents to create)
--------------------------------------------------------------
Reference<XComponent> xW = xCompLoader->loadComponentFromURL(
 OUString::createFromAscii("private:factory/swriter"),
 OUString::createFromAscii("_blank"),
 0,
 Sequence <::com::sun::star::beans::PropertyValue>()
);

//... insert some content
//... save   to doc
//... export to pdf



xW->dispose(); //CRASHES/NOT RUNNING after some documents
//i tried to dispose the xTextDocument as well ... same problem
//i tried to reapeat all the code i wrote here and on top of the prob descr. ...
same problem (although openoffice is completely restarted)
-------------------------------------------------------
(NOT WORKING) sometimes it happens and 10 documents run through
sometimes not just one document run through

..

so there must be a memory leak or sth else. I tried to interrupt VC++ 9.0 and it
says all threads did end

---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to