1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-24 23:31:33 -07:00
Commit graph

102369 commits

Author SHA1 Message Date
Paul Eggert
17107bb698 Integer and memory overflow issues.
* emacsclient.c (xmalloc): Accept size_t, not unsigned int, to
avoid potential buffer overflow issues on typical 64-bit hosts.
Return void *, not long *.
(get_current_dir_name): Report a failure, instead of looping
forever, if buffer size calculation overflows.  Treat malloc
failures like realloc failures, as that has better behavior and is
more consistent.  Do not check whether xmalloc returns NULL, as
that's not possible.
(message): Do not arbitrarily truncate message to 2048 bytes when
sending it to stderr; use vfprintf instead.
(get_server_config, set_local_socket)
(start_daemon_and_retry_set_socket): Do not alloca
arbitrarily-large buffers; that's not safe.
(get_server_config, set_local_socket): Do not use sprintf when its
result might not fit in 'int'.
(set_local_socket): Do not assume uid fits in 'int'.
2011-08-28 16:52:34 -07:00
Paul Eggert
5fc295a42f Merge from trunk. 2011-08-26 09:13:07 -07:00
Chong Yidong
7254299e4d * package.el (package-install): Call package-initialize if called interactively. 2011-08-26 11:53:50 -04:00
Chong Yidong
d43f5a423d Document package manager in Emacs manual.
* doc/emacs/package.texi: New file, documenting the package manager.

* doc/emacs/emacs.texi: Include it.

* doc/emacs/help.texi (Help Summary): Add describe-package.
2011-08-26 11:48:19 -04:00
Glenn Morris
37846983d0 Auto-commit of generated files. 2011-08-26 06:19:08 -04:00
Eli Zaretskii
c11821d4e1 Fix bug #9324 with unwarranted repositioning of point.
src/xdisp.c (redisplay_window): Don't force window start if point
 will be invisible in the resulting window.
2011-08-26 13:07:06 +03:00
Leo Liu
f8ccf16762 Fix format bug in defstruct
http://debbugs.gnu.org/9357
2011-08-26 17:52:07 +08:00
Katsumi Yamaoka
2a9878fd77 mailcap.el (mailcap-mime-data): Regexp-quote MIME subtype. 2011-08-26 09:01:56 +00:00
Jan Djärv
52ec1febdd * configure.in: Add -MP to DEPFLAGS.
Fixes: debbugs:9372
2011-08-26 09:12:16 +02:00
Paul Eggert
fcbc5f60ee Merge from trunk. 2011-08-25 22:05:13 -07:00
Katsumi Yamaoka
16e07ee0c3 gnus-msg.el (gnus-setup-message): Remove extra apostrophe. 2011-08-26 04:25:55 +00:00
Paul Eggert
ef25feb443 Merge from trunk. 2011-08-25 15:38:52 -07:00
Juri Linkov
3e8cd5ce95 * lisp/isearch.el (isearch-occur): Let-bind `search-spaces-regexp' to
`search-whitespace-regexp'.

Fixes: debbugs:9364
2011-08-25 23:48:45 +03:00
Juri Linkov
93eb711326 * lisp/isearch.el (isearch-edit-string): Let-bind `search-ring' and
`regexp-search-ring' to their global values to protect from
updating by `read-from-minibuffer'.

Fixes: debbugs:9185
2011-08-25 23:32:54 +03:00
Juri Linkov
f65d1611ff * lisp/textmodes/ispell.el (ispell-command-loop): Add newline
at the end of the "Use option `i'..." line.
2011-08-25 22:54:07 +03:00
Juri Linkov
f1cf7a31ca * lisp/battery.el (display-battery-mode): If `battery-status-function'
or `battery-mode-line-format' is nil, display the message and set
`display-battery-mode' to nil.

Fixes: debbugs:9363
2011-08-25 22:49:57 +03:00
Paul Eggert
a974cdce9b Merge from trunk. 2011-08-25 12:06:56 -07:00
Eli Zaretskii
e25be79236 Fix last change for text terminals.
src/xdisp.c (try_cursor_movement): Don't advance `row' beyond the
 last row of the window.
2011-08-25 20:16:39 +03:00
Eli Zaretskii
fee65a97c0 Fix cursor motion with long continued lines near window bottom.
src/xdisp.c (try_cursor_movement): Check for the need to scroll more
 accurately, and prefer exact match for point under bidi.
2011-08-25 19:33:16 +03:00
Chong Yidong
856ce114ff Fix Emacs manual chapter numbers in last change. 2011-08-25 12:30:46 -04:00
Chong Yidong
f404f8bc63 Relocate some additional Emacs manual nodes.
* doc/emacs/display.texi (Narrowing): Move into display chapter.

