diff options
| author | Paul Eggert <eggert@cs.ucla.edu> | 2012-07-10 14:48:34 -0700 |
|---|---|---|
| committer | Paul Eggert <eggert@cs.ucla.edu> | 2012-07-10 14:48:34 -0700 |
| commit | e99a530f8cdca3ccd9e739cd092ed9865d12fe89 (patch) | |
| tree | c2bef9f80ff9910be17757a83f61caed02146d0a /src/gtkutil.c | |
| parent | c59592b32f5b5808c12720bfd37ea73b473fa1db (diff) | |
| download | emacs-e99a530f8cdca3ccd9e739cd092ed9865d12fe89.tar.gz | |
Simplify by avoiding confusing use of strncpy etc.
Diffstat (limited to 'src/gtkutil.c')
| -rw-r--r-- | src/gtkutil.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gtkutil.c b/src/gtkutil.c index f4551b4b9f7..290ecef9216 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c @@ -529,7 +529,7 @@ get_utf8_string (const char *str) &bytes_written, &err)) && err->code == G_CONVERT_ERROR_ILLEGAL_SEQUENCE) { - strncpy (up, (char *)p, bytes_written); + memcpy (up, p, bytes_written); sprintf (up + bytes_written, "\\%03o", p[bytes_written]); up += bytes_written+4; p += bytes_written+1; |
