diff options
author | Dodji Seketeli <dodji@seketeli.org> | 2007-08-30 22:31:47 +0200 |
---|---|---|
committer | Dodji Seketeli <dodji@openedhand.com> | 2007-10-02 16:55:15 +0200 |
commit | 8c78df0ea36abc7d46c4f59670289f4280f75507 (patch) | |
tree | 9ce7e55366a669b2f5e924bb4f869642b452be1c | |
parent | 024abe825cd702334266f6b8da289907bbd05970 (diff) |
Xserver: fix potential crash
* dix/extension.c:
(AddExtensionAlias): don't crash when failed to add
extension alias.
-rw-r--r-- | dix/extension.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/dix/extension.c b/dix/extension.c index 186574d76..4c0c3d236 100644 --- a/dix/extension.c +++ b/dix/extension.c @@ -184,6 +184,8 @@ _X_EXPORT Bool AddExtensionAlias(char *alias, ExtensionEntry *ext) char *name; char **aliases; + if (!ext) + return FALSE ; aliases = (char **)xrealloc(ext->aliases, (ext->num_aliases + 1) * sizeof(char *)); if (!aliases) |