* dired.c (Ffile_attributes): Return Qnil, if Fexpand_file_name
raises an error.
* net/tramp-adb.el (tramp-adb-handle-file-attributes):
* net/tramp-gvfs.el (tramp-gvfs-handle-file-attributes):
* net/tramp-sh.el (tramp-sh-handle-file-attributes): Return nil in
case of errors.

* net/tramp.el (tramp-error-with-buffer): Show connection buffer
only when message appeared in minibuffer.
Fix wrong bound to c-font-lock-declarators.  Fixes bug #18948.
progmodes/cc-fonts.el (c-font-lock-declarations): Pass "(point-max)" as
bound to c-font-lock-declarators, not "limit", as the buffer is sometimes
narrowed to less than "limit" (e.g., in the presence of macros).
Backport fix to bug #18749 to Emacs-24 branch.
* src/xgselect.c (xg_select): Use g_main_context_acquire.
* src/syntax.c (back_comment): Fix off-by-one error.
epg: Adjust to GnuPG 2.1 key listing change
  
* epg.el (epg--list-keys-1): Ignore fields after the 15th field
(bug#18979).  Reported by Hideki Saito.

Backported from trunk.
Backport from trunk documentation of shr-color-visible-* variables.

 doc/misc/eww.texi (Advanced): Document increasing contrast with
 shr-color-visible-distance-min and shr-color-visible-luminance-min.
doc/misc/eww.texi: Fix a typo and improve wording of last commit.
* files.el (file-name-non-special): Wrap the call of
`insert-file-contents' by `unwind-protect', in order to set the
buffer's file name anyway.
* callproc.c (encode_current_directory): Support handling of file
names prepended by "/:".
* src/callproc.c (encode_current_directory): Fix thinko in previous.
* lisp/emulation/cua-base.el (cua--select-keymaps): Use region-active-p.
(cua-set-mark, cua--pre-command-handler-1,cua--post-command-handler-1):
* lisp/emulation/cua-gmrk.el (cua-cancel-global-mark): Same.
* callproc.c (encode_current_directory): Encode dir at the end.
* net/tramp.el (tramp-check-cached-permissions): Include hop in
the constructed Tramp file name.
* lisp/replace.el: History for query replace pairs.
(query-replace-defaults): Promote to a list of cons cell.  Doc fix.
(query-replace-from-to-separator): New variable.
(query-replace-read-from): Let-bind query-replace-from-to-history
to a list of FROM-TO strings created from query-replace-defaults
and separated by query-replace-from-to-separator.  Use it as
the history while reading from the minibuffer.  Split the returned
string by the separator to get FROM and TO parts, and add them
to the history variables.
(query-replace-read-to): Add FROM-TO pairs to query-replace-defaults.
(query-replace-regexp-eval): Let-bind query-replace-defaults to nil.
http://lists.gnu.org/archive/html/emacs-devel/2014-11/msg00253.html

* lisp/isearch.el (isearch-text-char-description): Keep characters
intact and put formatted strings with the `display' property.
Backport Tramp changes from trunk.

* automated/tramp-tests.el (tramp-remote-process-environment):
Declare.
(tramp--test-enabled): Ignore errors.
(tramp--instrument-test-case): Extend docstring.  Print debug
buffer in any case.
(tramp-test15-copy-directory): Skip for tramp-smb.el.
(tramp-test21-file-links): Use `file-truename' for directories.
(tramp-test26-process-file): Extend test according to Bug#17815.
(tramp-test27-start-file-process, tramp-test28-shell-command):
Retrieve process output more robustly.
(tramp-test29-vc-registered): Set $BZR_HOME.
(tramp--test-check-files): Extend test with `substitute-in-file-name'.
(tramp-test30-special-characters): Skip for tramp-adb.el,
tramp-gvfs.el and tramp-smb.el.  Add further file names.
* nsterm.m (EmacsScroller.dealloc): Reinstate, removed at merge
cleanup from 2014-11-01.
Backport Tramp changes from trunk.

* tramp.texi (Inline methods): Remove restriction on "telnet".
Recommend sharing ssh connections for "plink".
(External methods): Remove "sftp".  Merge "pscp" and "psftp"
descriptions.  Recommend sharing ssh connections.  Add "nc" method.
(GVFS based methods): Add "sftp".
(Customizing Completion, External packages, Issues): Use @dots{}.
(Remote shell setup): Explain, how to change command line
arguments of remote "nc" listener.

* trampver.texi: Update release number.
Run `window-configuration-change-hook' only after all faces have been realized.

* frame.c (adjust_frame_size): Call x_set_window_size only if
f->can_x_set_window_size is set.
(make_frame): Initialize f->can_x_set_window_size and
f->can_run_window_configuration_change_hook.
(Fcan_run_window_configuration_change_hook): New function.
* frame.h (frame): Split `official' into `can_x_set_window_size'
and `can_run_window_configuration_change_hook'.
* nsfns.m (Fx_create_frame): Set f->can_x_set_window_size.
* w32fns.c (Fx_create_frame, x_create_tip_frame): Set
f->can_x_set_window_size.
* window.c (run_window_configuration_change_hook): Return
immediately if either f->can_x_set_window_size or
f->can_run_window_configuration_change_hook are false.
(Fset_window_configuration): Instead of f->official set
f->can_x_set_window_size.
* xfns.c (Fx_create_frame, x_create_tip_frame): Set
f->can_x_set_window_size.
* faces.el (face-set-after-frame-default): Enable running
`window-configuration-change-hook'.