shaper: fix reallocation

Update the variable that tracks the allocated size. This potentially
improves performance and avoid some side effects, which lead to
undefined behavior in some cases.

Fixes fuzzer test case id:000051,sig:11,sync:fuzzer3,src:004221.
hb_shaper_get_run_language(ASS_Shaper *shaper, hb_script_t script)
{
    hb_language_t lang;

    if (shaper->language != HB_LANGUAGE_INVALID)
        return shaper->language;

    lang = script_to_language(script);

    if (lang == HB_LANGUAGE_INVALID)
        lang = hb_language_get_default();

    return lang;
}

hb_shaper_get_run_language(ASS_Shaper *shaper, hb_script_t script)
{
    hb_language_t lang;

    if (shaper->language != HB_LANGUAGE_INVALID)
        return shaper->language;

    lang = script_to_language(script);

    if (lang == HB_LANGUAGE_INVALID)
        lang = hb_language_get_default();

    return lang;
}
