async: adjust implementation for xev version bump

This commit is contained in:
Tarry Singh 2024-09-06 16:00:58 +00:00
parent 4b7e618b43
commit 7e0fcecfc9

View File

@ -78,7 +78,7 @@ pub fn sleep(exec: *Executor, ms: u64) !void {
const Data = XCallback(SleepResult);
var data = Data.init();
const w = try xev.Timer.init();
var w = try xev.Timer.init();
defer w.deinit();
var c: xev.Completion = .{};
w.run(loop, &c, ms, Data, &data, &Data.callback);
@ -129,7 +129,7 @@ pub const TCP = struct {
}
pub fn accept(self: Self) !Self {
const AcceptResult = xev.TCP.AcceptError!xev.TCP;
const AcceptResult = xev.AcceptError!xev.TCP;
const Data = XCallback(AcceptResult);
const loop = self.exec.loop;