aboutsummaryrefslogtreecommitdiffstats
path: root/facebook/facebook-api.c
diff options
context:
space:
mode:
authorjgeboski <jgeboski@gmail.com>2015-12-20 20:26:24 -0500
committerjgeboski <jgeboski@gmail.com>2015-12-20 20:26:24 -0500
commit28ec26e7ca9b1909c65939cea7f55fc72c55ed9c (patch)
treec4a5345d6990f46cd437aff235e26bc200538d0f /facebook/facebook-api.c
parent00c0ae832b2f04969d205b951ae37b9bc884b84f (diff)
downloadbitlbee-facebook-28ec26e7ca9b1909c65939cea7f55fc72c55ed9c.tar.gz
bitlbee-facebook-28ec26e7ca9b1909c65939cea7f55fc72c55ed9c.tar.bz2
bitlbee-facebook-28ec26e7ca9b1909c65939cea7f55fc72c55ed9c.tar.xz
facebook-json: fixed a size overflow with string duplication
Unlike json_parser_load_from_data(), g_strndup() will not handle signed sizes that are negative. This causes the size to overflow to a really large value, and in turn lead to a segmentation fault. The solution is simple: calculate the size of the data when the given size is negative. This bug was introduced by 0121bae.
Diffstat (limited to 'facebook/facebook-api.c')
0 files changed, 0 insertions, 0 deletions