GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Fix/db create double close by deepsidhu1313 · Pull Request #4229 · sqlitebrowser/sqlitebrowser

Conversation

@deepsidhu1313

@deepsidhu1313 deepsidhu1313 commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

SqliteTableModel::setTypedData() accessed m_cache with at(). The cache is
sparse and rows beyond the loaded chunk are valid model rows (rowCount()
includes them), so editing such a row, e.g. by pasting a large clipboard,
raised std::out_of_range ("no matching segment found") and terminated the
application.

Load the row first (triggerCacheLoad + waitUntilIdle, as find() already
does) and skip the edit if it is still not available.

Add a test-table-model target covering both an uncached and a cached row.

Fixes #3892

Co-Authored-By: Claude Sonnet 5.5 [email protected]

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
claude added 8 commits October 25, 2026 03:55
@claude
Fix crash when pasting into rows that are not loaded yet
fb0f950
SqliteTableModel::setTypedData() accessed m_cache with at(). The cache is
sparse and rows beyond the loaded chunk are valid model rows (rowCount()
includes them), so editing such a row, e.g. by pasting a large clipboard,
raised std::out_of_range ("no matching segment found") and terminated the
application.

Load the row first (triggerCacheLoad + waitUntilIdle, as find() already
does) and skip the edit if it is still not available.

Add a test-table-model target covering both an uncached and a cached row.

Fixes sqlitebrowser#3892

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@claude
Run test-table-model without a display
37583f3
The test used QTEST_MAIN, which needs a Qt platform plugin and aborted on
the headless CI runners. Select the offscreen platform in main() unless
QT_QPA_PLATFORM is already set.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@claude
Don't use DBBrowserDB::create() in test-table-model
891a68b
create() closes the sqlite3 handle and then calls open(), which closes
the dangling handle a second time. That crashed the test on Windows CI.
Open an empty database file instead.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@claude
Fix closing the database handle twice when creating a database
6d355ca
DBBrowserDB::create() closed the sqlite3 handle but left _db pointing at
it, so the open() call that follows saw an open database and closed the
stale handle a second time. This is undefined behaviour; it showed up as
the warning "Database didn't close correctly" on Linux and crashed a test
on Windows.

Reset _db after closing it, and add a test that create() does not
produce any warning.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@claude
Let test-table-model find the SQLite DLL on Windows
3b50490
test-global-filter needs the CMake prefix paths on PATH on Windows
because the CI jobs build SQLite as a DLL there. test-table-model links
SQLite too and crashed on Windows without them.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@claude
Merge branch 'fix/paste-uncached-row' into fix/db-create-double-close
c26f489
@claude
Build test-table-model with Qt6 UI connections
4457a76
The .ui files connect to slots that don't exist in Qt6 (QDialog::help)
unless uic generates string based connections. The main target already
sets this option for Qt6, but test-table-model compiles CipherDialog.ui
as well and failed to build in the Windows on ARM job.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@claude
Merge branch 'fix/paste-uncached-row' into fix/db-create-double-close
484df07

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

[Bug]: crash when pasting certain data into cell

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@deepsidhu1313 @claude
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.