When trying to render an empty string via gdImageStringFT(), the function fails as of libgd 2.3.0, while formerly it was just a no-op.
Test script
#include <stdio.h>
#include <gd.h>
int main()
{
gdImagePtr im;
int fg;
int rect[8];
char *res;
im = gdImageCreate(100, 100);
fg = gdImageColorAllocate(im, 255, 255, 255);
res = gdImageStringFT(im, rect, fg, "/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf", 12, 0, 10, 10, "");
if (res) printf("%s\n", res);
return 0;
}
Expected output
Actual output
Problem doing text layout
When trying to render an empty string via
gdImageStringFT(), the function fails as of libgd 2.3.0, while formerly it was just a no-op.Test script
Expected output
Actual output