xkb: ddxLoad: don't crash the server when strcpy() fails

No need for RunXkbComp() to hard-crash (by calling XNFstrdup()) the server
if strdup() fails to allocate more memory - it's callers already handling
the situation gracefully.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult 2025-02-28 16:50:43 +01:00
parent ff6ee89494
commit 1bac33b0da

View File

@ -194,7 +194,7 @@ RunXkbComp(xkbcomp_buffer_callback callback, void *userdata)
#ifdef WIN32
unlink(tmpname);
#endif
return XNFstrdup(keymap);
return strdup(keymap);
}
else {
LogMessage(X_ERROR, "Error compiling keymap (%s) executing '%s'\n",