| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
Notes:
svn path=/head/; revision=30483
|
| |
|
|
|
|
|
|
| |
were a workaround for limitations in bsd.man.mk that were fixed about
2 years ago.
Notes:
svn path=/head/; revision=30482
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The names of m-d variants are now added (manually) to MDSRCS instead
of to SRCS, and the names of all machine-independent (m-i) variants
that can reasonably be replaced by an m-d variant are now added
(manually) to MISRCS instead of to SRCS, so that a simple substitution
can be used to discard the unused m-i variants. MISRCS is potentially
all m-i sources, but the substitution is too simple to be fast, so
MISRCS should be kept reasonably small.
libc/Makefile.inc:
Do the substitution.
libc/i386/string/Makefile.inc:
Add to MDSRCS instead of to SRCS. Add the names of all sources in this
directory, but no others.
libc/string/Makefile.inc
Add to MISRCS instead of to SRCS. Add the names of all sources in this
directory. Don't use (broken) explicit rules for special cases.
Notes:
svn path=/head/; revision=30481
|
| |
|
|
| |
Notes:
svn path=/head/; revision=30480
|
| |
|
|
| |
Notes:
svn path=/head/; revision=30479
|
| |
|
|
| |
Notes:
svn path=/head/; revision=30457
|
| |
|
|
| |
Notes:
svn path=/head/; revision=30448
|
| |
|
|
|
|
|
|
| |
were a workaround for limitations in bsd.man.mk that were fixed about
2 years ago.
Notes:
svn path=/head/; revision=30447
|
| |
|
|
|
|
|
|
| |
between sources and objects. This will be used to avoid messy
special cases in Makefile.inc.
Notes:
svn path=/head/; revision=30444
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
for the entire time that it was there, so obviously nothing needs it
anymore.
Note, unix98/single-unix spec v2 says that usleep() returns an int rather
than a void, to indicate whether the entire time period elapsed (0) or an
error (eg: signal handler) interrupted it (returns -1, errno = EINTR)
It is probably useful to make this change but I'll test it locally first
to see if this will break userland programs [much]...
Reviewed by: ache, bde
Notes:
svn path=/head/; revision=30443
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
back to the original single nanosleep() implementation. This is POSIX and
Unix98 (aka single-unix spec v2) compliant behavior. If a program sets
alarm(2) or an interval timer (setitimer(2)) without a SIGALRM handler
being active, sleep(3) will no longer absorb it, and the program will get
what it asked for..... :-]
The original reason for this in the first place (apache) doesn't seem to
need it anymore, according to Andrey.
Reviewed by: ache, bde
Notes:
svn path=/head/; revision=30442
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
made to the RPC code some months ago. The value of __svc_fdsetsize is being
calculated incorrectly.
Logically, one would assume that __svc_fdsetsize is being used as a
substitute for FD_SETSIZE, with the difference being that __svc_fdsetsize
can be expanded on the fly to accomodate more descriptors if need be.
There are two problems: first, __svc_fdsetsize is not initialized to 0.
Second, __svc_fdsetsize is being calculated in svc.c:xprt_registere() as:
__svc_fdsetsize = howmany(sock+1, NFDBITS);
This is wrong. If we are adding a socket with index value 4 to the
descriptor set, then __svc_fdsetsize will be 1 (since fds_bits is
an unsigned long, it can support any descriptor from 0 to 31, so we
only need one of them). In order for this to make sense with the
rest of the code though, it should be:
__svc_fdsetsize = howmany(sock+1, NFDBITS) * NFDBITS;
Now if sock == 4, __svc_fdsetsize will be 32.
This bug causes 2 errors to occur. First, in xprt_register(), it
causes the __svc_fdset descriptor array to be freed and reallocated
unnecessarily. The code checks if it needs to expand the array using
the test: if (sock + 1 > __svc_fdsetsize). The very first time through,
__svc_fdsetsize is 0, which is fine: an array has to be allocated the
first time out. However __svc_fdsetsize is incorrectly set to 1, so
on the second time through, the test (sock + 1 > __svc_fdsetsize)
will still succeed, and the __svc_fdset array will be destroyed and
reallocated for no reason.
Second, the code in svc_run.c:svc_run() can become hopelessly confused.
The svc_run() routine malloc()s its own fd_set array using the value
of __svc_fdsetsize to decide how much memory to allocate. Once the
xprt_register() function expands the __svc_fdset array the first time,
the value for __svc_fdsetsize becomes 2, which is too small: the resulting
calculation causes the code to allocate an array that's only 32 bits wide
when it actually needs 64 bits. It also uses the valuse of __svc_fdsetsize
when copying the contents of the __svc_fdset array into the new array.
The end result is that all but the first 32 file descriptors get lost.
Note: from what I can tell, this bug originated in OpenBSD and was
brought over to us when the code was merged. The bug is still there
in the OpenBSD source.
Total nervous breakdown averted by: Electric Fence 2.0.5
Notes:
svn path=/head/; revision=30420
|
| |
|
|
|
|
|
| |
Sorted SRCS.
Notes:
svn path=/head/; revision=30401
|
| |
|
|
| |
Notes:
svn path=/head/; revision=30400
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
to POSIX.2. In particular:
- don't retry for ETXTBSY. This matches what sh(1) does. The retry code
was broken anyway. It only slept for several seconds for the first few
retries. Then it retried without sleeping.
- don't abort the search for errors related to the path prefix, in
particular for ENAMETOOLONG, ENOTDIR, ELOOP. This fixes PR1487. sh(1)
gets this wrong in the opposite direction by never aborting the search.
- don't confuse EACCES for errors related to the path prefix with EACCES
for errors related to the file. sh(1) gets this wrong.
- don't return a stale errno when the search terminates normally without
finding anything. The errno for the last unsuccessful execve() was
usually returned. This gave too much precedence to pathologies in the
last component of $PATH. This bug is irrelevant for sh(1).
The implementation still uses the optimization/race-inhibitor of trying
to execve() things first. POSIX.2 seems to require looking at file
permissions using stat(). We now use stat() after execve() if execve()
fails with an ambiguous error. Trying execve() first may actually be a
pessimization, since failing execve()s are fundamentally a little slower
than stat(), and are significantly slower when a file is found but has
unsuitable permissions or points to an unsuitable interpreter.
PR: 1487
Notes:
svn path=/head/; revision=30399
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
'slow' lookup if we get a YPERR_MAP (no such map in server's domain) error
instead of failing over on any error. In the latter case, if the 'fast'
search fails legitimately (i.e. the user or host really isn't a member
of the specified netgroup) then we end up doing the 'slow' search and
failing all over again. The result is still correct, but cycles are
consumed for no good reason.
Also removed the #ifdef CHARITABLE since the compat kludge is no longer
optional.
Notes:
svn path=/head/; revision=30390
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
that if searching through the special netgroup.byhost or netgroup.byuser
maps didn't work, we would roll over to the 'slow' method of grovelling
though the netgroup map and working out the dependencies on the fly.
But I left this option hidden inside an #ifdef CHARITABLE since I
didn't think I'd ever need it.
Well, the Sun rpc.nisd NIS+ server in YP compat mode doesn't support
the .byhost and .byuser reverse maps, so the failover is necessary
in order to be compatible. *sigh*
This closes PR #3891, and should be merged into RELENG_2_2.
Notes:
svn path=/head/; revision=30288
|
| |
|
|
| |
Notes:
svn path=/head/; revision=30260
|
| |
|
|
|
|
|
| |
kernel for a few months.
Notes:
svn path=/head/; revision=30255
|
| |
|
|
|
|
|
|
| |
Added the conversion specifiers %g and %G, that are replaced
by the year which contains the greater part of the week in question.
Notes:
svn path=/head/; revision=30089
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29988
|
| |
|
|
|
|
|
| |
"fixing" it is not a good idea.
Notes:
svn path=/head/; revision=29941
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29908
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29907
|
| |
|
|
|
|
|
| |
Minor formatting
Notes:
svn path=/head/; revision=29885
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29858
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29857
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29856
|
| |
|
|
|
|
|
|
| |
Basic support for the Shift JIS encoding of japanese.
(and one tiny typo fixed in a comment)
Notes:
svn path=/head/; revision=29818
|
| |
|
|
|
|
|
| |
Submitted by: Dmitrij Tejblum <dima@tejblum.dnttm.rssi.ru>
Notes:
svn path=/head/; revision=29718
|
| |
|
|
|
|
|
|
| |
that are up on second (loopback only) pass, and only select non-loopback
AF_INET interfaces that are up on first pass.
Notes:
svn path=/head/; revision=29694
|
| |
|
|
|
|
|
|
|
|
|
|
| |
plain 0 should be used. This happens to work because we #define
NULL to 0, but is stylistically wrong and can cause problems
for people trying to port bits of code to other environments.
PR: 2752
Submitted by: Arne Henrik Juul <arnej@imf.unit.no>
Notes:
svn path=/head/; revision=29574
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29563
|
| |
|
|
|
|
|
|
|
|
| |
an unimplemented syscall returned ENOSYS, rather than EINVAL. I have run
statically linked code with this wrapper and it does appear to work fine
on 2.2-stable which doesn't have poll(). ktrace shows the poll syscall fail
once and the fallback to select() working.
Notes:
svn path=/head/; revision=29488
|
| |
|
|
|
|
|
|
| |
__getcwd(). I've got this libc code running on one of my machines
at the moment without the __getcwd() syscall being present.
Notes:
svn path=/head/; revision=29487
|
| |
|
|
|
|
|
| |
(`cvs diff -ib' print one new char ;-).
Notes:
svn path=/head/; revision=29479
|
| |
|
|
|
|
|
|
|
| |
important things to do ?? :-)
Prepare for the likely case of a change in kernel algorithm.
Notes:
svn path=/head/; revision=29476
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29462
|
| |
|
|
|
|
|
|
| |
PR: bin/4134
Submitted by: nick@foobar.org
Notes:
svn path=/head/; revision=29396
|
| |
|
|
|
|
|
|
| |
If your kernel doesn't support __getcwd() or if __getcwd() cannot
deliver because of cache expiry, it does the canonical thing.
Notes:
svn path=/head/; revision=29392
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
if necessary. This removes the need to malloc large fd_set's for selecting
on high fd's (larger than FD_SETSIZE at libc compile time).
The syscall adaptive stuff only happens on the very first call. SIGSYS
is masked, and if the call to poll fails with ENOSYS, then we use select
for the life of the program. If poll does not fail with ENOSYS, then we
always use poll and skip the once-off signal masking gunk.
This may be overkill, but it saved my neck a few times while working on
multiple different sets of kernel sources, some with poll, some without.
Notes:
svn path=/head/; revision=29380
|
| |
|
|
|
|
|
| |
Obtained from: NetBSD
Notes:
svn path=/head/; revision=29374
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29369
|
| |
|
|
|
|
|
| |
Make all the SA_* flags go into a tagged list, to improve readability.
Notes:
svn path=/head/; revision=29341
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29177
|
| |
|
|
| |
Notes:
svn path=/head/; revision=29176
|
| |
|
|
|
|
|
| |
Fortunately, the man page doesn't refer to "envp" so just deleting it is OK.
Notes:
svn path=/head/; revision=29049
|
| |
|
|
|
|
|
|
|
| |
Mention the capability in resolver(5).
Mention that RES_OPTIONS can be used in resolver(5).
Discussed with: -hackers
Notes:
svn path=/head/; revision=28982
|
| |
|
|
| |
Notes:
svn path=/head/; revision=28970
|
| |
|
|
|
|
|
|
| |
Reviewed by: phk
Submitted by: jdp
Notes:
svn path=/head/; revision=28952
|