summaryrefslogtreecommitdiff
path: root/external
diff options
context:
space:
mode:
authorZolnai Tamás <tamas.zolnai@collabora.com>2014-04-18 15:12:09 +0200
committerZolnai Tamás <tamas.zolnai@collabora.com>2014-04-18 18:53:21 +0200
commit9cf12d7544d501e6794cfbb6eabf508603d59966 (patch)
treec6325ef990b93f8b1bff5e64c39e2b6e67e10302 /external
parentaee75b57f042159d7a82734595cdce5a7903431b (diff)
Patching libgltf: character buffer is used as cstring
Change-Id: If0213fc5406ec9cbdc72be36ffc693fcbbf8ffcc
Diffstat (limited to 'external')
-rw-r--r--external/libgltf/UnpackedTarball_libgltf.mk1
-rw-r--r--external/libgltf/patches/charbuffer_used_as_cstring.patch12
2 files changed, 13 insertions, 0 deletions
diff --git a/external/libgltf/UnpackedTarball_libgltf.mk b/external/libgltf/UnpackedTarball_libgltf.mk
index 1fbe09d2c992..e83486d837b9 100644
--- a/external/libgltf/UnpackedTarball_libgltf.mk
+++ b/external/libgltf/UnpackedTarball_libgltf.mk
@@ -24,6 +24,7 @@ $(eval $(call gb_UnpackedTarball_add_patches,libgltf,\
external/libgltf/patches/include_typo_texture.patch \
external/libgltf/patches/adress_of_temporary.patch \
external/libgltf/patches/avoid_c++11.patch \
+ external/libgltf/patches/charbuffer_used_as_cstring.patch \
))
# vim: set noet sw=4 ts=4:
diff --git a/external/libgltf/patches/charbuffer_used_as_cstring.patch b/external/libgltf/patches/charbuffer_used_as_cstring.patch
new file mode 100644
index 000000000000..58f57017495a
--- /dev/null
+++ b/external/libgltf/patches/charbuffer_used_as_cstring.patch
@@ -0,0 +1,12 @@
+diff -ur libgltf.org/src/RenderScene.cpp libgltf/src/RenderScene.cpp
+--- libgltf.org/src/RenderScene.cpp 2014-04-18 13:52:31.148772285 +0200
++++ libgltf/src/RenderScene.cpp 2014-04-18 15:08:15.001604707 +0200
+@@ -211,7 +211,7 @@
+ {
+ if(0 == jsonfile)
+ return 0;
+- string tmpStr(jsonfile->buffer);
++ string tmpStr(jsonfile->buffer,jsonfile->size);
+ loadJson.setJsonInfo(tmpStr);
+ if (!loadJson.parseJsonFile())
+ return 0;