The program crashes when trying to determine slice width/height if the light texture is empty. This fix just returns an empty array, as if the light texture does not exist.
char_utils.h