summaryrefslogtreecommitdiff
path: root/nt/inc
Commit message (Collapse)AuthorAgeFilesLines
* Fix MS-Windows compilation of Gnulib with old versions of MinGWEli Zaretskii2020-09-151-0/+26
| | | | | | | | * nt/inc/ms-w32.h (_WIN32_WINNT_WIN2K, _WIN32_WINNT_WINXP) (_WIN32_WINNT_WS03, _WIN32_WINNT_VISTA, _WIN32_WINNT_WIN7, _WIN32_WINNT_WIN8, _WIN32_WINNT_WINBLUE, _WIN32_WINNT_WIN10) [__MINGW32__]: Define if any of these is not defined. Reported by martin rudalics <rudalics@gmx.at>.
* Remove private prototype for 'execve' and its uses in MinGW buildEli Zaretskii2020-05-301-11/+0
| | | | | | | | | * src/sysdep.c (emacs_exec_file): Don't compile this function anymore on WINDOWSNT, since it is not used there. This function was the only reason for having 'execve' prototype in ms-w32.h. * nt/inc/ms-w32.h (execve): Remove prototype and the MinGW64 vs ming.org mess that it causes.
* Don't use Gnulib's explicit_bzero on MS-WindowsEli Zaretskii2020-04-191-0/+1
| | | | | | | | | | | | This is a preventive change, since Gnulib was recently changed its explicit_bzero to call SecureZeroMemory on MS-Windows, disregarding systems older than XP, which didn't have it. * src/w32.c (explicit_bzero): New function. * nt/mingw-cfg.site (ac_cv_func_explicit_bzero): Avoid using the Gnulib replacement for explicit_bzero. * nt/inc/ms-w32.h (explicit_bzero): Add prototype.
* Fix the MinGW build as followup to recent "nofollow" changesEli Zaretskii2020-03-081-0/+5
| | | | | | | | | | | | | | | | | | | | * src/w32.c (fdutimens): Call utimensat instead of utime. (set_file_times): Function deleted. (convert_from_timespec): Renamed from convert_from_time_t and modified to accept 'struct timespec' argument instead of 'time_t'. (utimensat): Renamed from utime and modified to accept 'struct timespec [2]' argument and an additional argument FLAG. Emulate Posix 'utimensat'. Call 'convert_from_timespec'. (w32_copy_file): Call 'utimensat' instead of 'set_file_times'. * src/fileio.c (Fcopy_file) [WINDOWSNT]: Make the error message be identical to that on Posix platforms. * nt/inc/sys/stat.h (utimensat): Provide prototype. * nt/mingw-cfg.site (ac_cv_func_futimens) (gl_cv_func_futimens_works, ac_cv_func_utimensat) (gl_cv_func_utimensat_works): Override Gnulib tests. * nt/gnulib-cfg.mk (OMIT_GNULIB_MODULE_futimens) (OMIT_GNULIB_MODULE_utimensat): Disable these Gnulib modules.
* Merge from origin/emacs-27Glenn Morris2020-01-161-2/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 52080b5778 (origin/emacs-27) * lisp/minibuffer.el (read-file-name-def... e4cec1fd10 ; * etc/NEWS: Fix some file name quotations. 13995f31a2 Make emacs prefer an existing ~/.emacs.d to an existing XD... 91cac24952 ; etc/NEWS minor edits 5505babc07 Describe --with-cairo non-support for bitmapped fonts. caf00066ee Mention GTK font chooser changes in NEWS 23b87db628 ; Unmaintain fortran elisp 3b0d1a50aa f90: handle F2008 module function 55803cc189 Move shell-related menu items to "Shell Commands" submenu ... 2be48605c0 * admin/notes/font-backend: Remove outdated file. (Bug#34663) f07a470124 Declare the ftx font backend driver obsolete 6c08a430fb ; Fix wording of a comment. # Conflicts: # admin/notes/font-backend # etc/NEWS
| * ; Fix wording of a comment.Eli Zaretskii2020-01-151-2/+2
| | | | | | | | | | * nt/inc/ms-w32.h (BROKEN_DATAGRAM_SOCKETS): Fix wording of commentary.
* | Fix the MS-Windows build broken by "Let the OS clear large new objects"Eli Zaretskii2020-01-031-0/+3
|/ | | | | | | * src/w32heap.c (sys_calloc): New function, implements calloc in terms of our private implementations of malloc. * nt/inc/ms-w32.h (calloc): Redirect to sys_calloc.
* Update copyright year to 2020Paul Eggert2020-01-0110-10/+10
| | | | Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
* Extend network-interface-list to return IPv6 and network infoRobert Pluim2019-11-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Bug#38218 * src/process.c (Fnetwork_interface_list): Extend argument list to allow requesting full network info and/or IPv4/IPv6 info. (network_interface_list) [HAVE_GETIFADDRS]: Use getifaddrs to retrieve interface IP addresses. * src/process.h: Update prototype of network_interface_list. * src/w32.c (g_b_init_get_adapters_addresses): New init flag. (globals_of_w32): Initialize it. (GetAdaptersAddresses_Proc): New function typedef. (get_adapters_addresses): New wrapper function. (init_winsock): Load htonl and ntohl. (sys_htonl, sys_ntohl): New wrapper functions. (network_interface_list): Implement in terms of get_adapters_addresses. * nt/inc/sys/socket.h: Add sys_htonl and sys_ntohl prototypes. * etc/NEWS: Announce IPv4/IPv6 changes in network-interface-list. * doc/lispref/processes.texi (Misc Network): Document updated arglist and return values for network-interface-list.
* Support (locale-info 'paper) on MS-WindowsEli Zaretskii2019-02-041-0/+4
| | | | | | | | | | | | | | | | | | * src/w32proc.c (LOCALE_IPAPERSIZE): Define if undefined. (nl_langinfo): Support _NL_PAPER_WIDTH and _NL_PAPER_HEIGHT like glibc does. * src/fns.c (Flocale_info): Update the doc string. * nt/inc/langinfo.h: Add _NL_PAPER_WIDTH and _NL_PAPER_HEIGHT to the enumeration. (_NL_PAPER_WIDTH, _NL_PAPER_HEIGHT): Define namesake macros. * nt/mingw-cfg.site (emacs_cv_langinfo__nl_paper_width): Set to 'yes'. * doc/lispref/nonascii.texi (Locales): Update the documentation of 'locale-info' for the argument of 'paper'. * etc/NEWS: Update the locale-info entry.
* Merge from origin/emacs-26Paul Eggert2018-12-3110-10/+10
|\ | | | | | | | | | | 2fcf2df Fix copyright years by hand 26bed8b Update copyright year to 2019 2814292 Fix value of default frame height. (Bug#33921)
| * Update copyright year to 2019Paul Eggert2019-01-0110-10/+10
| | | | | | | | Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
* | Fix WINDOWSNT/DOS_NT buildEli Zaretskii2018-12-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Recent changes in sysdep.c and emacsclient unnecessarily removed useful code from DOS_NT builds. This changeset reinstates that code. * nt/inc/ms-w32.h (tcdrain): Redirect to _commit. (fdatasync): No need to redirect anymore. * lib-src/emacsclient.c (flush_stdout): Don't avoid calling tcdrain on DOS_NT platforms. * src/sysdep.c (reset_sys_modes): Don't ifdef away the call to tcdrain on DOS_NT platforms.
* | Avoid gettimeofday deprecation warnings with MinGWEli Zaretskii2018-07-291-0/+5
|/ | | | | | | * nt/inc/ms-w32.h (__POSIX_2008_DEPRECATED) [__MINGW32_VERSION >= 5001000L]: Define to nothing, to avoid deprecation warnings about gettimeofday with mingw.org's MinGW runtime 5.1 and later.
* ; Fix last change: only MinGW runtime 5.0.2 and later needs that.Eli Zaretskii2018-07-282-2/+2
|
* Fix compilation with mingw.org's MinGW 5.x headersEli Zaretskii2018-07-282-1/+11
|
* Update copyright year to 2018Paul Eggert2018-01-0110-10/+10
| | | | Run admin/update-copyright.
* Prefer HTTPS to HTTP for gnu.orgPaul Eggert2017-09-2910-10/+10
| | | | | This catches some URLs I missed in my previous scan, or perhaps were added after the scan.
* Use Gnulib 'tempname' on MS-WindowsEli Zaretskii2017-08-121-4/+11
| | | | | | | | | | | | | | | | | | | * lib-src/ntlib.h (mkdir, open): Remove redefinitions. They are now in nt/inc/ms-w32.h. * lib-src/ntlib.c (sys_mkdir, sys_open): New functions. (mkostemp): Remove. * src/w32.c (mkostemp): Remove. (sys_mkdir): Accept a second (unused) argument. * src/fileio.c (Fmake_directory_internal): Remove the WINDOWSNT specific call to mkdir. (Bug#28023) * nt/inc/ms-w32.h (mkdir): Remove from "#ifdef emacs" and redefine to accept 2 arguments. (open): Remove from "#ifdef emacs". * nt/mingw-cfg.site (ac_cv_func_mkostemp): Remove. * nt/gnulib-cfg.mk (OMIT_GNULIB_MODULE_mkostemp) (OMIT_GNULIB_MODULE_tempname): Remove.
* Remove unneeded stuff from nt/inc/sys/time.hEli Zaretskii2017-05-151-23/+1
| | | | | | | | * nt/inc/sys/time.h (_TIMEVAL_DEFINED, struct timevat, timerisset) (timercmp, timerclear): Don't define. Instead, include the system header sys/time.h, and add only the interval timers stuff. This avoids compiler warnings about 'gettimeofday's prototype, and also avoids redefinition of macros from system headers.
* Remove gettimeofday from w32 sourcesEli Zaretskii2017-05-141-19/+0
| | | | | | * lib-src/ntlib.c (gettimeofday): * nt/inc/sys/time.h (gettimeofday, struct timezone): Remove unused function 'gettimeofday' and all of its supporting code.
* Fix the MS-Windows buildEli Zaretskii2017-05-141-1/+1
| | | | | * nt/inc/sys/time.h (gettimeofday): * src/w32.c (gettimeofday): Adjust signature to match Gnulib.
* ; Remove redundant definition of the 'DebPrint' macroEli Zaretskii2017-05-041-7/+0
| | | | | * nt/inc/ms-w32.h (DebPrint): Remove redundant definition (defined in src/conf_post.h).
* Temporary fix for the MS_Windows buildEli Zaretskii2017-05-021-1/+1
| | | | | | | * nt/inc/ms-w32.h (WIN32_LEAN_AND_MEAN): Define to an empty value, to be consistent with Gnulib's utimens.c. This is because utimens.c unconditionally defines WIN32_LEAN_AND_MEAN to an empty value, so the previous definition here conflicted with that.
* Update copyright year to 2017 in masterPaul Eggert2017-01-011-1/+1
| | | | | | Run admin/update-copyright in the master branch. This fixes files that were not already fixed in the emacs-25 branch before it was merged here.
* Merge from origin/emacs-25Paul Eggert2017-01-019-9/+9
|\ | | | | | | | | 2e2a806 Fix copyright years by hand 5badc81 Update copyright year to 2017
| * Update copyright year to 2017Paul Eggert2016-12-319-9/+9
| | | | | | | | Run admin/update-copyright.
| * Fix compilation with MinGW runtime 3.22.2 and w32api 3.18.2Eli Zaretskii2016-10-062-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * nt/inc/ms-w32.h (_WIN32_WINNT) [!MINGW_W64]: Undefine before defining to avoid redefinition warnings. * nt/inc/sys/stat.h (_SYS_STAT_H, _INC_STAT_H): Define, to avoid inclusion of sys/stat.h from the system headers, which could then lead to compilation errors due to redefinition of 'struct stat' etc. This is needed because latest versions of MinGW runtime include sys/stat.h from wchar.h. * src/image.c (__MINGW_MAJOR_VERSION) [WINDOWSNT]: Temporarily redefine to 4 to avoid conflict between 2 definitions of MemoryBarrier. (Bug#24613) Do not merge to master!
* | Merge branch 'concurrency'Eli Zaretskii2016-12-041-0/+1
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts (resolved): configure.ac src/Makefile.in src/alloc.c src/bytecode.c src/emacs.c src/eval.c src/lisp.h src/process.c src/regex.c src/regex.h
| * | Fix the MS-Windows buildEli Zaretskii2015-11-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/thread.h [WINDOWSNT]: Include sys/socket.h. * src/sysselect.h: Don't define fd_set and FD_* macros for MS-Windows here. * src/w32.h: Define them here. * src/process.h (sys_select): Declare prototype. * src/sysdep.c: * src/process.c: * src/filelock.c: * src/emacs.c: * src/callproc.c: Move inclusion of sys/select.h after lisp.h. * nt/inc/socket.h: Include w32.h instead of sysselect.h
| * | merge from trunkKen Raeburn2015-11-0112-44/+182
| |\ \
| * | | Fix MS-Windows build.Eli Zaretskii2013-08-261-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | src/callproc.c: src/emacs.c: src/filelock.c: src/process.c: src/sysdep.c: src/w32.c: Reshuffle Windows-specific headers to avoid errors with redefinition of fd_set etc. src/process.c: Don't use num_pending_connects when NON_BLOCKING_CONNECT is not defined. src/sysselect.h: Move definitions of FD_* macros and of SELECT_TYPE here from w32.h. src/w32proc.c (sys_select): Adjust the argument types to what thread.h expects. nt/inc/sys/socket.h: Include stdint.h. Include sysselect.h instead of w32.h.
* | | | Implement getrlimit and setrlimit for MS-WindowsEli Zaretskii2016-11-191-0/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/w32heap.c (getrlimit, setrlimit): New functions. Include w32.h. * src/emacs.c (main): Use 'rlim_t', not 'long', for values that should be compatible with 'struct rlimit' members. * nt/inc/sys/resource.h: New header file. * nt/mingw-cfg.site (ac_cv_func_getrlimit, ac_cv_func_setrlimit): Set to "yes".
* | | | Fix compilation with MinGW runtime 3.22.2 and w32api 3.18.2Eli Zaretskii2016-10-062-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * nt/inc/ms-w32.h (_WIN32_WINNT) [!MINGW_W64]: Undefine before defining to avoid redefinition warnings. * nt/inc/sys/stat.h (_SYS_STAT_H, _INC_STAT_H): Define, to avoid inclusion of sys/stat.h from the system headers, which could then lead to compilation errors due to redefinition of 'struct stat' etc. This is needed because latest versions of MinGW runtime include sys/stat.h from wchar.h. * src/image.c (__MINGW_MAJOR_VERSION) [WINDOWSNT]: Temporarily redefine to 4 to avoid conflict between 2 definitions of MemoryBarrier. (Bug#24613)
* | | | * nt/inc/ms-w32.h (execve) [MINGW_W64]: Make commentary more accurate.Eli Zaretskii2016-09-011-5/+6
| | | |
* | | | Avoid compiler warnings with MinGW64 GCC 6Eli Zaretskii2016-09-011-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | * nt/inc/ms-w32.h (execve) [MINGW_W64]: Make the prototype match the GCC 6 builtin, to avoid warnings. For more details, see http://lists.gnu.org/archive/html/emacs-devel/2016-08/msg00721.html.
* | | | Fix compilation warning in the MinGW buildEli Zaretskii2016-07-221-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * nt/inc/ms-w32.h: Include stdint.h. (_execvp, execve): Provide prototypes. * lib-src/emacsclient.c [WINDOWSNT]: Remove prototype for execvp, it is now in nt/inc/ms-w32.h. * lib-src/ntlib.c (getppid): Avoid compiler warnings due to format mismatch. (sys_ctime): Remove, not used.
* | | | Merge from origin/emacs-25John Wiegley2016-03-119-20/+18
|\ \ \ \ | | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | facb5e2 Update Emacs manual section related to character folding 4efea8e ; * etc/DEBUG: Fix a typo. (Bug#22984) f8df21b Update admin/notes/unicode 950be68 Add symref-filepattern entries for c?perl-mode 8b8a6ad Don't use XRANDR 1.3 extensions if the server doesn't support them. 985dacf ; NEWS update for the last change in etags 741a6f8 Sync with gnulib 7352c6c Rework C source files to avoid ^( a589e9a By default, etags produces unqualified Perl tag names 72c7438 Indent methods with keyword names correctly 28532a9 Propertize character literals and special global variables differently a7d6f39 ; Fix last change in NEWS 83b2a20 Change how /etc/NEWS presents character folding b417c5a Revert "Revert "Backport: * lisp/isearch.el: Turn char-folding off by default"" 711ca36 Properly handle lambda as read function (bug 22961) 1b9d616 Propertize operator symbol names with symbol syntax class 9b16bc2 Stop recognizing :#{} as symbol in ruby-mode 366ec77 Allow using the left shift operator without spaces on both sides 02bf7cc Properly handle unquoting in wdired (bug 22938) 16cf469 ; Spelling fix and tighten up comment f50bc04 Allow splat operator before percent literal 991c801 Don't apply the return value of goto-char as syntax class 6e63b3e Guard against nested percent literals 066f3bc Recognize iuwu-mod after an escaped newline 6f7a57c Fix symbolic mode string conversion for s and t 50b9826 Update 'ucs-names' database 993b2fb Improve doc string of 'shell-command' b71c717 Make the code in movemail_strftime more general cc057e4 Speed up redisplay of binary files with long series of nulls e51b27e Remove the highlighting support for quoting 'like this' inside Lisp docstrings b1abce1 Restore leading space in movemail pop output 98b8d44 Fix bidi-paragraph-direction in Rmail view buffer dc9d837 Don't misindent computed property generator methods 7923112 Fix mbox files produced by movemail on MS-Windows c45a1ca doc string file descriptor exhaustion fix 265141b Fix Bug#22814
| * | | Rework C source files to avoid ^(Paul Eggert2016-03-109-20/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Work around Bug#22884 by rewording comments and strings to avoid ‘(’ at the start of a line unless it starts a function. This change is a short-term hack; in the longer run we plan to fix cc-mode’s performance for C files that have ‘(’ at the start of a line in a comment or string.
* | | | Unbreak the MinGW64 buildEli Zaretskii2016-03-061-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * nt/inc/ms-w32.h [MINGW_W64]: Undefine HAVE_GAI_STRERROR. See http://lists.gnu.org/archive/html/emacs-devel/2016-03/msg00130.html for the details. Reported by Angelo Graziosi <angelo.graziosi@alice.it>.
* | | | Implement getaddrinfo fallback for MS-WindowsEli Zaretskii2016-03-051-0/+5
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See http://lists.gnu.org/archive/html/emacs-devel/2016-02/msg01602.html for more details. * nt/mingw-cfg.site (ac_cv_func_getaddrinfo) (ac_cv_func_gai_strerror): Set to "yes", as the configure script's test program is not smart enough to auto-detect these. * nt/inc/sys/socket.h (getaddrinfo, freeaddrinfo): Redirect to sys_getaddrinfo and sys_freeaddrinfo. Provide prototypes for sys_getaddrinfo and sys_freeaddrinfo. * src/w32.c (init_winsock): Try loading getaddrinfo and freeaddrinfo from ws2_32.dll. (sys_getaddrinfo, sys_freeaddrinfo): New functions. * lib-src/pop.c [WINDOWSNT]: Include winsock2.h, not winsock.h, and also ws2tcpip.h. (getaddrinfo, freeaddrinfo) [WINDOWSNT]: Redirect to sys_getaddrinfo and sys_freeaddrinfo, respectively. (load_ws2, sys_getaddrinfo, sys_freeaddrinfo) [WINDOWSNT]: New functions.
* | | Ensure 8-byte aligned memory allocation on MS-Windows 9XJussi Lahdenniemi2016-01-161-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/w32heap.c (init_heap): Redirect malloc, realloc, and free to special functions on Windows 9X. Refuse to dump Emacs on Windows 9X. (malloc_after_dump_9x, realloc_after_dump_9x) (free_after_dump_9x): New functions. (Bug#22379) See also http://lists.gnu.org/archive/html/emacs-devel/2016-01/msg00852.html for more details about the original problem. * nt/inc/ms-w32.h (malloc_after_dump_9x, realloc_after_dump_9x) (free_after_dump_9x): Add prototypes. Copyright-paperwork-exempt: yes
* | | Update copyright year to 2016Paul Eggert2016-01-019-9/+9
| |/ |/| | | | | Run admin/update-copyright.
* | Support recovery from C stack overflow on MS-WindowsEli Zaretskii2015-08-081-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/w32fns.c (w32_reset_stack_overflow_guard) (stack_overflow_handler): New functions for handling C stack overflow exceptions. (my_exception_handler): Handle EXCEPTION_STACK_OVERFLOW exceptions specially, and zero out except_addr if we do. (globals_of_w32fns): Initialize dwMainThreadId in non-interactive mode. * src/sysdep.c [HAVE_STACK_OVERFLOW_HANDLING]: Add !WINDOWSNT to the condition, as HAVE_STACK_OVERFLOW_HANDLING is now defined for the MinGW build, but the code guarded by that is for Posix hosts. * src/keyboard.c (command_loop) [WINDOWSNT]: Call w32_reset_stack_overflow_guard. * nt/inc/ms-w32.h (sigjmp_buf): New typedef. (sigsetjmp): New macro. (w32_reset_stack_overflow_guard): Declare the prototype. * configure.ac (HAVE_STACK_OVERFLOW_HANDLING): Set to 1 for MinGW.
* | MS-Windows follow-up for recent TZ-related changesEli Zaretskii2015-07-271-15/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * nt/mingw-cfg.site (ac_cv_header_pthread_h) (gl_cv_sys_struct_timespec_in_pthread_h): Force to "no", to avoid picking up 'struct timespec' from pthread.h, if it is installed on the user's system. We want either the definitions from MinGW system headers, if available, or the Gnulib replacements if not. * nt/inc/ms-w32.h <struct timespec>: Don't define, as we now use lib/time.h. * lib/time.in.h: Don't let __need_* symbols affect what happens on MinGW. These symbols are defined by MinGW system headers, but we don't want that to affect whether Gnulib portions of the header are or aren't used.
* | Adapt 'struct timespec' to next release of MinGW runtimeEli Zaretskii2015-06-071-1/+4
| | | | | | | | | | * nt/inc/ms-w32.h (struct timespec): Don't declare if __struct_timespec_defined is defined.
* | Support non-blocking connect on MS-Windows (Bug#20207)Eli Zaretskii2015-03-271-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Based on ideas from Kim F. Storm <storm@cua.dk>, see http://lists.gnu.org/archive/html/emacs-devel/2006-12/msg00873.html. src/w32proc.c (reader_thread): If the FILE_CONNECT flag is set, call '_sys_wait_connect'. If it returns STATUS_CONNECT_FAILED, exit the thread with code 2. (sys_select): Support 'wfds' in addition to 'rfds'. If a descriptor in 'wfds' has its bit set, but the corresponding fd_info member doesn't have its FILE_CONNECT flag set, ignore the descriptor. Otherwise, acknowledge a successful non-blocking connect by resetting the FILE_CONNECT flag and setting cp->status to STATUS_READ_ACKNOWLEDGED. src/w32.h (STATUS_CONNECT_FAILED): New enumeration value. (struct _child_process): New member 'errcode'. (FILE_CONNECT): New flag. (_sys_wait_connect): Add prototype. src/w32.c (pfn_WSAEnumNetworkEvents): New function pointer. (init_winsock): Load WSAEnumNetworkEvents from winsock DLL. (set_errno): Map WSAEWOULDBLOCK and WSAENOTCONN. (sys_connect): Support non-blocking 'connect' calls by setting the FILE_CONNECT flag in the fd_info member and returning EINPROGRESS. (_sys_read_ahead): Add debug message if this function is called for a descriptor that waits for a non-blocking connect to complete. (_sys_wait_connect): New function. (sys_read): Support STATUS_CONNECT_FAILED. Return the error code recorded by _sys_wait_connect when the non-blocking connect failed. Don't call WSAGetLastError before a call to set_errno had a chance to use its value, since WSAGetLastError clears the last error. nt/inc/ms-w32.h (BROKEN_NON_BLOCKING_CONNECT): Don't define.
* | Support daemon mode on MS-Windows (bug#19688)Mark Laws2015-02-271-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | src/emacs.c <w32_daemon_event> [WINDOWSNT]: New global var. (main) [WINDOWSNT]: Initialize it to NULL. Create the event to signal clients we are ready for connections. (Fdaemon_initialized): Use DAEMON_RUNNING. [WINDOWSNT]: MS-Windows specific code to signal clients we are ready for connections. src/lisp.h (DAEMON_RUNNING): New macro, encapsulates Posix and MS-Windows conditions for running in daemon mode. src/minibuf.c (read_minibuf): Use DAEMON_RUNNING. src/keyboard.c (kbd_buffer_get_event): Use DAEMON_RUNNING. src/dispnew.c (init_display) [WINDOWSNT]: Initialize frames/terminal even in daemon mode. nt/inc/ms-w32.h (W32_DAEMON_EVENT): New macro. lib-src/emacsclient.c (decode_options) [WINDOWSNT]: Don't reject empty arguments for --alternate-editor. (print_help_and_exit) [WINDOWSNT]: Don't refrain from advertising empty arguments for --alternate-editor. (start_daemon_and_retry_set_socket) [WINDOWSNT]: MS-Windows specific code to start Emacs in daemon mode and wait for it to be ready for client connections. lisp/server.el (server-process-filter): Force GUI frames on MS-Windows in daemon mode, even if a TTY frame was requested. lisp/frameset.el (frameset-keep-original-display-p): Don't assume windows-nt cannot be in daemon mode. lisp/frame.el (window-system-for-display): Don't assume windows-nt cannot be in daemon mode.
* | Update copyright year to 2015Paul Eggert2015-01-019-9/+9
| | | | | | | | Run admin/update-copyright.
* | Merge branch 'emacs-24'Ted Zlatanov2014-11-261-4/+13
|\ \ | | | | | | | | | | | | | | | | | | Conflicts: nt/addsection.c nt/inc/ms-w32.h src/w32.c