| ... | ... | @@ -393,15 +393,19 @@ fn openSelfDebugInfoWindows(allocator: *mem.Allocator) !DebugInfo { |
| 393 | 393 | |
| 394 | 394 | try coff_file.loadHeader(); |
| 395 | 395 | |
| 396 | | var path: [windows.MAX_PATH]u8 = undefined; |
| 397 | | const len = try coff_file.getPdbPath(path[0..]); |
| 398 | | std.debug.warn("pdb path {}\n", path[0..len]); |
| 396 | var path_buf: [windows.MAX_PATH]u8 = undefined; |
| 397 | const len = try coff_file.getPdbPath(path_buf[0..]); |
| 398 | const raw_path = path_buf[0..len]; |
| 399 | std.debug.warn("pdb raw path {}\n", raw_path); |
| 400 | |
| 401 | const path = try os.path.resolve(allocator, raw_path); |
| 402 | std.debug.warn("pdb resolved path {}\n", path); |
| 399 | 403 | |
| 400 | 404 | var di = DebugInfo{ |
| 401 | 405 | .pdb = undefined, |
| 402 | 406 | }; |
| 403 | 407 | |
| 404 | | try di.pdb.openFile(allocator, path[0..len]); |
| 408 | try di.pdb.openFile(allocator, path); |
| 405 | 409 | |
| 406 | 410 | var pdb_stream = di.pdb.getStream(pdb.StreamType.Pdb) orelse return error.InvalidDebugInfo; |
| 407 | 411 | std.debug.warn("pdb real filepos {}\n", pdb_stream.getFilePos()); |