summaryrefslogtreecommitdiff
path: root/vtab.zig
diff options
context:
space:
mode:
Diffstat (limited to 'vtab.zig')
-rw-r--r--vtab.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/vtab.zig b/vtab.zig
index 77a9839..53e46c1 100644
--- a/vtab.zig
+++ b/vtab.zig
@@ -32,7 +32,7 @@ pub const ModuleContext = struct {
32 allocator: mem.Allocator, 32 allocator: mem.Allocator,
33}; 33};
34 34
35fn dupeToSQLiteString(s: []const u8) [*c]const u8 { 35fn dupeToSQLiteString(s: []const u8) [*c]u8 {
36 var buffer: [*c]u8 = @ptrCast(c.sqlite3_malloc(@intCast(s.len + 1))); 36 var buffer: [*c]u8 = @ptrCast(c.sqlite3_malloc(@intCast(s.len + 1)));
37 37
38 mem.copyForwards(u8, buffer[0..s.len], s); 38 mem.copyForwards(u8, buffer[0..s.len], s);
@@ -730,7 +730,7 @@ pub fn VirtualTable(
730 return c.SQLITE_ERROR; 730 return c.SQLITE_ERROR;
731 } 731 }
732 732
733 fn xConnect(db: ?*c.sqlite3, module_context_ptr: ?*anyopaque, argc: c_int, argv: [*c]const [*c]const u8, vtab: [*c][*c]c.sqlite3_vtab, err_str: [*c][*c]const u8) callconv(.C) c_int { 733 fn xConnect(db: ?*c.sqlite3, module_context_ptr: ?*anyopaque, argc: c_int, argv: [*c]const [*c]const u8, vtab: [*c][*c]c.sqlite3_vtab, err_str: [*c][*c]u8) callconv(.C) c_int {
734 const module_context = getModuleContext(module_context_ptr); 734 const module_context = getModuleContext(module_context_ptr);
735 735
736 var arena = heap.ArenaAllocator.init(module_context.allocator); 736 var arena = heap.ArenaAllocator.init(module_context.allocator);