Searched hist:1.557 (Results 1 - 25 of 25) sorted by relevance
| /src/sys/kern/ | ||
| H A D | vfs_syscalls.c | 1.557 Sun Mar 05 14:40:32 GMT 2023 riastradh open(2): Don't map ERESTART to EINTR. If a file or device's open function returns ERESTART, respect that -- restart the syscall; don't pretend a signal has been delivered when it was not. If an SA_RESTART signal was delivered, POSIX does not allow it to fail with EINTR: SA_RESTART This flag affects the behavior of interruptible functions; that is, those specified to fail with errno set to [EINTR]. If set, and a function specified as interruptible is interrupted by this signal, the function shall restart and shall not fail with [EINTR] unless otherwise specified. If an interruptible function which uses a timeout is restarted, the duration of the timeout following the restart is set to an unspecified value that does not exceed the original timeout value. If the flag is not set, interruptible functions interrupted by this signal shall fail with errno set to [EINTR]. https://pubs.opengroup.org/onlinepubs/9699919799/functions/sigaction.html Nothing in the POSIX definition of open specifies otherwise. In 1990, Kirk McKusick added these lines with a mysterious commit message: Author: Kirk McKusick <mckusick> Date: Tue Apr 10 19:36:33 1990 -0800 eliminate longjmp from the kernel (for karels) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 7bc7b39bbf..d572d3a32d 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -14,7 +14,7 @@ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. * - * @(#)vfs_syscalls.c 7.42 (Berkeley) 3/26/90 + * @(#)vfs_syscalls.c 7.43 (Berkeley) 4/10/90 */ #include "param.h" @@ -530,8 +530,10 @@ copen(scp, fmode, cmode, ndp, resultfd) if (error = vn_open(ndp, fmode, (cmode & 07777) &~ S_ISVTX)) { crfree(fp->f_cred); fp->f_count--; - if (error == -1) /* XXX from fdopen */ - return (0); /* XXX from fdopen */ + if (error == EJUSTRETURN) /* XXX from fdopen */ + return (0); /* XXX from fdopen */ + if (error == ERESTART) + error = EINTR; scp->sc_ofile[indx] = NULL; return (error); } (found via this git import of the CSRG history: https://github.com/robohack/ucb-csrg-bsd/commit/cce2869b7ae5d360921eb411005b328a29c4a3fe) This change appears to have served two related purposes: 1. The fdopen function (the erstwhile open routine for /dev/fd/N) used to return -1 as a hack to mean it had just duplicated the fd; it was recently changed by Mike Karels, in kern_descrip.c 7.9, to return EJUSTRETURN, now defined to be -2, presumably to avoid a conflict with ERESTART, defined to be -1. So this change finished part of the change by Mike Karels to use a different magic return code from fdopen. Of course, today we use still another disgusting hack, EDUPFD, for the same purpose, so none of this is relevant any more. 2. Prior to April 1990, the kernel handled signals during tsleep(9) by longjmping out to the system call entry point or similar. In April 1990, Mike Karels worked to convert all of that into explicit unwind logic by passing through EINTR or ERESTART as appropriate, instead of setjmp at each entry point. However, it's not clear to me why this setjmp/longjmp and fdopen/-1/EJUSTRETURN renovation justifies unconditional logic to map ERESTART to EINTR in open(2). I suspect it was a mistake. In 2013, the corresponding logic to map ERESTART to EINTR in open(2) was removed from FreeBSD: r246472 | kib | 2013-02-07 14:53:33 +0000 (Thu, 07 Feb 2013) | 11 lines Stop translating the ERESTART error from the open(2) into EINTR. Posix requires that open(2) is restartable for SA_RESTART. For non-posix objects, in particular, devfs nodes, still disable automatic restart of the opens. The open call to a driver could have significant side effects for the hardware. Noted and reviewed by: jilles Discussed with: bde MFC after: 2 weeks Index: vfs_syscalls.c |
| /src/usr.bin/make/ | ||
| H A D | main.c | 1.562 Tue Dec 28 21:56:13 GMT 2021 rillig make: fix double-free in CLEANUP mode (since 2021.12.27.23.11.55) When make is run without the '-f' option, it searches for the files 'makefile' and 'Makefile' in the current directory. The function ReadFirstDefaultMakefile allocated memory for these filenames, added the filenames to opts.makefiles and then freed the memory. From that moment, opts.makefiles contained dangling pointers. The function main_CleanUp cleans the list, but only if make is compiled with -DCLEANUP. Since main.c 1.557 from 2021.12.27.23.11.55, the strings in opts.makefiles are freed as well, before that, only the list nodes were freed. Freeing the strings led to the double-free. Fix this bug by using a separate list for these short-lived strings. At the point where ReadFirstDefaultMakefile is called, opts.makefiles is not used anymore, therefore there are no side effects. To reproduce, run 'make test-coverage', which compiles with -DCLEANUP. The test opt-chdir failed with a segmentation fault in main_Cleanup. This test may be the only one that doesn't use the option '-f'. 1.557 Mon Dec 27 23:11:55 GMT 2021 rillig make: free the names of the makefiles in cleanup mode Since parse.c 1.576 from 2021-12-13 the filenames from opts.makefiles no longer end up in the GNodes, they are copied by Str_Intern. |
| H A D | parse.c | 1.557 Sun Apr 04 11:56:43 GMT 2021 rillig make: convert VarEvalFlags back into an enum, but not a bit-set As was apparent in VarEvalFlags_ToString, a bit-set was not the best data type since most of the flags were not freely combinable. The two flags that could be combined were keepDollar and keepUndef, but even these have distinguished names in the debug log. The downside of struct bit-fields is that they need extra helper functions in C90 (see nonints.h). Exchange these for a few helper functions in var.c, to keep the code outside var.c simple. No functional change. |
| H A D | var.c | 1.557 Sat Oct 03 10:13:39 GMT 2020 rillig make(1): clean up confusing code in Var_Export The generated code stays exactly the same. |
| /src/sys/sys/ | ||
| H A D | param.h | 1.557 Tue Jan 09 19:52:29 GMT 2018 christos branches: 1.557.2; Use a queue of deferred entries to delete routes instead of a fixed stack of 10. Otherwise we can overflow in route deletions from the rexmit timer. XXX: pullup-8 1.557 Tue Jan 09 19:52:29 GMT 2018 christos branches: 1.557.2; Use a queue of deferred entries to delete routes instead of a fixed stack of 10. Otherwise we can overflow in route deletions from the rexmit timer. XXX: pullup-8 |
| /src/distrib/notes/common/ | ||
| H A D | main | 1.557 Wed Nov 27 09:29:25 GMT 2019 martin More cleanup: - simplify TOC handling and remove arg limit (from uwe) - use Lk with explicit anchor text in some places - do not allow official release builds when we can not derive the proper date from the buildid |
| /src/sys/dev/usb/ | ||
| H A D | usbdevs | 1.557 Mon Jun 14 18:57:49 GMT 2010 riz Sort Sierra Wireless products by ID. |
| H A D | usbdevs.h | 1.557 Mon Oct 18 16:11:31 GMT 2010 sborrill Regen |
| H A D | usbdevs_data.h | 1.557 Fri Oct 01 21:08:28 GMT 2010 christos regen |
| /src/sys/arch/amd64/conf/ | ||
| H A D | GENERIC | 1.557 Sun Jan 19 20:00:37 GMT 2020 thorpej Remove Token Ring support. |
| /src/share/man/man4/ | ||
| H A D | Makefile | 1.557 Mon Apr 04 17:26:24 GMT 2011 bouyer Add a man page for rdcpcib(4). While there move rdcide.4 to i386/ |
| /src/sys/dev/pci/ | ||
| H A D | pcidevs.h | 1.557 Sun Jul 27 01:41:46 GMT 2003 jonathan Regen from pcidevs 1.555 (Bluesteel,Broadcom security coprocessors) |
| H A D | pcidevs_data.h | 1.557 Tue Jul 29 07:43:49 GMT 2003 martin Regen. |
| H A D | pcidevs | 1.557 Tue Jul 29 07:41:43 GMT 2003 martin Intel 8255GM is GM, not PM (obviously a copy&pasto). From FUKAUMI Naoki in PR 22293. |
| /src/usr.bin/xlint/lint1/ | ||
| H A D | tree.c | 1.557 Sun Jul 09 11:18:55 GMT 2023 rillig lint: clean up wording in diagnostics Use the term 'parameter' as defined in C99 3.15. |
| /src/sys/arch/i386/i386/ | ||
| H A D | machdep.c | 1.557 Thu Aug 05 18:04:35 GMT 2004 dbj fix several related bugs that cause sysctl machdep.diskinfo to lose when booted from pxeboot. . make sure that i386_alldisks gets initialized even if bios geometry information is not available in the bootinfo . if i386_alldisks is not initialized, have sysctl return EOPNOTSUPP . compile pxeboot with -DPASS_BIOSGEOM and I386_INCLUDE_DISK=yes this may increase the size of pxeboot which is required to run in 64k. However, it seems to be working ok on my system |
| /src/distrib/sets/lists/base/ | ||
| H A D | shl.mi | 1.557 Mon Nov 22 22:22:28 GMT 2010 christos bump libssh to 16 |
| H A D | mi | 1.557 Mon Jun 27 20:32:39 GMT 2005 peter Remove (pf)spamd. Its right to exist in NetBSD has been questioned since it appeared and whether it's really part of pf or not is still unclear. Looking at the other *BSDs it seems that they have left out spamd when importing pf, and now we do that too. Also, the name conflicted with another more popular used tool, after the rename to pfspamd it was left with completely unusable documentation which apparently no-one wanted to fix. A port of the latest spamd will be imported into pkgsrc soon. Suggested by several people, no objections on last proposal on tech-userlevel. |
| /src/doc/ | ||
| H A D | 3RDPARTY | 1.557 Wed Oct 17 06:57:12 GMT 2007 wiz gdb-6.7 out. |
| /src/sys/arch/i386/conf/ | ||
| H A D | GENERIC | 1.557 Mon Apr 21 00:17:46 GMT 2003 fvdl Add commented-out ahd driver. |
| /src/distrib/sets/lists/man/ | ||
| H A D | mi | 1.557 Tue Apr 15 19:46:38 GMT 2003 jdolecek add POSIX.2 patchchk(1) utility - check pathnames from FreeBSD via Jonathan Perkin fixes PR standards/11198 by Ben Harris |
| /src/distrib/sets/lists/tests/ | ||
| H A D | mi | 1.557 Tue Jan 14 17:53:02 GMT 2014 pgoyette Update sets list for new opencrypto test suite |
| /src/share/mk/ | ||
| H A D | bsd.own.mk | 1.557 Wed Feb 25 20:36:45 GMT 2009 sketch Make grep a host tool. |
| /src/sys/conf/ | ||
| H A D | files | 1.557 Sat Oct 05 15:16:10 GMT 2002 tsutsui Overhaul of fmv(4) driver: - Split if_fmv.c into MI/MD part and add ISA-PnP attachment for FMV-183. (XXX FMV-184 is not tested. It would require extra media-select functions..) - Fix probe functions of fmv_isa so that FMV-181A/182A will also match. Fixes port-i386/9476. |
| /src/distrib/sets/lists/comp/ | ||
| H A D | mi | 1.557 Sun Apr 06 18:27:52 GMT 2003 perry add des.h |
Completed in 1492 milliseconds