| ... | @@ -1306,15 +1306,15 @@ fn initResource(f: *Fetch, uri: std.Uri, resource: *Resource, reader_buffer: []u | ... | @@ -1306,15 +1306,15 @@ fn initResource(f: *Fetch, uri: std.Uri, resource: *Resource, reader_buffer: []u |
| 1306 | return error.FetchFailed; | 1306 | return error.FetchFailed; |
| 1307 | } | 1307 | } |
| 1308 | | 1308 | |
| 1309 | var want_oid_buf: [git.Oid.max_formatted_length]u8 = undefined; | 1309 | var want_oid_hex_buf: [git.Oid.max_formatted_length]u8 = undefined; |
| 1310 | _ = std.fmt.bufPrint(&want_oid_buf, "{f}", .{want_oid}) catch unreachable; | 1310 | const want_oid_hex = std.mem.print(&want_oid_hex_buf, "{f}", .{want_oid}) catch unreachable; |
| 1311 | resource.* = .{ .git = .{ | 1311 | resource.* = .{ .git = .{ |
| 1312 | .session = session, | 1312 | .session = session, |
| 1313 | .fetch_stream = undefined, | 1313 | .fetch_stream = undefined, |
| 1314 | .want_oid = want_oid, | 1314 | .want_oid = want_oid, |
| 1315 | } }; | 1315 | } }; |
| 1316 | const fetch_stream = &resource.git.fetch_stream; | 1316 | const fetch_stream = &resource.git.fetch_stream; |
| 1317 | session.fetch(fetch_stream, &.{&want_oid_buf}, reader_buffer) catch |err| { | 1317 | session.fetch(fetch_stream, &.{want_oid_hex}, reader_buffer) catch |err| { |
| 1318 | return f.fail(f.location_tok, try eb.printString("unable to create fetch stream: {t}", .{err})); | 1318 | return f.fail(f.location_tok, try eb.printString("unable to create fetch stream: {t}", .{err})); |
| 1319 | }; | 1319 | }; |
| 1320 | errdefer fetch_stream.deinit(fetch_stream); | 1320 | errdefer fetch_stream.deinit(fetch_stream); |