mirror of
https://github.com/raysan5/raylib.git
synced 2025-11-15 06:48:40 +00:00
Protect TextIsEqual from NULLs (#2121)
This commit is contained in:
@@ -1142,6 +1142,10 @@ bool TextIsEqual(const char *text1, const char *text2)
|
|||||||
{
|
{
|
||||||
bool result = false;
|
bool result = false;
|
||||||
|
|
||||||
|
if (text1 == NULL || text2 == NULL) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (strcmp(text1, text2) == 0) result = true;
|
if (strcmp(text1, text2) == 0) result = true;
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
Reference in New Issue
Block a user