diff options
author | Mikhail Gusarov <dottedmag@dottedmag.net> | 2010-06-04 16:58:58 +0700 |
---|---|---|
committer | Mikhail Gusarov <dottedmag@dottedmag.net> | 2010-06-11 19:04:23 +0700 |
commit | 6592db6bb526f0c43b4c7b55859c629709e039b4 (patch) | |
tree | 30d525b635170a94193c0a8837e1b36b609e757e /glx/glxcmds.c | |
parent | 620ca54aaa0b363fcf68cec1bd6c37e68c988352 (diff) |
Get rid of xstrdup when argument is definitely non-NULL
Replace xstrdup with strdup when either constant string is
being duplicated or argument is guarded by conditionals and
obviously can't be NULL
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Diffstat (limited to 'glx/glxcmds.c')
-rw-r--r-- | glx/glxcmds.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/glx/glxcmds.c b/glx/glxcmds.c index 1d3be4921..9e5b2139e 100644 --- a/glx/glxcmds.c +++ b/glx/glxcmds.c @@ -2433,7 +2433,7 @@ int __glXDisp_ClientInfo(__GLXclientState *cl, GLbyte *pc) cl->GLClientminorVersion = req->minor; free(cl->GLClientextensions); buf = (const char *)(req+1); - cl->GLClientextensions = xstrdup(buf); + cl->GLClientextensions = strdup(buf); return Success; } |