Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit b2e1f2a

Browse filesBrowse files
qtxoxerial
authored andcommitted
xerial#385 Fix the params check when vals array is reused (xerial#386)
xerial#385
1 parent c7c5604 commit b2e1f2a
Copy full SHA for b2e1f2a

1 file changed

+2-2Lines changed: 2 additions & 2 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • src/main/java/org/sqlite/core
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/main/java/org/sqlite/core/DB.java‎

Copy file name to clipboardExpand all lines: src/main/java/org/sqlite/core/DB.java
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -826,8 +826,8 @@ final synchronized int[] executeBatch(long stmt, int count, Object[] vals, boole
826826
public final synchronized boolean execute(CoreStatement stmt, Object[] vals) throws SQLException {
827827
if (vals != null) {
828828
final int params = bind_parameter_count(stmt.pointer);
829-
if (params != vals.length) {
830-
throw new SQLException("assertion failure: param count (" + params + ") != value count (" + vals.length
829+
if (params > vals.length) {
830+
throw new SQLException("assertion failure: param count (" + params + ") > value count (" + vals.length
831831
+ ")");
832832
}
833833

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.