Skip to content

Commit 14c8500

Browse files
author
rodolpheh
committed
Enforce null-terminated url for Wget
1 parent f08cecd commit 14c8500

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/zemscripten.zig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ pub fn log(
202202
extern fn emscripten_wget(url: [*c]const u8, file: [*c]const u8) c_int;
203203
extern fn emscripten_wget_data(url: [*c]const u8, pbuffer: **anyopaque, pnum: *c_int, perror: *c_int) void;
204204

205-
pub fn Wget(url: []const u8, file: []const u8) c_int {
205+
pub fn Wget(url: [:0]const u8, file: [:0]const u8) c_int {
206206
return emscripten_wget(url.ptr, file.ptr);
207207
}
208208

0 commit comments

Comments
 (0)