Bug #86180 Reproducible Workbench segfault when no connection
Submitted: 4 May 2017 16:25 Modified: 7 May 2017 15:49
Reporter: Mike Reid Email Updates:
Status: Won't Fix Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:6.3.9 OS:MacOS (10.12.4)
Assigned to: CPU Architecture:Any
Tags: Connection, crash, segfault

[4 May 2017 16:25] Mike Reid
Description:
When an established connection on your machine goes offline, workbench can be reliably segfaulted when attempting to refresh a query result in the result grid.

How to repeat:
1. Open Workbench
2. Connect to remote MySQL database (in my case, via SSH tunnel)
3. Open a new Query Tab
4. Run basic SQL showing records, e.g. SELECT * FROM mysql.user;
5. Turn off Wi-Fi on machine (or if hard-wired, unplug) to kill all connections from machine
6. Click the Refresh data button ("recycle icon") directly above the results in the Result Grid
7. Watch as program/cursor becomes busy (aka beachball), and Workbench segfaults.

(see followup attachment)

Suggested fix:
Refreshing a result set intentionally with no connection technically doesn't make sense, but a real-world scenario does exist when a connection inevitably could get dropped unbeknownst to the user.

Ideally the program would become aware of the change in connection status (or missing tunnel) upon failed communication, and alert the user of the error vs. hard crashing.
[4 May 2017 16:25] Mike Reid
Workbench segfault upon refresh data when offline

Attachment: MySQLWorkbench_2017-05-04-094122_user.crash (application/octet-stream, text), 81.27 KiB.

[7 May 2017 15:49] MySQL Verification Team
Thank you for the bug report. Verified as described.
[14 Sep 18:03] Omer Barnir
Posted by developer:

This issue applies to the legacy MySQL Workbench 8.x implementation that is no longer supported or maintained.
MySQL Workbench 26.7 is a complete rewrite using a new technology stack and does not use the affected legacy implementation.
Therefore, this issue is not applicable to the current MySQL Workbench product and as such is closed.