From b9d4df2c338530e255062599755e9c7b99bd14a7 Mon Sep 17 00:00:00 2001 From: Rob Browning Date: Mon, 7 Apr 2003 01:49:04 +0000 Subject: [PATCH] * strings.c (scm_mem2string): use memcpy rather than by-hand loop. Thanks to Dale P. Smith. --- libguile/strings.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libguile/strings.c b/libguile/strings.c index ac5cfd239..d38959413 100644 --- a/libguile/strings.c +++ b/libguile/strings.c @@ -129,9 +129,7 @@ scm_mem2string (const char *src, size_t len) { SCM s = scm_allocate_string (len); char *dst = SCM_STRING_CHARS (s); - - while (len--) - *dst++ = *src++; + memcpy (dst, src, len); return s; }