duckdb 0.3.3-dev579.0 → 0.3.3-dev581.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "duckdb",
3
3
  "main": "./lib/duckdb.js",
4
- "version": "0.3.3-dev579.0",
4
+ "version": "0.3.3-dev581.0",
5
5
  "description": "DuckDB node.js API",
6
6
  "gypfile": true,
7
7
  "dependencies": {
package/src/duckdb.cpp CHANGED
@@ -227336,6 +227336,7 @@ size_t Utf8Proc::RenderWidth(const char *s, size_t len, size_t pos) {
227336
227336
 
227337
227337
 
227338
227338
  #include <stdlib.h>
227339
+ #include <string>
227339
227340
 
227340
227341
 
227341
227342
 
@@ -227348,7 +227349,7 @@ typedef struct parse_result_str parse_result;
227348
227349
  struct parse_result_str {
227349
227350
  bool success;
227350
227351
  PGList *parse_tree;
227351
- char *error_message;
227352
+ std::string error_message;
227352
227353
  int error_location;
227353
227354
  };
227354
227355
 
@@ -227429,6 +227430,7 @@ static void allocate_new(parser_state *state, size_t n) {
227429
227430
  if (state->malloc_ptr_idx >= state->malloc_ptr_size) {
227430
227431
  size_t new_size = state->malloc_ptr_size * 2;
227431
227432
  auto new_malloc_ptrs = (char **) malloc(sizeof(char *) * new_size);
227433
+ memset(new_malloc_ptrs, 0, sizeof(char*) * new_size);
227432
227434
  memcpy(new_malloc_ptrs, state->malloc_ptrs, state->malloc_ptr_size * sizeof(char*));
227433
227435
  free(state->malloc_ptrs);
227434
227436
  state->malloc_ptr_size = new_size;
@@ -227470,6 +227472,7 @@ void pg_parser_init() {
227470
227472
 
227471
227473
  pg_parser_state.malloc_ptr_size = 4;
227472
227474
  pg_parser_state.malloc_ptrs = (char **) malloc(sizeof(char *) * pg_parser_state.malloc_ptr_size);
227475
+ memset(pg_parser_state.malloc_ptrs, 0, sizeof(char*) * pg_parser_state.malloc_ptr_size);
227473
227476
  pg_parser_state.malloc_ptr_idx = 0;
227474
227477
  allocate_new(&pg_parser_state, 1);
227475
227478
  }
@@ -227481,14 +227484,7 @@ void pg_parser_parse(const char *query, parse_result *res) {
227481
227484
  res->success = pg_parser_state.pg_err_code == PGUNDEFINED;
227482
227485
  } catch (std::exception &ex) {
227483
227486
  res->success = false;
227484
- // copy the error message of the exception
227485
- auto error_message = ex.what();
227486
- uint32_t pos = 0;
227487
- while(pos < 1023 && error_message[pos]) {
227488
- pg_parser_state.pg_err_msg[pos] = error_message[pos];
227489
- pos++;
227490
- }
227491
- pg_parser_state.pg_err_msg[pos] = '\0';
227487
+ res->error_message = ex.what();
227492
227488
  }
227493
227489
  res->error_message = pg_parser_state.pg_err_msg;
227494
227490
  res->error_location = pg_parser_state.pg_err_pos;
package/src/duckdb.hpp CHANGED
@@ -11,8 +11,8 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
11
11
  #pragma once
12
12
  #define DUCKDB_AMALGAMATION 1
13
13
  #define DUCKDB_AMALGAMATION_EXTENDED 1
14
- #define DUCKDB_SOURCE_ID "517c5e9de"
15
- #define DUCKDB_VERSION "v0.3.3-dev579"
14
+ #define DUCKDB_SOURCE_ID "818903e44"
15
+ #define DUCKDB_VERSION "v0.3.3-dev581"
16
16
  //===----------------------------------------------------------------------===//
17
17
  // DuckDB
18
18
  //