diff options
author | Richard M. Stallman <rms@gnu.org> | 1993-08-10 21:16:01 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1993-08-10 21:16:01 +0000 |
commit | abfc2e5fd21a2f8430fff7af6b9481a0a9a8a0db (patch) | |
tree | fc7c29d3ebf64587020168e9cc229a4b1e0a9276 /src/xrdb.c | |
parent | b3bf02fa6141fefc4238fc6a6dd45063a8751d45 (diff) | |
download | emacs-abfc2e5fd21a2f8430fff7af6b9481a0a9a8a0db.tar.gz |
(x_get_customization_string): Don't use value of strcpy.
Diffstat (limited to 'src/xrdb.c')
-rw-r--r-- | src/xrdb.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/xrdb.c b/src/xrdb.c index ea0cbc89b31..b1a8a9ce6a2 100644 --- a/src/xrdb.c +++ b/src/xrdb.c @@ -113,7 +113,11 @@ x_get_customization_string (db, name, class) result = x_get_string_resource (db, full_name, full_class); if (result) - return strcpy ((char *) malloc (strlen (result) + 1), result); + { + char *copy = (char *) malloc (strlen (result) + 1); + strcpy (copy, result); + return copy; + } else return 0; } |