summaryrefslogtreecommitdiffhomepage
path: root/src/external/tinyobj_loader_c.h
diff options
context:
space:
mode:
authorSuperUserNameMan <[email protected]>2023-10-27 17:13:10 +0200
committerGitHub <[email protected]>2023-10-27 17:13:10 +0200
commitb46505b13d4a85e26d1d5b6f9fc2a4264bf8b02f (patch)
tree4fd6ceeaf38c9a66a0dd83169f7efe8c5bfadf94 /src/external/tinyobj_loader_c.h
parent2db7c727b653fc526b7da07fd337de02b7156e37 (diff)
downloadraylib-b46505b13d4a85e26d1d5b6f9fc2a4264bf8b02f.tar.gz
raylib-b46505b13d4a85e26d1d5b6f9fc2a4264bf8b02f.zip
Update tinyobj_loader_c.h (#3474)
temporary quickfix for issue #3473
Diffstat (limited to 'src/external/tinyobj_loader_c.h')
-rw-r--r--src/external/tinyobj_loader_c.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/external/tinyobj_loader_c.h b/src/external/tinyobj_loader_c.h
index 502a55a7..55d595a6 100644
--- a/src/external/tinyobj_loader_c.h
+++ b/src/external/tinyobj_loader_c.h
@@ -1269,6 +1269,11 @@ int tinyobj_parse_obj(tinyobj_attrib_t *attrib, tinyobj_shape_t **shapes,
if (is_line_ending(buf, i, end_idx)) {
line_infos[line_no].pos = prev_pos;
line_infos[line_no].len = i - prev_pos;
+
+// ---- QUICK BUG FIX : https://github.com/raysan5/raylib/issues/3473
+ if ( i > 0 && buf[i-1] == '\r' ) line_infos[line_no].len--;
+// --------
+
prev_pos = i + 1;
line_no++;
}