1. 20 Sep, 2010 1 commit
    • Juanma Barranquero's avatar
      Don't make W32 code conditional on HAVE_SOCKETS, it's always defined. · 7d701334
      Juanma Barranquero authored
      * w32.c: Remove top-level uses of #ifdef HAVE_SOCKETS.
        (gethostname) [!HAVE_SOCKETS]: Remove.
        (SOCK_REPLACE_HANDLE): Remove macro.
        (socket_to_fd, sys_close, _sys_read_ahead, sys_read, sys_write)
        (term_ntproc, init_ntproc): Don't conditionalize on HAVE_SOCKETS.
      * w32proc.c: Remove top-level uses of #ifdef HAVE_SOCKETS.
        (syms_of_ntproc): Don't conditionalize on HAVE_SOCKETS.
      7d701334
  2. 17 Sep, 2010 1 commit
    • Eli Zaretskii's avatar
      Fix bug #6989. · 69e847be
      Eli Zaretskii authored
       w32.c (_PROCESS_MEMORY_COUNTERS_EX): Don't define with versions
       of w32api >= 3.15.
      69e847be
  3. 06 Aug, 2010 1 commit
    • Dan Nicolaescu's avatar
      Move declarations to header files. · 3ef1d108
      Dan Nicolaescu authored
      * src/keyboard.h (quit_char): Add declaration.
      * src/process.h (QCport, QCspeed, QCprocess, QCbytesize, QCstopbits)
      (QCparity, Qodd, Qeven, QCflowcontrol, Qhw, Qsw, QCsummary): Add
      declarations.
      * sysdep.c:
      * src/w32.c: Remove the above declarations.
      3ef1d108
  4. 07 Jul, 2010 1 commit
  5. 06 Jul, 2010 1 commit
  6. 22 May, 2010 1 commit
    • Eli Zaretskii's avatar
      Fix bug #6237. · 6e83d800
      Eli Zaretskii authored
       w32.c (sys_write): Break writes into chunks smaller than 32MB.
      6e83d800
  7. 01 May, 2010 1 commit
    • Eli Zaretskii's avatar
      Emulate POSIX_SIGNALS on MS-Windows. · d6dae14b
      Eli Zaretskii authored
       w32.c (sigemptyset, sigaddset, sigfillset, sigprocmask): New stubs.
       sysdep.c (sys_signal) [WINDOWSNT]: #ifdef away.
       (wait_for_termination) [WINDOWSNT]: Move MS-Windows specific code
       from non-POSIX_SIGNALS section to POSIX_SIGNALS section.
       s/ms-w32.h (POSIX_SIGNALS, struct sigaction, SIG_BLOCK)
       (SIG_SETMASK, SIG_UNBLOCK): Define.
      d6dae14b
  8. 13 Jan, 2010 1 commit
  9. 19 Oct, 2009 1 commit
    • Dan Nicolaescu's avatar
      * alloc.c: Do not define struct catchtag. · d7306fe6
      Dan Nicolaescu authored
      * eval.c: Move struct catchtag definition ...
      * lisp.h: ... here.
      
      * image.c: Move png.h #include earlier to avoid warnings.
      
      * xterm.c:
      * xsmfns.c:
      * xselect.c:
      * xrdb.c:
      * xmenu.c:
      * xftfont.c:
      * xfont.c:
      * xfns.c:
      * xfaces.c:
      * xdisp.c:
      * window.c:
      * widget.c:
      * w32xfns.c:
      * w32uniscribe.c:
      * w32term.c:
      * w32select.c:
      * w32reg.c:
      * w32proc.c:
      * w32menu.c:
      * w32inevt.c:
      * w32heap.c:
      * w32font.c:
      * w32fns.c:
      * w32console.c:
      * w32.c:
      * w16select.c:
      * vm-limit.c:
      * unexsol.c:
      * unexec.c:
      * unexcw.c:
      * unexaix.c:
      * undo.c:
      * tparam.c:
      * textprop.c:
      * terminfo.c:
      * terminal.c:
      * termcap.c:
      * term.c:
      * syntax.c:
      * sound.c:
      * sheap.c:
      * search.c:
      * scroll.c:
      * region-cache.c:
      * regex.c:
      * ralloc.c:
      * process.c:
      * print.c:
      * msdos.c:
      * minibuf.c:
      * menu.c:
      * marker.c:
      * macros.c:
      * keymap.c:
      * keyboard.c:
      * intervals.c:
      * insdel.c:
      * indent.c:
      * gtkutil.c:
      * ftxfont.c:
      * ftfont.c:
      * fringe.c:
      * frame.c:
      * fontset.c:
      * font.c:
      * fns.c:
      * floatfns.c:
      * filelock.c:
      * fileio.c:
      * emacs.c:
      * editfns.c:
      * dosfns.c:
      * doprnt.c:
      * doc.c:
      * dispnew.c:
      * dired.c:
      * dbusbind.c:
      * data.c:
      * composite.c:
      * coding.c:
      * cmds.c:
      * cm.c:
      * chartab.c:
      * charset.c:
      * character.c:
      * ccl.c:
      * category.c:
      * casetab.c:
      * casefiddle.c:
      * callproc.c:
      * callint.c:
      * bytecode.c:
      * buffer.c:
      * atimer.c: Include setjmp.h.  (Bug#4643)
      
      * xlwmenu.c:
      * lwlib.c:
      * lwlib-utils.c:
      * lwlib-Xm.c:
      * lwlib-Xlw.c:
      * lwlib-Xaw.c: Include setjmp.h.
      d7306fe6
  10. 11 Jul, 2009 2 commits
  11. 09 Jul, 2009 1 commit
  12. 04 Jul, 2009 1 commit
    • Eli Zaretskii's avatar
      Emulation of `getloadavg' on MS-Windows: · ad9e2d54
      Eli Zaretskii authored
      Include float.h
      (g_b_init_get_native_system_info, g_b_init_get_system_times)
      (GetNativeSystemInfo_Proc, GetSystemTimes_Proc): Declare.
      (get_native_system_info, get_system_times): New functions.
      (buf_next, buf_prev, sample_system_load, getavg): New subroutines.
      (getloadavg): Rewrite using GetSystemTimes and GetNativeSystemInfo.
      (globals_of_w32): Initialize g_b_init_get_native_system_info,
      g_b_init_get_system_times, and num_of_processors.
      ad9e2d54
  13. 29 Jun, 2009 1 commit
    • Jim Meyering's avatar
      Remove useless if-before-xfree tests. · 5f445726
      Jim Meyering authored
      * nsfont.m (nsfont_close): Remove useless test.
      * term.c (delete_tty): Likewise.
      * w32.c (system_process_attributes): Likewise.
      * w32font.c (w32font_close): Likewise.
      * xfaces.c (x_free_gc): Likewise.
      * xselect.c (buffer): Likewise.
      5f445726
  14. 21 Mar, 2009 1 commit
    • Eli Zaretskii's avatar
      inc/sys/stat.h (struct stat): Change the types of st_uid and st_gid to unsigned. · 22749e9a
      Eli Zaretskii authored
      inc/pwd.h (struct passwd): Change the types of pw_uid and pw_gid to unsigned.
      	  (getpwuid): Argument is now unsigned.
      	  uid_t is now unsigned.
      
      ntlib.c (setuid): Argument is now unsigned.
      	(getuid): Return value is now unsigned.
      	(getpwuid): Argument is now unsigned.
      	(fchown): UID and GID arguments are now unsigned.
      
      ntlib.h (fchown): UID and GID arguments are now unsigned.
      	(getuid): Return value is now unsigned.
      	(setuid): Argument is now unsigned.
      	(getpwuid): Remove prototype (it's declared in nt/inc/pwd.h).
      
      w32.c   (getpwuid): Change argument type to unsigned.
      	(struct w32_id): Change type of `rid' member to unsigned.
      	(w32_cached_id, w32_add_to_cache, get_name_and_id): Change type of
      	argument ID to unsigned.  All callers changed.
      	(getuid, geteuid, getgid, getegid): Change return type to unsigned.
      22749e9a
  15. 08 Jan, 2009 1 commit
  16. 04 Jan, 2009 1 commit
    • Juanma Barranquero's avatar
      * w32.c: Use 64-bit arithmetic to do FILETIME conversions. (Bug#1766) · 5da9424d
      Juanma Barranquero authored
        (utc_base): Declare as ULONGLONG, not long double.
        (convert_time_raw): Delete.
        (FILETIME_TO_U64, U64_TO_LISP_TIME): New macros.
        (initialize_utc_base): New function.
        (convert_time): Use FILETIME_TO_U64, initialize_utc_base.
        (convert_from_time_t): Use initialize_utc_base; compute result with
        64-bit arithmetic.
        (process_times): Use FILETIME_TO_U64, U64_TO_LISP_TIME.
      5da9424d
  17. 02 Jan, 2009 1 commit
  18. 19 Dec, 2008 1 commit
    • Dan Nicolaescu's avatar
      Reorganize implementation of Flist_system_processes and · 06e111a6
      Dan Nicolaescu authored
      Fsystem_process_attributes.  No functional changes.
      * process.c: Don't #include pwd.h, grp.h and limits.h.
      (Flist_system_processes): Just call list_system_processes.
      (Fsystem_process_attributes): Just call system_process_attributes.
      (procfs_list_system_processes, time_from_jiffies)
      (ltime_from_jiffies, get_up_time, procfs_ttyname, MAJOR, MINOR)
      (procfs_get_total_memory, procfs_system_process_attributes): Move ...
      
      * sysdep.c: ... here.  Include pwd.h, grp.h and limits.h.
      (list_system_processes): Rename from
      procfs_list_system_processes.  Enclose in #ifdef HAVE_PROCFS.
      Provide a do nothing implementation.
      (system_process_attributes): Rename from
      procfs_list_system_processes.
      (ltime_from_jiffies, get_up_time, procfs_ttyname, MAJOR, MINOR)
      (procfs_get_total_memory):  Enclose in #ifdef GNU_LINUX.
      
      * w32.c (list_system_processes): Rename from
      w32_list_system_processes.
      (system_process_attributes): Rename from
      w32_system_process_attributes.
      
      * s/gnu-linux.h (LISTPROC, PROCATTR): Remove.
      
      * process.h (w32_list_system_processes)
      (w32_system_process_attributes): Remove.
      (list_system_processes, system_process_attributes): New
      prototypes.
      
      * config.nt (LISTPROC, PROCATTR): Remove.
      06e111a6
  19. 03 Dec, 2008 1 commit
  20. 30 Aug, 2008 2 commits
  21. 15 Aug, 2008 4 commits
  22. 09 Aug, 2008 3 commits
    • Eli Zaretskii's avatar
    • Eli Zaretskii's avatar
      3af03101
    • Eli Zaretskii's avatar
      Include thelp32.h, psapi.h and coding.h. · 7c80d5ec
      Eli Zaretskii authored
      (_MEMORYSTATUSEX, _PROCESS_MEMORY_COUNTERS_EX): New struct declarations.
      (CreateToolhelp32Snapshot_Proc, Process32First_Proc, Process32Next_Proc): New
      typedefs.
      (g_b_init_create_toolhelp32_snapshot, g_b_init_process32_first)
      (g_b_init_process32_next, g_b_init_open_thread_token)
      (g_b_init_impersonate_self, g_b_init_revert_to_self)
      (g_b_init_get_process_memory_info, g_b_init_global_memory_status)
      (g_b_init_get_process_working_set_size)
      (g_b_init_global_memory_status_ex): New static variables.
      (globals_of_w32): Initialize them.
      (create_toolhelp32_snapshot, process32_first, process32_next)
      (open_thread_token, impersonate_self, revert_to_self)
      (get_process_memory_info, get_process_working_set_size)
      (global_memory_status, global_memory_status_ex): New wrapper functions.
      (w32_list_system_processes, w32_system_process_attributes)
      (enable_privilege, restore_privilege, ltime, process_times): New functions.
      (convert_time_raw): New function.
      (convert_time): Remove conversion of FILETIME into time in 100 nsec units,
      call convert_time_raw instead.
      7c80d5ec
  23. 01 Jul, 2008 1 commit
  24. 27 Jun, 2008 1 commit
  25. 14 Jun, 2008 1 commit
  26. 13 Jun, 2008 1 commit
    • Glenn Morris's avatar
      Daniel Engeler <engeler at gmail.com> · d888760c
      Glenn Morris authored
      These changes add serial port access.
      * process.c: Add HAVE_SERIAL.
      (Fdelete_process, Fprocess_status, Fset_process_buffer)
      (Fset_process_filter, Fset_process_sentinel, Fprocess_contact)
      (list_processes_1, select_wrapper, Fstop_process)
      (Fcontinue_process, Fprocess_send_eof, kill_buffer_processes)
      (status_notify): Modify to handle serial processes.
      [HAVE_SERIAL] (Fserial_process_configure)
      [HAVE_SERIAL] (make_serial_process_unwind, Fmake_serial_process):
      New functions.
      * process.h (struct Lisp_Process): Add `type'.
      * sysdep.c [HAVE_TERMIOS] (serial_open, serial_configure):
      New functions.
      * w32.c (_sys_read_ahead, sys_read, sys_write): Modify to handle serial ports.
      (serial_open, serial_configure) New functions.
      * w32.h: Add FILE_SERIAL.
      (struct _child_process): Add ovl_read, ovl_write.
      d888760c
  27. 02 Jun, 2008 1 commit
    • Jim Meyering's avatar
      Make "xfree (NULL)" a no-op; remove useless if-before-xfree. · 70fdbb46
      Jim Meyering authored
      * src/alloc.c (xfree): Return right away for a NULL arg.
      * src/lread.c (nosuffix): Remove now-useless if-before-xfree tests.
      * src/gtkutil.c (xg_gtk_scroll_destroy): Likewise.
      * src/mac.c (create_apple_event_from_event_ref): Likewise.
      (create_apple_event_from_drag_ref, cfstring_create_normalized): Likewise.
      * src/doprnt.c (doprnt1): Likewise.
      * src/frame.c (frame): Likewise.
      * src/keyboard.c (wipe_kboard): Likewise.
      * src/macterm.c (x_free_frame_resources, xlfdpat_destroy, XFreePixmap):
      (init_font_name_table, mac_unload_font, x_delete_display): Likewise.
      * src/term.c (tty_default_color_capabilities, maybe_fatal)
      (delete_tty): Likewise.
      * src/w16select.c (string): Likewise.
      * src/w32.c (w32_get_resource, SET_ENV_BUF_SIZE): Likewise.
      * src/w32bdf.c (w32_free_bdf_font): Likewise.
      * src/w32fns.c (w32_unload_font): Likewise.
      * src/w32font.c (w32font_close): Likewise.
      * src/window.c (size_window): Likewise.
      * src/xselect.c (receive_incremental_selection): Likewise.
      * src/xterm.c (x_free_frame_resources, x_delete_display): Likewise.
      * src/mactoolbox.c (create_apple_event_from_drag_ref): Likewise.
      * src/w32.c (stat): Likewise.
      70fdbb46
  28. 24 May, 2008 1 commit
  29. 22 May, 2008 1 commit
  30. 14 May, 2008 1 commit
  31. 10 May, 2008 1 commit
  32. 09 May, 2008 2 commits
    • Eli Zaretskii's avatar
      (stat): Fix last change. · 2a85f0c2
      Eli Zaretskii authored
      2a85f0c2
    • Eli Zaretskii's avatar
      Support for reporting owner and group of each file on MS-Windows: · 8aaaec6b
      Eli Zaretskii authored
      	* dired.c (stat_uname, stat_gname): New functions, with special
      	implementation for w32.
      	(Ffile_attributes): Use them instead of getpwuid and getgrgid.
      
      	* w32.c:
      	(g_b_init_get_file_security, g_b_init_get_security_descriptor_owner)
      	(g_b_init_get_security_descriptor_group, g_b_init_is_valid_sid):
      	New initialization states.
      	(globals_of_w32): Initialize them to zero.  Initialize the default
      	group name to "None".
      	(GetFileSecurity_Name): New global var, the name of the function
      	to call for GetFileSecurity.
      	(GetFileSecurity_Proc, GetSecurityDescriptorOwner_Proc)
      	(GetSecurityDescriptorGroup_Proc, IsValidSid_Proc): New typedefs.
      	(get_file_security, get_security_descriptor_owner)
      	(get_security_descriptor_group, is_valid_sid)
      	(get_file_security_desc, get_rid, get_name_and_id)
      	(get_file_owner_and_group): New functions.
      	(stat): Use get_file_security_desc and get_file_owner_and_group to
      	report the owner and primary group of each file.  Don't ignore the
      	high 32 bits of file's size, now that st_size is 64-bit wide.  Fix
      	test when to get true file attributes.
      	(init_user_info): Use get_rid instead of equivalent inline code.
      	(fstat): Don't ignore the high 32 bits of file's size.
      8aaaec6b