* doc/emacs/picture-xtra.texi (Picture Mode): Group with Editing Binary
Files section.  Convert from chapter into section.

* doc/emacs/text.texi (Two-Column): Move into Text chapter.
2011-08-25 12:13:59 -04:00
Chong Yidong
e0b1591ba7 Rearrange manual chapters to group mail, rmail, and gnus together.
* sending.texi (Sending Mail):
* rmail.texi (Rmail):
* misc.texi (Gnus, Document View):
* dired.texi (Dired):
* emacs.texi: Group the mail, rmail, and gnus chapters together.
2011-08-25 11:38:49 -04:00
Bastien Guerry
84f211108b Cosmetic fixes. 2011-08-25 13:00:13 +02:00
Eli Zaretskii
0c95fcf739 Handle `(space ...)' display spec as paragraph separator.
src/xdisp.c (compute_display_string_pos): Return 2 in DISP_PROP when
 the display spec is of the form `(space ...)'.
 (handle_display_spec): Return the value returned by
 handle_single_display_spec, not just 1 or zero.
 (handle_single_display_spec): If the display spec is of the form
 `(space ...)', and specifies display in the text area, return 2
 rather than 1.
 src/dispextern.h (struct bidi_it): Rename the disp_prop_p member
 into disp_prop; all users changed.
 src/bidi.c (bidi_fetch_char): If compute_display_string_pos returns
 DISP_PROP = 2, substitute the u+2029 PARAGRAPH SEPARATOR character
 for the text covered by the display property.
 lisp/buff-menu.el (Buffer-menu-buffer+size): Remove calls to
 bidi-string-mark-left-to-right; they are unnecessary now.
 doc/lispref/display.texi (Specified Space): Mention that `space' specs
 influence bidi reordering.
 (Bidirectional Display): Explain how to use `(space . PROPS)' for
 separating fields with bidirectional content.
2011-08-25 13:45:33 +03:00
Deniz Dogan
a2ebe600c9 * lisp/net/quickurl.el: Documentation typo fixes. 2011-08-25 07:43:57 +02:00
Glenn Morris
b2948976fc * lisp/emacs-lisp/derived.el (define-derived-mode): Doc fix. 2011-08-24 22:37:55 -07:00
Chong Yidong
e4ed06f12b Delete record-buffer, and rename unrecord-buffer to bury-buffer-internal.
* lisp/window.el (bury-buffer, quit-window): Use bury-buffer-internal.

* src/buffer.c (Fbury_buffer_internal): Rename from Funrecord_buffer.
Change return value to nil.
(Frecord_buffer): Delete unused function.
2011-08-24 20:45:23 -04:00
Glenn Morris
e5f1c99e95 Minor smtpmail.el fixes.
* lisp/mail/smtpmail.el (smtpmail-smtp-user): Add version: tag.
(smtpmail-via-smtp): Handle nil response from smtp.
2011-08-24 20:41:03 -04:00
Paul Eggert
011ba6eaac Merge from trunk. 2011-08-24 14:20:36 -07:00
Juri Linkov
f22f4808a0 More uses of error' and warning' faces.
* lisp/battery.el (battery-update): Use the face `error' instead of
`font-lock-warning-face'.

* lisp/ibuffer.el (ibuffer-marked-face): Change default face from
`font-lock-warning-face' to `warning'.
(ibuffer-deletion-face): Change default face from
`font-lock-type-face' to `error'.

* lisp/proced.el (proced-marked): Inherit from `error' instead of
`font-lock-warning-face'.

Fixes: debbugs:6117
2011-08-24 21:09:18 +03:00
Juri Linkov
6a93965ee8 * lisp/faces.el (success): Change face color from "Green3" to
"ForestGreen" on light background.

Fixes: debbugs:9353
2011-08-24 21:01:40 +03:00
Chong Yidong
1ed43b0999 Rename quit-restore-window into quit-window.
* lisp/window.el (quit-window): Renamed from quit-restore-window.  Use
same arglist as old quit-window.
(frame-auto-delete): Doc fix.

* lisp/view.el (view-mode-exit): Use quit-window.
2011-08-24 13:38:46 -04:00
Eli Zaretskii
8610fe8b84 Fix cursor movement in R2L text within L2R paragraphs.
src/xdisp.c (set_cursor_from_row): Consider candidate row a win if its
 glyph represents a newline and point is on that newline.  Fixes cursor
 positioning on the newline at EOL of R2L text within L2R
 paragraph, and vice versa.
 (try_cursor_movement): Check continued rows, in addition to
 continuation rows.  Fixes unwarranted scroll when point enters a
 continued line of R2L text within an L2R paragraph, or vice versa.
 (cursor_row_p): Consider the case of point being equal to
 MATRIX_ROW_END_CHARPOS.  Prevents cursor being stuck when moving
 from the end of a short line to the beginning of a continued line
 of R2L text within L2R paragraph.
 (RECORD_MAX_MIN_POS): For max_pos, use IT_CHARPOS even for
 composed characters.
