diff options
| author | 2022-10-31 15:53:27 -0700 | |
|---|---|---|
| committer | 2022-11-01 02:26:14 +0100 | |
| commit | 32e8023978af198040d9053e97127d3d0bb5d99f (patch) | |
| tree | 3293235f07a79a2b84f8a5ca133ee9b182c408fc /sqlite.zig | |
| parent | vtab: fix tests when using a db file instead of in memory (diff) | |
| download | zig-sqlite-32e8023978af198040d9053e97127d3d0bb5d99f.tar.gz zig-sqlite-32e8023978af198040d9053e97127d3d0bb5d99f.tar.xz zig-sqlite-32e8023978af198040d9053e97127d3d0bb5d99f.zip | |
Fix compile error with Zig 0.10.0
Fixes the following error:
```
sqlite.zig:343:50: error: expected type '[*c]const u8', found '[:0]const u8'
const result = c.sqlite3_open_v2(path, &db, flags, null);
^~~~
```
Diffstat (limited to '')
| -rw-r--r-- | sqlite.zig | 2 |
1 files changed, 1 insertions, 1 deletions
| @@ -340,7 +340,7 @@ pub const Db = struct { | |||
| 340 | switch (options.mode) { | 340 | switch (options.mode) { |
| 341 | .File => |path| { | 341 | .File => |path| { |
| 342 | var db: ?*c.sqlite3 = undefined; | 342 | var db: ?*c.sqlite3 = undefined; |
| 343 | const result = c.sqlite3_open_v2(path, &db, flags, null); | 343 | const result = c.sqlite3_open_v2(path.ptr, &db, flags, null); |
| 344 | if (result != c.SQLITE_OK or db == null) { | 344 | if (result != c.SQLITE_OK or db == null) { |
| 345 | if (db) |v| { | 345 | if (db) |v| { |
| 346 | diags.err = getLastDetailedErrorFromDb(v); | 346 | diags.err = getLastDetailedErrorFromDb(v); |