Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
b9607587
Commit
b9607587
authored
Jun 28, 2009
by
Andreas Schwab
Browse files
(send_process): Keep decoded string in a local
variable and protect it from GC. (Bug#3521)
parent
485422be
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
5 deletions
+12
-5
src/ChangeLog
src/ChangeLog
+5
-0
src/process.c
src/process.c
+7
-5
No files found.
src/ChangeLog
View file @
b9607587
2009-06-28 Andreas Schwab <schwab@linux-m68k.org>
* process.c (send_process): Keep decoded string in a local
variable and protect it from GC. (Bug#3521)
2009-06-28 Eli Zaretskii <eliz@gnu.org>
* term.c (create_tty_output) [MSDOS]: #ifdef away.
...
...
src/process.c
View file @
b9607587
...
...
@@ -5550,10 +5550,11 @@ send_process (proc, buf, len, object)
struct Lisp_Process *p = XPROCESS (proc);
int rv;
struct coding_system *coding;
struct gcpro gcpro1;
struct gcpro gcpro1
, gcpro2
;
SIGTYPE (*volatile old_sigpipe) ();
Lisp_Object dst_object = Qnil;
GCPRO
1
(object);
GCPRO
2
(object
, dst_object
);
if (p->raw_status_new)
update_status (p);
...
...
@@ -5632,7 +5633,8 @@ send_process (proc, buf, len, object)
}
len = coding->produced;
buf = SDATA (coding->dst_object);
dst_object = coding->dst_object;
buf = SDATA (dst_object);
}
if (pty_max_bytes == 0)
...
...
@@ -5764,7 +5766,7 @@ send_process (proc, buf, len, object)
/* Running filters might relocate buffers or strings.
Arrange to relocate BUF. */
if (CODING_REQUIRE_ENCODING (coding))
offset = buf - SDATA (
coding->
dst_object);
offset = buf - SDATA (dst_object);
else if (BUFFERP (object))
offset = BUF_PTR_BYTE_POS (XBUFFER (object), buf);
else if (STRINGP (object))
...
...
@@ -5777,7 +5779,7 @@ send_process (proc, buf, len, object)
#endif
if (CODING_REQUIRE_ENCODING (coding))
buf = offset + SDATA (
coding->
dst_object);
buf = offset + SDATA (dst_object);
else if (BUFFERP (object))
buf = BUF_BYTE_ADDRESS (XBUFFER (object), offset);
else if (STRINGP (object))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment