Issue 64377 - Increase code size that basic can handle
Summary: Increase code size that basic can handle
Status: CLOSED FIXED
Alias: None
Product: General
Classification: Code
Component: scripting (show other issues)
Version: OOo 2.0.2
Hardware: All All
: P3 Trivial (vote)
Target Milestone: OOo 2.2
Assignee: pmladek
QA Contact: issues@framework
URL:
Keywords:
: 66533 (view as issue list)
Depends on:
Blocks:
 
Reported: 2006-04-13 15:09 UTC by noel.power
Modified: 2007-02-05 13:32 UTC (History)
3 users (show)

See Also:
Issue Type: PATCH
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
patch (57.04 KB, patch)
2006-05-26 12:56 UTC, noel.power
no flags Details | Diff
test document (172.06 KB, application/vnd.oasis.opendocument.spreadsheet)
2006-10-03 18:10 UTC, noel.power
no flags Details
test document (145.38 KB, application/vnd.oasis.opendocument.spreadsheet)
2006-10-03 18:11 UTC, noel.power
no flags Details
test document (145.46 KB, application/msword)
2006-10-03 18:12 UTC, noel.power
no flags Details
test document (146.61 KB, application/vnd.oasis.opendocument.spreadsheet)
2006-10-03 18:45 UTC, noel.power
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description noel.power 2006-04-13 15:09:58 UTC
Basic binary format is bounded by 16 bit limits. This manifests itself in
getting "program too large errors" when dealing with large modules ( as has been
seen by me ) when importing from xl. This enhancement proposes to modify the
binary image layout to use 32 bit fields,offsets etc. This will result in a
significant increase in the max program size that can be handled
Comment 1 noel.power 2006-04-13 15:10:41 UTC
adding ab as cc

proposed cws npower3
Comment 2 noel.power 2006-05-26 12:50:28 UTC
reassign to ab
Comment 3 noel.power 2006-05-26 12:55:54 UTC
change type to patch for review
Comment 4 noel.power 2006-05-26 12:56:28 UTC
Created attachment 36733 [details]
patch
Comment 5 noel.power 2006-05-26 12:56:51 UTC
added patch for review
Comment 6 noel.power 2006-05-26 12:58:38 UTC
changed milestone
Comment 7 ab 2006-07-18 07:48:36 UTC
.> 2.x, should become 2.0.5 as soon as availible
Comment 8 ab 2006-07-18 08:00:29 UTC
*** Issue 66533 has been marked as a duplicate of this issue. ***
Comment 9 ab 2006-08-18 12:29:54 UTC
Patch evaluation is in progress, should be integrated for next milestone
-> OOo 2.1, STARTED
Comment 10 noel.power 2006-10-03 18:10:57 UTC
Created attachment 39533 [details]
test document
Comment 11 noel.power 2006-10-03 18:11:54 UTC
Created attachment 39534 [details]
test document
Comment 12 noel.power 2006-10-03 18:12:34 UTC
Created attachment 39535 [details]
test document
Comment 13 noel.power 2006-10-03 18:45:09 UTC
Created attachment 39536 [details]
test document
Comment 14 noel.power 2006-10-03 18:57:19 UTC
Note: to QA

there are a couple of things to test here

Background
----------

A side affect of changing the offsets is that we can't save password protected
files in the new binary format ( at least not now as the current openoffice
versions can't read the new format, the intention is to allow saving of the new
image format in the next major openoffice version ) So what we do is save
password protected Libraries in the old format. However if someone tries to save
a password protected library containing a module that has a code size bigger
than that supported by the old format we need to inform the user that this is
the case. ( see
http://specs.openoffice.org/scripting_framework/BasicImageSizeIncreaseWarning.odt )

so the first part of the testing should verify that 
a) attempts to save a document containing a password protected library that has
a module that exceeds the supported legacy size pop up the warning described in
the spec
b) attempts to export libraries from the basic organiser dialog (
tools/macros/organizemacros/openoffice.org.basic, select organize libraries,
select the document and library to export )

for a) above the possible scenarios should include various "save" and "save as"
scenarios, also its possible that someone could have an Excel document open and
add a new libarary containing a large module to it and save it as an openoffice
format.

for b) its possible to also export an uno package, the same warning also applies
in this case

attached test document "test-ray-bigmodule.odt" contains such a large Module and
it can be used to test export and "save"/"save as" scenarios. 

e.g. to test b) above Open the document, open the basic organizer, select
libraries, select the document from the drop down list, select the Library Xray,
make it password protected by pressing the password button, press the export
button etc. etc.

for a) similar steps need to be taken to password protect the library followed
by file->save or file->saveas

obviously it should be possible to read a "legacy" password protected library.
attached document "test-ray-oldimagepassword.odt" is a document with a complex
set of macros saved in the legacy binary password protected format.
Openoffice.org should be able to read this "old" 16 bit based format and convert
 it to the new format

similarly the saved password protected format from openoffice.org should be in
the legacy format ( see above for rational ) attached document
test-ray-oldimagesavedfromnewoo.odt is a version of the first test document
saved by this cws version of openoffice ( imo this should be validated manualy )

also we stated earlier that the next major version of openoffice should be able
to save the new image format.  Attached document "test-ray-newimagepassword.odt"
is a document I created that is saved using the new image layout format. 
As ths feature introduces forward compatibilty to this release for the new image
layout it should to read and execute the password protected library macros
contained in the document above

Note: this document was created artificially and no current version of
openoffice can handle the new image format ( in fact it may crash any other
version of openoffice ) 
Comment 15 noel.power 2006-10-03 18:57:37 UTC
fixed
Comment 16 noel.power 2006-10-03 18:58:30 UTC
over to qa
Comment 17 pmladek 2006-10-25 14:36:11 UTC
Verified in CWS npower3.
Comment 18 Martin Hollmichel 2006-11-01 08:59:59 UTC
set target to 2.2
Comment 19 Mathias_Bauer 2007-02-05 13:32:12 UTC
closing ancient issues