[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/src/fns.c
From: |
Jan Djärv |
Subject: |
[Emacs-diffs] Changes to emacs/src/fns.c |
Date: |
Thu, 17 Jun 2004 13:43:11 -0400 |
Index: emacs/src/fns.c
diff -c emacs/src/fns.c:1.363 emacs/src/fns.c:1.364
*** emacs/src/fns.c:1.363 Mon May 10 03:56:43 2004
--- emacs/src/fns.c Thu Jun 17 14:37:53 2004
***************
*** 1049,1064 ****
Lisp_Object string;
{
unsigned char *buf;
if (! STRING_MULTIBYTE (string))
return string;
! buf = (unsigned char *) alloca (SCHARS (string));
copy_text (SDATA (string), buf, SBYTES (string),
1, 0);
! return make_unibyte_string (buf, SCHARS (string));
}
DEFUN ("string-make-multibyte", Fstring_make_multibyte,
Sstring_make_multibyte,
--- 1049,1072 ----
Lisp_Object string;
{
unsigned char *buf;
+ Lisp_Object ret;
if (! STRING_MULTIBYTE (string))
return string;
! /* We can not use alloca here, because string might be very long.
! For example when selecting megabytes of text and then pasting it to
! another application. */
! buf = (unsigned char *) xmalloc (SCHARS (string));
copy_text (SDATA (string), buf, SBYTES (string),
1, 0);
! ret = make_unibyte_string (buf, SCHARS (string));
!
! xfree (buf);
!
! return ret;
}
DEFUN ("string-make-multibyte", Fstring_make_multibyte,
Sstring_make_multibyte,
- [Emacs-diffs] Changes to emacs/src/fns.c,
Jan Djärv <=
- [Emacs-diffs] Changes to emacs/src/fns.c, Kim F . Storm, 2004/06/21
- [Emacs-diffs] Changes to emacs/src/fns.c, Kim F . Storm, 2004/06/21
- [Emacs-diffs] Changes to emacs/src/fns.c, Kim F . Storm, 2004/06/22
- [Emacs-diffs] Changes to emacs/src/fns.c, Kim F . Storm, 2004/06/22
- [Emacs-diffs] Changes to emacs/src/fns.c, Kim F . Storm, 2004/06/24