update emoji autocorrect entries from po-files
[LibreOffice.git] / external / liblangtag / liblangtag-0.5.1-vsnprintf.patch
blob599c47f9ae52426fde125493e912fe8715ccba84
1 diff -ru UnpackedTarball/orig.langtag/liblangtag/lt-utils.c UnpackedTarball/langtag/liblangtag/lt-utils.c
2 --- UnpackedTarball/orig.langtag/liblangtag/lt-utils.c 2013-07-19 16:47:20.310734230 +0200
3 +++ UnpackedTarball/langtag/liblangtag/lt-utils.c 2013-07-19 16:53:10.839914271 +0200
4 @@ -173,9 +173,11 @@
6 va_end(ap);
8 - retval = malloc(sizeof (char) * size);
9 - if (retval) {
10 - vsprintf(retval, format, args);
11 + if (size > 0) {
12 + retval = malloc(sizeof (char) * size);
13 + if (retval) {
14 + vsprintf(retval, format, args);
15 + }
17 } LT_STMT_END;
18 #elif HAVE_VSNPRINTF