aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* pflocal: fix message flags on receiveRichard Braun2013-10-181-2/+1
| | | | | * pflocal/socket.c (S_socket_recv): Set the memory pointed by out_flags to 0 instead of the pointer.
* pflocal: fix port leak when receiving port rightsRichard Braun2013-10-181-1/+1
| | | | | | | | | | | | The socket_send and socket_recv routines can be used to transmit port rights along data. Unfortunately, pflocal retains a copy of these rights in the socket_recv RPC. These lingering references would in turn lead to other leaks in servers waiting for a no-sender notification to clean their resources. Since these copied rights aren't used at all by the server, it is safe to simply move them to the recipient instead. * pflocal/socket.c (S_socket_recv): Transmit port rights using MACH_MSG_TYPE_MOVE_SEND transfer type instead of MACH_MSG_TYPE_COPY_SEND.
* libdiskfs: fix removal of socket nodesRichard Braun2013-10-182-1/+7
| | | | | | | | | | | | | | | | | When the file system supports ifsock shortcuts, a socket node can obtain a right on a socket address. This reference is only lost if the address is destroyed, through a dead-name notification. On the other hand, pflocal keeps the address around until all references are dropped. This leads to a situation where socket nodes, addresses, and their associated sockets are leaked. To remedy the situation, make addresses get a light reference on socket nodes, and properly deallocate it when the node is destroyed, which will in turn make pflocal correctly remove the matching address and socket. * libdiskfs/ifsock.c (diskfs_S_ifsock_getsockaddr): Add a light reference instead of a hard one. * libdiskfs/node-nput.c (diskfs_nput): Deallocate right to socket address when cleaning light references.
* pflocal: fix destruction of explicitely bound socketsRichard Braun2013-10-181-1/+5
| | | | | | | | | Sockets must have a weak reference on the address they're bound to so that addr_unbind is properly called before addr_clean. For sockets that are automatically bound, this weak reference is created in ensure_addr. Do the same in sock_bind. * pflocal/sock.c (sock_bind): Handle weak reference on addr.
* term: fix read on a closed PTYRichard Braun2013-10-141-0/+6
| | | | * term/ptyio.c (pty_io_read): Return EIO if the terminal has been closed.
* console-client: replace function epilogue with console_exitJustus Winter2013-10-131-2/+1
| | | | * console-client/console.c (main): Replace epilogue with console_exit.
* console-client: minor stylistic fixJustus Winter2013-10-131-1/+1
| | | | * console-client/console.c (main): Minor stylistic fix.
* console-client: fix error handlingJustus Winter2013-10-131-0/+1
| | | | | | | Fix the error handling in console_move_mouse. This also appeases the compiler. * console-client/console.c (console_move_mouse): Fix error handing.
* console-client: entitle console_exit with the noreturn attributeJustus Winter2013-10-131-1/+1
| | | | * console-client/input.h (console_exit): Add noreturn attribute.
* console-client: remove the pid file on clean exitsJustus Winter2013-10-131-0/+5
| | | | | | | | Remove the pid file if the console client exits either cleanly using console_exit or because of an error during daemonization. * console-client/console.c (console_exit): Remove the pid file. (daemon_error): Likewise.
* libfshelp: properly free active translator entriesJustus Winter2013-10-081-1/+4
| | | | | | | Previously the dynamically allocated field name leaks. Fix this by properly freeing the objects of type struct translator. * libfshelp/translator-list.c (translator_ihash_cleanup): Fix memory leak.
* trans: rename a global variableJustus Winter2013-10-081-8/+8
| | | | | | | Rename the global variable "path" to "target_path" to make it more unambiguous. * trans/mtab.c: Rename global variable "path".
* Revert "tmpfs: drop privileges in the tmpfs translator"Justus Winter2013-10-081-6/+0
| | | | | | | | | | | | | | | This reverts commit 7075bc11289355478659cd1610632a9299734afc. Dropping the unix privileges of the tmpfs translator causes problems with the passive translator startup. The function fshelp_fetch_root creates an auth handle containing the processes original UID and GID. But if the privileges were dropped before, this operation fails with EPERM. This commit also broke mkfifo(3), possibly for similar or related reasons. * tmpfs/tmpfs.c (main): Do not drop all privileges.
* Fix memory leak in execRichard Braun2013-10-081-0/+1
| | | | * exec/hashexec.c (check_hashbang): Unmap command arguments.
* Fix memory leak in libnetfsRichard Braun2013-10-041-3/+1
| | | | | * libnetfs/dir-lookup.c (netfs_S_dir_lookup): Properly jump to the single exit point if fshelp_fetch_root fails.
* Check for negative sizes in file_set_sizeRichard Braun2013-10-027-1/+13
| | | | | | | | | | | * libdiskfs/file-set-size.c (diskfs_S_file_set_size): Return EINVAL if size is negative. * libnetfs/file-set-size.c (netfs_S_file_set_size): Likewise. * libtreefs/s-file.c (treefs_S_file_set_size): Likewise. * storeio/io.c (trivfs_S_file_set_size): Likewise. * term/users.c (trivfs_S_file_set_size): Likewise. * trans/null.c (trivfs_S_file_set_size): Likewise. * trans/streamio.c (trivfs_S_file_set_size): Likewise.
* Fix memory leak in libdiskfsRichard Braun2013-09-281-3/+1
| | | | | * libdiskfs/dir-lookup.c (diskfs_S_dir_lookup): Properly jump to the single exit point if fshelp_fetch_root fails.
* GNU Hurd 0.5.Thomas Schwinge2013-09-276-66/+74
| | | | | | | | | | * configure.ac (AC_INIT): Set version to 0.5. (AC_REVISION): Remove. * NEWS: Finalize changes for 0.5. * INSTALL: Update. * INSTALL-cross: Likewise. * README.CVS: Delete, but move some content... * README: ... here. Update.
* Decouple the Hurd version from the package version.Thomas Schwinge2013-09-275-10/+13
| | | | | | | | * config.make.in (package-version): New variable. (hurd-version): Set to 0.3. * Makeconf (%: %.sh): Use package-version instead of hurd-version. * Makefile (stamp-version): Likewise. * doc/Makefile (stamp-version): Likewise.
* Generate ChangeLog files for distributions.Thomas Schwinge2013-09-272-5/+512
| | | | | | | | * gitlog-to-changelog: New file; import from gnulib's 9fc81090f6c5590bd1b0e0fa5087577a2ee43a3e:build-aux/gitlog-to-changelog. * Makefile (ChangeLog.tar, gen-ChangeLog): New targets. ($(dist-version).tar): Depend on and use the former. (clean-misc): Clean up the generated files.
* UFS is no more.Thomas Schwinge2013-09-271-4/+0
| | | | | | | * ChangeLog: Don't refer to bsdfsck/ChangeLog, ufs/ChangeLog, ufs-fsck/ChangeLog, ufs-utils/ChangeLog. Fixup for commit 84cf9c0f312637b670cc87224ff7e7c4da659e36.
* * ChangeLog: Don't refer to serverboot/ChangeLog; it is no more.Thomas Schwinge2013-09-271-1/+0
| | | | Fixup for commit a8744157214a302d84c8959b1ae99abe3ae2d7d2.
* Update mailing listsSamuel Thibault2013-09-261-4/+4
| | | | * README: Update mailing lists.
* Drop dead linksSamuel Thibault2013-09-241-2/+0
| | | | * doc/hurd.texi (BSD Unix FS): Remove link to dropped section.
* Fix missing renamesSamuel Thibault2013-09-241-3/+3
| | | | | * pflocal/sock.c (sock_connect, sock_shutdown): Rename SOCK_CONNECTED to PFLOCAL_SOCK_CONNECTED.
* Add --without-daemon option to configureSamuel Thibault2013-09-241-3/+10
| | | | | * configure.ac (--without-daemon): Add option to disable libdaemon pkgconfig test.
* Fix spurious port deallocationSamuel Thibault2013-09-211-1/+0
| | | | | * utils/storeinfo.c (parse_opt): Do not deallocate `file` port, `store_free` does it already.
* include: make /hurd/proc PID 3Justus Winter2013-09-211-1/+1
| | | | | | | Using PID 0 is problematic for various reasons. Make /hurd/proc run as PID 3 instead. * include/pids.h: Make /hurd/proc PID 3.
* proc: do not hand out PID 0Justus Winter2013-09-211-1/+1
| | | | | | Using PID 0 causes various problems. This makes genpid skip PID 0. * proc/mgt.c (genpid): Start PIDs at 1.
* Fix sscanf format for c99Samuel Thibault2013-09-211-1/+1
| | | | | * utils/rpctrace.c (parse_msgid_list): Use %ms instead of %as in sscanf format.
* Fix gcc warningSamuel Thibault2013-09-211-0/+2
| | | | * console-client/pc-mouse.c (input_loop): Return NULL.
* Fix gcc warningSamuel Thibault2013-09-211-0/+1
| | | | * console-client/xkb/kstoucs.c (find_ucs): Return 0 by default.
* Fix gcc warningSamuel Thibault2013-09-211-0/+2
| | | | | * console-client/pc-kbd.c (gnumach_v1_input_next) [XKB_SUPPORT]: Do not define `up` and `sc` variables.
* Rename SOCK_* into PFLOCAL_SOCK_*Samuel Thibault2013-09-214-36/+36
| | | | | | | | | | To avoid conflicting with glibc's SOCK_* * pflocal/io.c, pflocal/sock.c, pflocal/sock.h, pflocal/socket.c: Rename SOCK_CONNECTED into PFLOCAL_SOCK_CONNECTED, SOCK_NONBLOCK into PFLOCAL_SOCK_NONBLOCK, SOCK_SHUTDOWN_READ into PFLOCAL_SOCK_SHUTDOWN_READ, SOCK_SHUTDOWN_WRITE into PFLOCAL_SOCK_SHUTDOWN_WRITE.
* Fix gcc warningSamuel Thibault2013-09-211-1/+1
| | | | | * pflocal/io.c (copy_time): Make `to_nsec` parameter a long * instead of an unsigned long *.
* Properly return errorSamuel Thibault2013-09-211-0/+3
| | | | | * isofs/pager.c (pager_read_page): Return error returned by `store_read`, if any.
* Fix gcc warningSamuel Thibault2013-09-211-1/+1
| | | | | * isofs/lookup.c (dirscanblock): Cast entry->name into const char * before passing to isonamematch.
* Fix gcc warningSamuel Thibault2013-09-211-1/+1
| | | | | * isofs/inode.c (read_disknode): Cast dr->date into char* before calling `isodate_915`.
* Fix test for block compressionSamuel Thibault2013-09-211-2/+2
| | | | | * ext2fs/dir.c (dirscanblock): Test ds->stat against LOOKING and COMPRESS, instead of ds->type.
* Fix gcc warningSamuel Thibault2013-09-211-1/+1
| | | | | * ext2fs/dir.c (dirscanblock): Test ds->type against LOOKUP instead of LOOKING. They happened to have the same value.
* Fix setting modem control linesSamuel Thibault2013-09-211-1/+1
| | | | | * term/hurdio.c (hurdio_mdmctl): Pass `newbits` intead of `oldbits` to `tioctl_tiocmods`.
* Fix gcc warningSamuel Thibault2013-09-211-1/+1
| | | | | * term/users.c (trivfs_S_io_read): Add parentheses to make expression evaluation priority clear.
* Fix S_tioctl_tiocsetd returning errorsSamuel Thibault2013-09-211-1/+1
| | | | * term/users.c (S_tioctl_tiocsetd): Properly return `err`.
* Fix test for term open modeSamuel Thibault2013-09-211-1/+1
| | | | | * term/users.c (S_term_open_ctty): Properly test for `openmodes` containing at least O_READ or O_WRITE.
* Fix gcc warningSamuel Thibault2013-09-211-1/+1
| | | | | * exec/hostarch.c (elf_machine_matches_host): Cast `&hostinfo` into host_info_t instead of natural_t *.
* Fix gcc warningSamuel Thibault2013-09-213-3/+3
| | | | | | * libfshelp/fshelp.h (fshelp_set_options): Make `argp` pointer const. * libfshelp/set-options.c (fshelp_set_options): Likewise. * doc/hurd.texi (fshelp_set_options): Likewise.
* Fix gcc warningSamuel Thibault2013-09-211-0/+1
| | | | * libpipe/pipe.c: Include <stdlib.h>
* Fix ENOMEM handling in *_make_peropenSamuel Thibault2013-09-212-15/+20
| | | | | | | * libdiskfs/peropen-make.c (diskfs_make_peropen): Move `strdup` before port reference modifications, to fix abortion. * libnetfs/make-peropen.c (netfs_make_peropen): Check for `malloc` failure. Move `strdup` before port reference modifications, to fix abortion.
* Fix gcc warning:Samuel Thibault2013-09-211-1/+1
| | | | | * libps/write.c (noise_write): Make `t` parameter a char * instead of unsigned char *.
* Fix gcc warningSamuel Thibault2013-09-211-2/+2
| | | | | | * libtrivfs/io-restrict-auth.c (listmember): Use uid_t type instead of int. (trivfs_S_io_restrict_auth): Make `i` variable an unsigned int, like the `num` field it is compared with