Fix image loading bug on some system