# HG changeset patch # User ben # Date 1021389368 0 # Node ID 44478bd99873323533a6e3a45f2c920f66ac8bb9 # Parent 1e4e42de23d5619b12141263531a6f83d90d4d6b [xemacs-hg @ 2002-05-14 15:15:58 by ben] crash fixes text.c: Fix bug leading to crashes with multibyte text. win32.c: Fix crash due to errant xfree(). xemacs.mak: Run tests with the packages so we don't get errors about advice not present, etc. diff -r 1e4e42de23d5 -r 44478bd99873 nt/ChangeLog --- a/nt/ChangeLog Tue May 14 13:04:00 2002 +0000 +++ b/nt/ChangeLog Tue May 14 15:16:08 2002 +0000 @@ -1,3 +1,10 @@ +2002-05-14 Ben Wing + + * xemacs.mak (batch_test_emacs): + * xemacs.mak (check): + Run tests with the packages so we don't get errors about + advice not present, etc. + 2002-05-14 Ben Wing * xemacs.mak (CONFIG_VALUES): diff -r 1e4e42de23d5 -r 44478bd99873 nt/xemacs.mak --- a/nt/xemacs.mak Tue May 14 13:04:00 2002 +0000 +++ b/nt/xemacs.mak Tue May 14 15:16:08 2002 +0000 @@ -957,7 +957,7 @@ run_temacs = $(temacs_loadup) run-temacs ## We have automated tests!! testdir=../tests/automated -batch_test_emacs=$(BATCH) -l $(testdir)/test-harness.el -f batch-test-emacs $(testdir) +batch_test_emacs=$(BATCH_PACKAGES) -l $(testdir)/test-harness.el -f batch-test-emacs $(testdir) # .PHONY: check check-temacs diff -r 1e4e42de23d5 -r 44478bd99873 src/ChangeLog --- a/src/ChangeLog Tue May 14 13:04:00 2002 +0000 +++ b/src/ChangeLog Tue May 14 15:16:08 2002 +0000 @@ -1,3 +1,10 @@ +2002-05-14 Ben Wing + + * text.c (copy_buffer_text_out): Fix bug leading to crashes + with multibyte text. + * win32.c (Fmswindows_shell_execute): Fix crash due to errant + xfree(). + 2002-05-14 Ben Wing * callproc.c (Fold_call_process_internal): diff -r 1e4e42de23d5 -r 44478bd99873 src/text.c --- a/src/text.c Tue May 14 13:04:00 2002 +0000 +++ b/src/text.c Tue May 14 15:16:08 2002 +0000 @@ -1189,7 +1189,16 @@ { dst += the_dst_used; dstlen -= the_dst_used; - if (!dstlen) + /* Stop if we didn't use all of the source text. Also stop + if the destination is full. We need the first test because + there might be a couple bytes left in the destination, but + not enough to fit a full character. The first test will in + fact catch the vast majority of cases where the destination + is empty, too -- but in case the destination holds *exactly* + the run length, we put in the second check. (It shouldn't + really matter though -- next time through we'll just get a + 0.) */ + if (the_src_used < runlen || !dstlen) break; } } diff -r 1e4e42de23d5 -r 44478bd99873 src/win32.c --- a/src/win32.c Tue May 14 13:04:00 2002 +0000 +++ b/src/win32.c Tue May 14 15:16:08 2002 +0000 @@ -338,8 +338,6 @@ ret = (int) qxeShellExecute (NULL, opext, doc, parmext, path, (INTP (show_flag) ? XINT (show_flag) : SW_SHOWDEFAULT)); - - xfree (doc); } if (ret <= 32)