mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-04-01 18:06:46 +00:00
use arena_pool for cache get
This commit is contained in:
@@ -31,6 +31,7 @@ const RobotStore = @import("Robots.zig").RobotStore;
|
||||
const WebBotAuth = @import("WebBotAuth.zig");
|
||||
const Cache = @import("cache/Cache.zig");
|
||||
|
||||
const App = @import("../App.zig");
|
||||
const Runtime = @This();
|
||||
|
||||
const Listener = struct {
|
||||
@@ -46,6 +47,7 @@ const MAX_TICK_CALLBACKS = 16;
|
||||
|
||||
allocator: Allocator,
|
||||
|
||||
app: *App,
|
||||
config: *const Config,
|
||||
ca_blob: ?net_http.Blob,
|
||||
robot_store: RobotStore,
|
||||
@@ -202,7 +204,7 @@ fn globalDeinit() void {
|
||||
libcurl.curl_global_cleanup();
|
||||
}
|
||||
|
||||
pub fn init(allocator: Allocator, config: *const Config) !Runtime {
|
||||
pub fn init(allocator: Allocator, app: *App, config: *const Config) !Runtime {
|
||||
globalInit(allocator);
|
||||
errdefer globalDeinit();
|
||||
|
||||
@@ -251,6 +253,7 @@ pub fn init(allocator: Allocator, config: *const Config) !Runtime {
|
||||
.available = available,
|
||||
.connections = connections,
|
||||
|
||||
.app = app,
|
||||
.robot_store = RobotStore.init(allocator),
|
||||
.web_bot_auth = web_bot_auth,
|
||||
.cache = cache,
|
||||
|
||||
Reference in New Issue
Block a user