Bug 141011 - Password is requested to open MailMerge database when opening More Fields dialog *on any tab*
Summary: Password is requested to open MailMerge database when opening More Fields dia...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.0.0.3 release
Hardware: All All
: medium normal
Assignee: Mike Kaganski
URL:
Whiteboard: target:7.2.0 target:7.1.3
Keywords:
Depends on:
Blocks:
 
Reported: 2021-03-14 08:12 UTC by Mike Kaganski
Modified: 2021-03-17 18:35 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments
MailMerge document and its database (9.23 KB, application/x-zip-compressed)
2021-03-14 08:12 UTC, Mike Kaganski
Details
Screencast of problems with fields dialog in MailMerge document with password-protected DB (3.35 MB, image/gif)
2021-03-14 08:34 UTC, Mike Kaganski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Kaganski 2021-03-14 08:12:40 UTC
Created attachment 170469 [details]
MailMerge document and its database

If the database associated with this MailMerge document is password-protected, then opening More Fields dialog requests that password, regardless of which tab is it opening.

It is OK when Database tab is opened, because it needs to expand the associated database, but it is unexpected and wrong when other tabs are opened.

Steps:

1. Create a password-protected database. E.g., use a password-protected spreadsheet, and create an ODB that uses that spreadsheet. Register it in Options->Base->Databases.
2. Create a new text document, and add a MailMerge field from the database on step 1. Save the document.
3. Insert->Field->More Fields; make sure that any tab *other than Database* is open; close the dialog.
4. Restart LibreOffice, to make sure that the database is not open.
5. Open the MailMerge document created at step 2, and open Insert->Field->More Fields dialog.

=> password is requested, despite the dialog opens at a tab chosen on step 3, not Database tab.

This may be reproduced with the attached repro set. Register the database from the set, open MM.odt, and try to open Insert->Field->More Fields dialog.

Repro in 7.1.1.2, and older versions starting with LO 4.0. In 3.6 and earlier, it only asked the password when opening Database tab (as expected).
Comment 1 Mike Kaganski 2021-03-14 08:34:20 UTC
Created attachment 170471 [details]
Screencast of problems with fields dialog in MailMerge document with password-protected DB

The screencast shows different problems (also filed in bug 141012 and bug 141013).

For the purposes of this bug, note that the password is asked, while the dialog is opened on Document tab, unrelated to the Database/Mail Merge functionality.
Comment 2 Mike Kaganski 2021-03-14 11:51:30 UTC
https://gerrit.libreoffice.org/c/core/+/112469
Comment 3 Commit Notification 2021-03-14 13:56:19 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/0adf52a644aaf85ba2bd666147c62c134234ffbb

tdf#141011: Postpone SwFieldDBPage::Reset to tab activation

It will be available in 7.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 4 Commit Notification 2021-03-17 18:35:20 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "libreoffice-7-1":

https://git.libreoffice.org/core/commit/64f98e467794f98836a99719ecde51bf6a8f8bad

tdf#141011: Postpone SwFieldDBPage::Reset to tab activation

It will be available in 7.1.3.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.