2011-08-24 18:51:56 +03:00
Eli Zaretskii
5980d4c6db Fix current-bidi-paragraph-direction and its doc.
src/xdisp.c (Fcurrent_bidi_paragraph_direction): For unibyte
 buffers, return left-to-right.
 doc/lispref/display.texi (Bidirectional Display): Document return value in
 buffers that are not bidi-reordered for display, and in unibyte
 buffers.
2011-08-24 14:49:54 +03:00
Juri Linkov
11dcdbb283 "C-s M-p" brings the tip of the search ring.
* lisp/isearch.el (isearch-ring-adjust1): Start visiting previous
search strings from the index 0 (-1 + 1) instead of 1 (0 + 1).
(isearch-repeat, isearch-edit-string): Call `isearch-ring-adjust1'
for empty search string (when the last search string is reused
automatically) to adjust the isearch ring to the last element and
prepare the correct index for further M-p commands.

Fixes: debbugs:9185
2011-08-24 12:40:58 +03:00
Eli Zaretskii
f67cdd7f25 Minor changes in bidi.c.
src/bidi.c (bidi_check_type): Use xassert.
 (bidi_cache_iterator_state): Update the disp_pos and disp_prop_p
 members.
2011-08-24 10:46:00 +03:00
Kenichi Handa
fd294c6932 merge trunk 2011-08-24 16:35:02 +09:00
Kenichi Handa
de62b4dfd0 international/ucs-normalize.el: If decomposition property of CHAR is the default one (i.e. a list of CHAR itself), treat it as nil. 2011-08-24 16:33:55 +09:00
Steve Chapel
c1ec8ad04d * etc/refcards/refcard.tex: Add a few more commands. (tiny change)
Fixes: debbugs:9343
2011-08-24 00:31:35 -07:00
Stefan Monnier
963b492b63 * lisp/mpc.el (mpc--proc-filter): Don't signal mpc-proc-error since signals
from process filters aren't reliably transmitted to the surrounding
accept-process-output.
(mpc-proc-check): New function.
(mpc-proc-sync): Use it

Fixes: debbugs:8293
2011-08-23 21:55:10 -04:00
Stefan Monnier
93b6b5e15d * lisp/emacs-lisp/eieio.el (eieio-defmethod, eieio-defgeneric):
Add compatibility functions.

Fixes: debbugs:9313
2011-08-23 14:53:51 -04:00
Eli Zaretskii
904215d227 cus-start.el: Add :version tag to bidi-paragraph-direction. 2011-08-23 18:53:46 +03:00
Eli Zaretskii
b177498a8a cus-start.el: Add entry for bidi-paragraph-direction. 2011-08-23 18:21:19 +03:00
Eli Zaretskii
bca633fb29 Followup for character properties in 2011-08-23T11:48:07Z!handa@m17n.org.
src/bidi.c (bidi_get_type): Abort if we get zero as the bidi type of
 a character.
 admin/unidata/unidata-gen.el (unidata-prop-alist): Update the default
 values of bidi-class according to DerivedBidiClass.txt from the
 latest UCD.
 lisp/international/uni-bidi.el: Regenerated.
 doc/lispref/nonascii.texi (Character Properties): Document the values for
 unassigned codepoints.
2011-08-23 17:45:14 +03:00
Chong Yidong
4a5885a74a * src/nsfont.m (ns_otf_to_script): Fix typo. 2011-08-23 10:41:07 -04:00
Kenichi Handa
821ff7208c merge trunk 2011-08-23 20:49:03 +09:00
Kenichi Handa
0902a04edd Fix default values of character properties. 2011-08-23 20:48:07 +09:00
Eli Zaretskii
8ddde6516c Fix bug #8874 with recentering and header line under scroll-conservatively.
src/xdisp.c (redisplay_window): When computing centering_position,
 account for the height of the header line.
2011-08-23 13:35:47 +03:00
Martin Rudalics
3bbf23bc31 Fix message in help-window-setup (Bug#9341).
* help.el (help-window-setup): Fix message displayed when other
window is reused.  (Bug#9341)
2011-08-23 11:31:54 +02:00
Eli Zaretskii
425cc014ac Fix crashes with completion and composed characters.
src/dispnew.c (buffer_posn_from_coords): Use buf_charpos_to_bytepos
 instead of CHAR_TO_BYTE.  Fixes a crash when a completion
 candidate is selected by the mouse, and that candidate has a
 composed character under the mouse.
2011-08-23 11:38:29 +03:00