diff options
| author | patrick-scho | 2025-06-30 16:02:41 +0200 |
|---|---|---|
| committer | patrick-scho | 2025-06-30 16:02:41 +0200 |
| commit | a6cb28b75fa1b2ea5547000baba2a6fac9f6a37c (patch) | |
| tree | b851e33f26722169fde8b96a62e237927995b893 | |
| parent | 2a647357d4fd2561c7d30fa960c4370d725e9068 (diff) | |
| download | zigws-main.tar.gz zigws-main.zip | |
| -rw-r--r-- | ws_epoll.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ws_epoll.zig b/ws_epoll.zig index 6973093..b86237d 100644 --- a/ws_epoll.zig +++ b/ws_epoll.zig @@ -6,7 +6,7 @@ const echo = std.debug.print; const html = \\<script> - \\let s = new WebSocket("ws://localhost:8080/"); + \\let s = new WebSocket("wss://" + window.location.hostname + ":8443"); \\s.addEventListener("open", (event) => { \\ console.log("connected"); \\ s.send("Hello Server!"); @@ -145,7 +145,7 @@ const Client = struct { }; pub fn main() !void { - const address = try std.net.Address.parseIp("127.0.0.1", 8080); + const address = try std.net.Address.parseIp("127.0.0.1", 8000); const tpe: u32 = posix.SOCK.STREAM | posix.SOCK.NONBLOCK; const protocol = posix.IPPROTO.TCP; |
