| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
pdev to non-NULL on success instead of unconditonally
setting it and maybe resetting it later.
Submitted by: Christoph Mallon
MFC after: 3 days
|
|
|
|
|
|
|
| |
fails, so there is no need to do it again after returning.
Submitted by: Christoph Mallon
MFC after: 3 days
|
|
|
|
|
| |
Reviewed by: many
Approved by: des
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
vs. the comment documented "If we are working with a privileged socket,
then take only one attempt". Make the code match.
Furthermore, critical privileged applications that [over] log a vast amount
can look like a DoS to this code. Given it's unlikely the single reattempted
send() will succeeded, avoid usurping the scheduler in a library API for a
single non-critical facility in critical applications.
Obtained from: Juniper Networks
Discussed with: glebius
|
| |
|
|
|
|
|
|
|
| |
implementation.
- Add symlink /usr/include/edit/readline/tilde.h -> readline.h
All this makes it possible to build and link gdb with -ledit.
|
|
|
|
| |
The former allows common settings from ../Makefile.inc to be used.
|
|
|
|
|
| |
MFC after: 3 days
Sponsored by: Google, Inc.
|
|
|
|
|
|
| |
Also add the license from upstream to contrib.
Approved by: dim (mentor)
|
|
|
|
| |
Approved by: dim (mentor)
|
|
|
|
|
|
|
|
|
| |
than silently failing and returning success.
Without this, code calls pthread_once(), receives a return value of
success, and thinks that the passed function has been called.
Approved by: dim (mentor)
|
|
|
|
|
|
|
|
| |
not disabled in the usual way (by adding it to __DEFAULT_NO_OPTIONS in
share/mk/bsd.own.mk), and because the test for MK_LIBCPLUSPLUS in
Makefile.inc1 was incorrect.
Pointy hat to: dim
|
|
|
|
|
|
|
|
|
|
|
| |
MK_LIBCPLUSPLUS=yes to enable). This is a work-in-progress. It works for
me, but is not guaranteed to work for anyone else and may eat your dog.
To build C++ using libc++, add -stdlib=libc++ to your CXX and LD flags.
Bug reports welcome, bug fixes even more welcome...
Approved by: dim (mentor)
|
|
|
|
|
|
| |
but we use STATIC_CFLAGS instead of our own private .c.o rule.
MFC after: 3 weeks
|
|
|
|
| |
Reviewed by: delphij
|
|
|
|
| |
MFC after: 2 weeks
|
|
|
|
|
|
|
| |
locale components.
Reported by: Michael Butler
Approved by: dim (mentor)
|
|
|
|
|
|
|
| |
- add a comment explaining why I used '|' instead of '||'
Submitted by: danfe@
Approved by: emaste@
|
|
|
|
|
|
|
|
|
| |
- while here change 's' to 's1' in strcoll
Submitted by: eadler@
Reviewed by: theraven@
Approved by: brooks@
MFC after: 2 weeks
|
|
|
|
|
|
| |
needed.
Approved by: brooks (mentor)
|
|
|
|
|
|
|
| |
on the shared library. The modules are loaded by the library, so we
know it'll be there when we need it.
MFC after: 3 weeks
|
|
|
|
|
|
| |
PR: docs/162719
Submitted by: Niclas Zeising <niclas at zeising gmail>
MFC after: 1 week
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
system calls to provide feed-forward clock management capabilities to
userspace processes. ffclock_getcounter() returns the current value of the
kernel's feed-forward clock counter. ffclock_getestimate() returns the current
feed-forward clock parameter estimates and ffclock_setestimate() updates the
feed-forward clock parameter estimates.
- Document the syscalls in the ffclock.2 man page.
- Regenerate the script-derived syscall related files.
Committed on behalf of Julien Ridoux and Darryl Veitch from the University of
Melbourne, Australia, as part of the FreeBSD Foundation funded "Feed-Forward
Clock Synchronization Algorithms" project.
For more information, see http://www.synclab.org/radclock/
Submitted by: Julien Ridoux (jridoux at unimelb edu au)
|
|
|
|
| |
import, it works without issue.
|
|
|
|
|
|
|
|
|
|
|
|
| |
is unencrypted. This defeats the nullok check, because it means a
non-null passphrase will successfully unlock the key.
To address this, try at first to load the key without a passphrase.
If this succeeds and the user provided a non-empty passphrase *or*
nullok is false, reject the key.
MFC after: 1 week
Noticed by: Guy Helmer <guy.helmer@palisadesystems.com>
|
|
|
|
|
|
|
| |
Retire the the now unused sctp_udp_tunneling_for_client_enable
sysctl variable.
MFC after: 3 months.
|
|
|
|
|
|
|
|
|
|
|
|
| |
load of _l suffixed versions of various standard library functions that use
the global locale, making them take an explicit locale parameter. Also
adds support for per-thread locales. This work was funded by the FreeBSD
Foundation.
Please test any code you have that uses the C standard locale functions!
Reviewed by: das (gdtoa changes)
Approved by: dim (mentor)
|
|
|
|
|
| |
Reported by: slonoman2011 yandex ru
MFC after: 1 week
|
|
|
|
|
|
| |
bug fixes by Kuan-Chung Chiu <buganini at gmail dot com>.
Tested by me in production for several days at work.
|
|
|
|
|
|
|
|
|
|
|
| |
allow the built-in operations to be redefined, at least not without
excessive force).
Instead, just disable LLVM's support for atomic operations for now.
Nothing in either clang or the tablegen tools currently depends on it.
This still allows users of head built before r198344 to upgrade to
top-of-head seamlessly.
|
|
|
|
|
| |
Submitted by: arundel
MFC after: 3 days
|
|
|
|
|
|
|
|
|
| |
timeout correctly for pthread_cond_timedwait when
it uses kernel-based condition variable.
PR: 162403
Submitted by: jilles
MFC after: 3 days
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
change here is to ensure that when a process forks after arc4random
is seeded, the parent and child don't observe the same random sequence.
OpenBSD's fix introduces some additional overhead in the form of a
getpid() call. This could be improved upon, e.g., by setting a flag
in fork(), if it proves to be a problem.
This was discussed with secteam (simon, csjp, rwatson) in 2008, shortly
prior to my going out of town and forgetting all about it. The conclusion
was that the problem with forks is worrisome, but it doesn't appear to
have introduced an actual vulnerability for any known programs.
The only significant remaining difference between our arc4random and
OpenBSD's is in how we seed the generator in arc4_stir().
|
|
|
|
|
|
|
|
|
|
| |
OpenBSD's version (r1.22). While some of our style changes were
indeed small improvements, being able to easily track functionality
changes in OpenBSD seems more useful.
Also fix style bugs in the FreeBSD-specific parts of this file.
No functional changes, as verified with md5.
|
|
|
|
|
|
|
| |
C++'s <cmath> to work without the compiler complaining that the C++ versions are calling implicitly-declared functions. You will still get a linker error when they are called. OpenBSD 5.0 claims to fully implement the C99 <math.h> stuff, so might be worth investigating...
Reviewed by: das
Approved by: dim (mentor)
|
|
|
|
|
|
| |
and encoded wint_t.
Spotted by: ache
|
| |
|
|
|
|
|
|
|
| |
- Fix types of function arguments match their declaration
Reviewed by: delphij
Obtained from: NetBSD
|
|
|
|
|
|
|
| |
Some header file parts of this patch were taken from a patch submitted
by Maya Erez <merez@codeaurora.org> to the LibUSB developers list.
MFC after: 1 week
|
|
|
|
|
|
|
|
|
|
| |
Some consumers of PAM remove the /dev/ component (i.e. login), while
others don't (i.e. su). We must ensure that the /dev/ component is
removed to ensure that the utmpx entries properly work with tools such
as w(1).
Discussed with: des
MFC after: 1 week
|
|
|
|
|
|
|
|
|
|
|
| |
to be gcc's default before r198344, calls to atomic builtins will not be
expanded inline. Instead, they will be generated as calls to external
functions (e.g. __sync_fetch_and_add_N), leading to linking errors later
on.
Put in a seatbelt that disables use of atomic builtins in libstdc++ and
llvm, when tuning specifically for the real i386 CPU. This does not
protect against all possible issues, but it is better than nothing.
|
|
|
|
|
|
|
|
| |
This variable was added in r82352 back in 2001, but even then it didn't
have any use. Because it's not marked static, the C compiler won't
complain about it.
Discussed with: des
|
|
|
|
|
|
| |
The size passed to strlcat() must depend on the input length, not the
output length. Because the input and output buffers are equal in size,
the resulting binary does not change at all.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
madvise(2) except that it operates on a file descriptor instead of a
memory region. It is currently only supported on regular files.
Just as with madvise(2), the advice given to posix_fadvise(2) can be
divided into two types. The first type provide hints about data access
patterns and are used in the file read and write routines to modify the
I/O flags passed down to VOP_READ() and VOP_WRITE(). These modes are
thus filesystem independent. Note that to ease implementation (and
since this API is only advisory anyway), only a single non-normal
range is allowed per file descriptor.
The second type of hints are used to hint to the OS that data will or
will not be used. These hints are implemented via a new VOP_ADVISE().
A default implementation is provided which does nothing for the WILLNEED
request and attempts to move any clean pages to the cache page queue for
the DONTNEED request. This latter case required two other changes.
First, a new V_CLEANONLY flag was added to vinvalbuf(). This requests
vinvalbuf() to only flush clean buffers for the vnode from the buffer
cache and to not remove any backing pages from the vnode. This is
used to ensure clean pages are not wired into the buffer cache before
attempting to move them to the cache page queue. The second change adds
a new vm_object_page_cache() method. This method is somewhat similar to
vm_object_page_remove() except that instead of freeing each page in the
specified range, it attempts to move clean pages to the cache queue if
possible.
To preserve the ABI of struct file, the f_cdevpriv pointer is now reused
in a union to point to the currently active advice region if one is
present for regular files.
Reviewed by: jilles, kib, arch@
Approved by: re (kib)
MFC after: 1 month
|
| |
|
|
|
|
|
|
|
|
| |
the word alignment, some versions of gcc do require 16-byte alignment.
Make sure the stack is 16-byte aligned before calling a subroutine.
Inspired by: PR amd64/162214
MFC after: 1 week
|
|
|
|
|
|
|
|
|
| |
as it is required by amd64 ABI. Add a comment for the places were
the stack is accidentally properly aligned already.
PR: amd64/162214
Submitted by: yamayan <yamayan kbh biglobe ne jp>
MFC after: 1 week
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When booting the system, truncate the utx.active file, but do write the
BOOT_TIME record into it afterwards. This allows one to obtain the boot
time of the system as follows:
struct utmpx u1 = { .ut_type = BOOT_TIME }, *u2;
setutxent();
u2 = getutxid(&u1);
Now, the boot time is stored in u2->ut_tv, just like on Linux and other
systems.
We don't open the utx.active file with O_EXLOCK. It's rather unlikely
that other applications use this database at the same time and I want to
prevent the possibility of deadlocks in init(8).
Discussed with: pluknet
|