[js] flags field is not initialized by tstr_cat
[js] eval: avoid NULL pointer dereference