1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-28 07:50:48 -08:00
Commit graph

130436 commits

Author SHA1 Message Date
Noam Postavsky
5c2da93015 Fix kill-line's docstring
* lisp/simple.el (kill-line): The effect of show-trailing-whitespace is
important lines with *no* nonblanks (Bug #16654).
2016-10-21 22:39:37 -04:00
Noam Postavsky
ad66b3fadb Fix handling of allocation in regex matching
`re_match_2_internal' uses pointers to the lisp objects that it
searches.  Since it may call malloc when growing the "fail stack", these
pointers may be invalidated while searching, resulting in memory
curruption (Bug #24358).

To fix this, we check the pointer that the lisp object (as specified by
re_match_object) points to before and after growing the stack, and
update existing pointers accordingly.

* src/regex.c (STR_BASE_PTR): New macro.
(ENSURE_FAIL_STACK, re_search_2): Use it to convert pointers into
offsets before possible malloc call, and back into pointers again
afterwards.
(POS_AS_IN_BUFFER): Add explanatory comment about punning trick.
* src/search.c (search_buffer): Instead of storing search location as
pointers, store them as pointers and recompute the corresponding address
for each call to `re_search_2'.
(string_match_1, fast_string_match_internal, fast_looking_at):
* src/dired.c (directory_files_internal): Set `re_match_object' to Qnil
after calling `re_search' or `re_match_2'.
* src/regex.h (re_match_object): Mention new usage in commentary.
2016-10-21 22:24:54 -04:00
Paul Eggert
5a26c9b0e1 * lisp/electric.el (electric-quote-mode): Improve doc (Bug#24759). 2016-10-21 14:00:44 -07:00
Paul Eggert
897998291f New error file-missing
This fixes a recently-introduced bug in delete-directory,
where the code assumes the C locale when determining
whether a file-error corresponds to a missing file (Bug#24714).
* doc/lispref/errors.texi (Standard Errors):
* doc/lispref/files.texi (Changing Files):
* etc/NEWS:
Document this.
* doc/lispref/loading.texi (How Programs Do Loading):
Say "a file-error" rather than "the error file-error" since
it might be a file-missing now.
* lisp/emacs-lisp/bytecomp.el (byte-compile-file):
* lisp/epa-file.el (epa-file--find-file-not-found-function):
(epa-file-insert-file-contents, epa-file-write-region):
* lisp/ffap.el (find-file-at-point, dired-at-point):
* lisp/jka-compr.el (jka-compr-insert-file-contents)
(jka-compr-insert-file-contents):
* lisp/net/ange-ftp.el (ange-ftp-barf-if-not-directory)
(ange-ftp-insert-file-contents, ange-ftp-copy-file-internal):
* lisp/progmodes/etags.el (visit-tags-table):
* lisp/url/url-handlers.el (url-copy-file):
* src/fileio.c (report_file_errno):
Signal file-missing if appropriate.
* lisp/epa-file.el (epa-file-insert-file-contents):
* lisp/jka-compr.el (jka-compr-insert-file-contents):
Don't assume file-error is a leaf in the error hierarchy.
* lisp/files.el (files--force):
* lisp/gnus/nnmaildir.el (nnmaildir--enoent-p):
* lisp/jka-compr.el (jka-compr-insert-file-contents):
Use file-missing to detect whether the file is missing.
* lisp/url/url-handlers.el (url-copy-file):
Signal file-already-exists if appropriate.
* src/fileio.c (syms_of_fileio): Define file-missing.

2016-10-18  Paul Eggert  <eggert@cs.ucla.edu>
2016-10-21 13:06:03 -07:00
Mark Oteiza
76b08a35bb Teach browse-url to open man page urls
* lisp/net/browse-url.el (browse-url-man-function): New custom option.
(browse-url): Add a condition to catch links matching "^man:".
(browse-url-man): New function.
2016-10-21 11:32:29 -04:00
Eli Zaretskii
0929e061fb Improve fontification of footnote references in Info buffers
* lisp/info.el (Info-fontify-node): Don't fontify random numbers
in parentheses as if they were footnote references.  See
https://lists.gnu.org/archive/html/bug-texinfo/2016-10/msg00007.html
for the details.
2016-10-21 12:59:58 +03:00
Philipp Stephani
56f8384bb3 Minor fixes to cc-mode-tests.el
See Bug#24747.

* progmodes/cc-mode-tests.el: Rename from cc-mode.el; fix typo in
file-local variable; add comments to make checkdoc happy.
2016-10-20 20:22:40 +02:00
Michael Albinus
3b83123a7f * etc/NEWS: Fix typos. Remove entries backported to Emacs 25.2. 2016-10-20 16:29:40 +02:00
Michael Albinus
ce26926b62 Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs 2016-10-20 14:58:13 +02:00
Michael Albinus
38091c9000 Document, how to suppress iTerm2 shell integration in Tramp
* doc/misc/tramp.texi (Frequently Asked Questions):
Suppress iTerm2 shell integration.
2016-10-20 14:57:17 +02:00
Tino Calancha
f63a4b82f0 cl-seq: Remove max limit on input sequence length
* lisp/emacs-lisp/cl-seq.el (cl-fill, cl-replace, cl-delete)
(cl--position, cl-nsubstitute, cl-substitute, cl-remove):
Remove limit on maximum length for the input sequence
(#Bug24264).
* test/lisp/emacs-lisp/cl-seq-tests.el: Update test expected result as passed.
2016-10-20 19:51:55 +09:00
Tino Calancha
3877c911b7 vc-region-history: Search just on lines intersecting the region
* lisp/vc/vc.el (vc-region-history): If region ends in the beginning
of a line, then exclude that line from the search (Bug#24725).
2016-10-20 19:39:59 +09:00
Mark Oteiza
10a2239627 Derive dig-mode from special-mode
* lisp/net/dig.el: Remove unused cl dependency.  Remove top level
mode-class assignment.
(dig-mode-map): Unmap g, as dig has no notion of reverting the buffer.
(dig-mode): Derive from special-mode.
(dig-exit): Use quit-window instead.
(dig): Use pop-to-buffer-same-window.  Remove redundant assignments.
(query-dig): Use pop-to-buffer-same-window.
2016-10-19 23:59:04 -04:00
Eli Zaretskii
8988327d54 Fix documentation of 'alist-get'
* doc/lispref/lists.texi (Association Lists): Fix the signature of
'alist-get'.  Fix the markup, the wording, and the punctuation in
the description. (Bug#24740)
2016-10-19 21:10:31 +03:00
Eli Zaretskii
b6998eab37 * src/regex.h (re_match_object): Improve commentary. 2016-10-19 17:31:47 +03:00
Alan Third
dfd047666b Fix cursor at bottom left of rectangle (bug#24364)
* lisp/rect.el (rectangle--col-pos): Don't assume point at EOL doesn't
require rectangle--point-crutches to be set.
2016-10-19 12:37:50 +01:00
Michael Albinus
8ad0d7da0a ; Fix quoting in etc/NEWS 2016-10-19 10:49:13 +02:00
Michael Albinus
6b9dee1ae6 Change Tramp version to "2.2.13.25.2"
* doc/misc/trampver.texi:
* lisp/net/trampver.el: Change version to "2.2.13.25.2".
2016-10-19 10:35:52 +02:00
Eli Zaretskii
62f268414c * lisp/emacs-lisp/autoload.el (update-directory-autoloads): Fix last change. 2016-10-19 10:59:05 +03:00
Eli Zaretskii
b2f32e4c9a Don't scan compiled module files for autoloads
* lisp/emacs-lisp/autoload.el (update-directory-autoloads): Ignore
compiled module files.  Make sure the extension really ends the
file name.
2016-10-19 10:42:45 +03:00
Johan Bockgård
eb610f270e cl-defstruct: Fix debug spec and check of slot options
* lisp/emacs-lisp/cl-macs.el (cl-defstruct): Improve checking of slot
option syntax.  Fix debug spec.  (Bug#24700)
2016-10-19 00:32:12 +02:00
Johan Bockgård
f52892fe01 isearch: Fix bug in defstruct syntax
* lisp/isearch.el (isearch--state): Use correct form of defstruct slot
options.  (Bug#24685)
2016-10-19 00:12:06 +02:00
Mark Oteiza
224443922c Add an option for eshell-input-filter
* etc/NEWS: Document changes.
* lisp/eshell/em-hist.el (eshell-input-filter): Set value to function
symbol.  Change type to a radio for choosing functions.  Refer to both
new functions.
(eshell-input-filter-default): New function.  Same body as the previous
value of eshell-input-filter.
(eshell-input-filter-initial-space): New function.
2016-10-18 18:05:51 -04:00
Philipp Stephani
2ce01c494d ; Fix embarassing typo 2016-10-18 21:16:55 +02:00
Michael Albinus
9a758b4ccc Fix Bug#24698
* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Don't send "stty tab0" to *BSD and Darwin machines.  (Bug#24698)
2016-10-18 20:41:19 +02:00
Paul Eggert
704fd2a7ae delete-directory no longer errors when racing
Problem reported by Glenn Morris for package-test.el (Bug#24714).
* doc/lispref/files.texi (Create/Delete Dirs), etc/NEWS: Document this.
* lisp/files.el (files--force): New function.
(delete-directory): Use it to avoid error in this case.
2016-10-18 09:37:13 -07:00
Yuri Khan
0956a3e41e Support Shift selection in nxml-mode commands
* lisp/nxml/nxml-mode.el (nxml-forward-balanced-item)
(nxml-up-element, nxml-backward-up-element, nxml-down-element)
(nxml-backward-down-element, nxml-forward-element)
(nxml-backward-element, nxml-forward-paragraph)
(nxml-backward-paragraph): Use "^p" as the interactive spec, to
support shift-selection.

Copyright-paperwork-exempt: yes
2016-10-18 09:42:54 +03:00
Eli Zaretskii
baa8ba4ed4 * lisp/subr.el (start-process): Doc fix. (Bug#24693) 2016-10-18 09:24:05 +03:00
Mark Oteiza
73d4c86ee1 Simplify some loops and cons
* lisp/net/mailcap.el: Replace cl with cl-lib.
(mailcap--get-user-mime-data, mailcap--set-user-mime-data):
(mailcap-parse-mailcaps, mailcap-parse-mailcap-extras):
(mailcap-possible-viewers): Use push and dolist where possible.
(mailcap-viewer-passes-test): Remove unused binding.
(mailcap-add-mailcap-entry): Use push.
(mailcap-mime-info): Remove unused binding.  Use push.
(mailcap-parse-mimetypes): Use dolist.
2016-10-18 01:53:22 -04:00
Göktuğ Kayaalp
e535ca4522 Fix display of vc-dir CVS file statuses in subdirectories
* lisp/vc/vc-cvs.el (vc-cvs-dir-status-files): Use 'cvs update'
instead of 'cvs status'.  It's faster, easier to parse, and
relieves us of the need to use vc-expand-dirs.  (Bug#24082)
(vc-cvs-after-dir-status): Parse its output.
2016-10-18 03:03:17 +03:00
Mark Oteiza
e697ccab77 Turn on lexical-binding in auth-source
* lisp/auth-source.el: Turn on lexical-binding.
(auth-source-netrc-parse, auth-source-netrc-normalize):
(auth-source-token-passphrase-callback-function):
(auth-source-netrc-create, auth-source-secrets-search):
(auth-source-macos-keychain-search-items):
(auth-source-plstore-search): Use let instead of lexical-let.
2016-10-17 14:31:31 -04:00
Eli Zaretskii
12da149670 Update URL of MS-Windows optional DLLs
* nt/README.W32:
* nt/INSTALL: Update the URL of the MS-Windows binaries of the
optional libraries built with MSYS2/MinGW64 project tools.
2016-10-17 12:12:25 +03:00
Martin Rudalics
421c0512f7 Fix frame focus redirection with shared minibuffer windows (Bug#24500)
* src/frame.c (do_switch_frame): Redirect frame focus also when
the frame switched to has its minibuffer window on the selected
frame.
* src/window.c (candidate_window_p): To qualify as candidate
it's not sufficient for the window's frame to just share the
minibuffer window - it must be active as well.
2016-10-17 10:52:01 +02:00
Martin Rudalics
027c350e0c ; * etc/NEWS: Add note on atomic windows. 2016-10-17 09:59:20 +02:00
Eli Zaretskii
2331056cfd Merge branch 'emacs-25' of git.savannah.gnu.org:/srv/git/emacs into emacs-25 2016-10-17 10:26:55 +03:00
Eli Zaretskii
d70ed8aaea Fix time-related data types in 2 editfns.c functions
* src/editfns.c (format_time_string, Fcurrent_time_zone): Pass a
pointer to time_t value to emacs_localtime_rz and gmtime_r,
instead of relying on struct timespec's tv_sec member to be of
compatible type.
2016-10-17 10:25:58 +03:00
Eli Zaretskii
be0c3814af Fix time-related data types in 2 editfns.c functions
* src/editfns.c (format_time_string, Fcurrent_time_zone): Pass a
pointer to 'time_t' value to 'emacs_localtime_rz' and 'gmtime_r',
instead of relying on struct timespec's 'tv_sec' member to be of
compatible type.
2016-10-17 10:19:34 +03:00
Martin Rudalics
665ee0a565 Document atomic windows in Elisp manual (Bug#18170)
* lisp/window.el (display-buffer-in-atom-window): If no `side'
alist entry was specified, use `below' as the doc tells.
* doc/lispref/elisp.texi (Atomic Windows): Add menu entry.
* doc/lispref/windows.texi (Atomic Windows): New section.
(Window Parameters): Update reference.
2016-10-17 08:57:24 +02:00
Tino Calancha
a4285bcb11 * lisp/simple.el (process-menu-mode, list-processes--refresh):
Include PID.  (Bug#21725)

(cherry picked from commit b7adc2f237)
2016-10-16 23:37:28 -07:00
Tino Calancha
b0c447e466 * lisp/ibuf-ext.el (ibuffer-do-shell-command-file):
Fix non-file-visiting-buffer case.  (Bug#22678)

(cherry picked from commit 738738259b)
2016-10-16 23:36:24 -07:00
Tino Calancha
cf3c19b029 * lisp/ibuffer.el (ibuffer): Improve 'other-window' case. (Bug#23617)
(cherry picked from commit f4ef1a1fea)
2016-10-16 23:35:28 -07:00
Paul Eggert
99892eeec8 Port to Ubuntu 16.10, which needs gcc -nopie
* configure.ac (emacs_cv_prog_cc_no_pie): Rename from
emacs_cv_prog_cc_nopie.  All usages changed.  Check for -no-pie in
preference to -nopie (Bug#24682).  Backport from master.
2016-10-16 23:16:32 -07:00
Paul Eggert
c06a518b5b New face homoglyph
Suggested by Eli Zaretskii, from a feature request by
Alan Mackenzie (Bug#24468).
* doc/emacs/display.texi (Standard Faces, Text Display):
* etc/NEWS: Document this.
* etc/themes/dichromacy-theme.el, etc/themes/leuven-theme.el:
* etc/themes/light-blue-theme.el, etc/themes/manoj-dark-theme.el:
* etc/themes/tango-dark-theme.el, etc/themes/tango-theme.el:
* etc/themes/wombat-theme.el:
Customize homoglyph to be the same as escape-glyph.
* lisp/cus-theme.el (custom-theme--listed-faces):
Add homoglyph.
* lisp/faces.el (homoglyph): New face.
* lisp/startup.el (startup--setup-quote-display): Use it.
2016-10-16 22:51:51 -07:00
Glenn Morris
b73f4668ab * lisp/cus-start.el (exec-path): Handle nil elements. (Bug#24471) 2016-10-16 18:56:06 -07:00
Paul Eggert
032a299b0e Port to Ubuntu 16.10, which needs gcc -nopie
* configure.ac (emacs_cv_prog_cc_no_pie): Rename from
emacs_cv_prog_cc_nopie.  All usages changed.  Check for -no-pie in
preference to -nopie (Bug#24682).
2016-10-16 16:53:03 -07:00
Andreas Politz
55ebb708cf Catch the imenu-unavailable error in sh-mode completion table
* lisp/progmodes/sh-script.el (sh--cmd-completion-table):
Catch the imenu-unavailable error (bug#24238).
2016-10-16 16:56:25 +03:00
Michael Albinus
3ed8100f77 Fix bug#24665 in Tramp
* doc/misc/tramp.texi (External methods): Do not confuse
method names.  (Bug#24665)
2016-10-16 15:52:26 +02:00
Eli Zaretskii
993acb5088 ; Minor fix for last change in characters.el 2016-10-16 14:22:24 +03:00
Eli Zaretskii
30c4bb58ca More char-width fixes
* lisp/international/characters.el (char-width-table): More fixes
according to the latest EastAsianWidth.txt.  (Bug#24705)
2016-10-16 14:19:32 +03:00
Sam Steingold
f9cbe8ee63 use full time objects (lists) instead of floats when possible
* midnight.el (midnight-buffer-display-time): Remove
(clean-buffer-list): Use float time only for time comparison
2016-10-15 23:27:46 -04:00