Bug 88442

Summary: Global of struct type behave as local variables
Product: LibreOffice Reporter: Lionel Elie Mamane <lionel>
Component: BASICAssignee: Not Assigned <libreoffice-bugs>
Status: NEW --- QA Contact:
Severity: major    
Priority: high CC: bill-list, lionel, nopower, qubit, serval2412, todventtu, uray.janos
Version: Inherited From OOo   
Hardware: x86-64 (AMD64)   
OS: All   
Whiteboard:
i915 platform: i915 features:
Bug Depends on:    
Bug Blocks: 88092    
Attachments: reproduction example

Description Lionel Elie Mamane 2015-01-15 06:40:37 UTC
Created attachment 112267 [details]
reproduction example

+++ This bug was initially created as a clone of Bug #88092 +++

Reproduction instructions:

1. Open attached document, allowing macros to run.

2. Click "Set Struct" button. Click "OK" on the message boxes appearing.

3. Click "Set Show Struct" button.

Actual behaviour:

  In execution of doShow from the button event (that is, after doSet has
  finished executing), aStr keeps the value assigned to it by doSet,
  but aDate is reset to default (all zeros) value.

Expected behaviour:

  Since aDate is a global, it should keep the value that was assigned
  to it by doSet.


The same can be observed by going in the Basic IDE and running (F5 or the toolbar button) the macros from there.
Comment 1 Beluga 2015-01-17 13:17:10 UTC
Repro on Win & Linux.

Changed component to BASIC, I hope it's ok.

Win 7 Pro 64-bit Version: 4.5.0.0.alpha0+
Build ID: 5f6bdce0c0ac687f418821ce328f2987bf340cda
TinderBox: Win-x86@62-TDF, Branch:MASTER, Time: 2015-01-17_01:06:46

Ubuntu 14.10 64-bit
LibreOffice 3.3.0 
OOO330m19 (Build:6)
tag libreoffice-3.3.0.4

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.