To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=59550
                  Issue #:|59550
                  Summary:|[API] accessing a introspection adapter after
                          |releasing the XIntrospectionAccess crashes OOo
                Component:|udk
                  Version:|680m142
                 Platform:|All
                      URL:|
               OS/Version:|All
                   Status:|NEW
        Status whiteboard:|
                 Keywords:|
               Resolution:|
               Issue type:|DEFECT
                 Priority:|P3
             Subcomponent:|code
              Assigned to:|ab
              Reported by:|fs





------- Additional comments from [EMAIL PROTECTED] Mon Dec 19 04:45:14 -0800 
2005 -------
execute the following piece of C++ code (I am sure that this is reproducible in
Java, too, but the C++ example was easier for me to create :)

  // create the desktop component
  Reference< XInterface > xDesktop = _rxFactory->createInstance(
    ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
      "com.sun.star.frame.Desktop" ) ) );
  // create an instrospection component
  Reference< XIntrospection > xIntrospection( _rxFactory->createInstance(
    ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
      "com.sun.star.beans.Introspection" ) ) ), UNO_QUERY );
  // let it inspect the desktop
  Reference< XIntrospectionAccess > xIntrospectionAccess(
    xIntrospection->inspect( makeAny( xDesktop ) ) );

  // query an XPropertySet adapter
  Reference< XPropertySet > xPropertyAccess(
    xIntrospectionAccess->queryAdapter( XPropertySet::static_type() ),
    UNO_QUERY );

  // ask for some arbitrary property
  Any aValue = xPropertyAccess->getPropertyValue(
    ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "IsPlugged" ) ) );

  // now release the introspection access, and ask again for the same property
  xIntrospectionAccess.clear();
  aValue = xPropertyAccess->getPropertyValue(
    ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "IsPlugged" ) ) );

=> GPF

Targeting this to 2.0.2 since it's a crash which can be easily reproduce when
scripting OOo

---------------------------------------------------------------------
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