[PATCH libX11 2/4] XStringToKeysym: Special case for XF86 keysyms
Keith Packard
keithp at keithp.com
Thu Jul 8 11:20:46 PDT 2010
On Thu, 8 Jul 2010 16:50:48 +0100, Daniel Stone <daniel at fooishbar.org> wrote:
> Jesus, how embarassment. Is the following OK?
Yup, looks good.
> @@ -159,6 +159,8 @@ XStringToKeysym(_Xconst char *s)
> if (strncmp(s, "XF86_", 5) == 0) {
> KeySym ret;
> char *tmp = strdup(s);
> + if (!tmp)
> + return NoSymbol;
> memmove(&tmp[4], &tmp[5], strlen(s) - 5 + 1);
> ret = XStringToKeysym(tmp);
> free(tmp);
--
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20100708/412b08bd/attachment.pgp>
More information about the xorg-devel
mailing list