Bug 97646 - InputStreamToXInputStreamAdapter doesn't work
Summary: InputStreamToXInputStreamAdapter doesn't work
Status: RESOLVED INVALID
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: BASIC (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-08 13:35 UTC by Samuel Mehrbrodt (allotropia)
Modified: 2016-04-14 13:30 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Beanshell Macro (1.55 KB, text/plain)
2016-02-08 13:35 UTC, Samuel Mehrbrodt (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Samuel Mehrbrodt (allotropia) 2016-02-08 13:35:22 UTC
See the attached Beanshell Macro.
When using line 22 instead 23, the script doesn't work anymore.
This is probably because InputStreamToXInputStreamAdapter doesn't implement XSeekable (while ByteArrayToXInputStreamAdapter does)
Comment 1 Samuel Mehrbrodt (allotropia) 2016-02-08 13:35:47 UTC
Created attachment 122440 [details]
Beanshell Macro
Comment 2 Buovjaga 2016-02-11 10:21:27 UTC
Created C:/test.odt to test.

Confirmed that with line 23, it opens test.odt.
With 23 commented out and 22 enabled, it doesn't open test.odt.

Win 7 Pro 64-bit Version: 5.2.0.0.alpha0+
Build ID: a6f876d45bd4e41a7143594a6cb11b6893a0f620
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
TinderBox: Win-x86@39, Branch:master, Time: 2016-02-11_00:07:38
Locale: fi-FI (fi_FI)
Comment 3 Oliver Specht (CIB) 2016-04-14 13:15:34 UTC
How should the adapter implement XSeekable from a java.io.InputStream? It can only provide what is available: https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html
Comment 4 Oliver Specht (CIB) 2016-04-14 13:30:50 UTC
The adapter cannot provide what the source doesn't offer in any way.
Closing as invalid.