Option: fix a possible null reference segfault

This commit is contained in:
李通洲
2025-08-01 16:05:18 +08:00
parent 4f8d8de749
commit ba3e26f2b4
+1 -1
View File
@@ -157,7 +157,7 @@ bool ffOptionParseBoolean(const char* str)
void ffOptionParseColorNoClear(const char* value, FFstrbuf* buffer)
{
if (value[0] == '\0') return;
if (!value || value[0] == '\0') return;
// If value is already an ANSI escape code, use it
if (value[0] == '\e' && value[1] == '[')