Commit Graph

11507 Commits

Author SHA1 Message Date
abhinav
e62bbc5df1 Avoid a call to strncmp when comparing only the first character of the string. 2017-04-30 08:41:18 +00:00
abhinav
116a5447e2 Bring the comment in sync with code (after changes brought by the last commit). 2017-04-29 16:49:51 +00:00
abhinav
c376a38e5b Don't parse Nm macro when it occurs anywhere outside the NAME section.
mandoc(3) already generates the text node representing the value for the .Nm macro.
Doing our own parsing for .Nm on top of that leads to large duplication of text
in the database. This gets specially worse for man pages with large NAME sections,
such as queue(3).
2017-04-29 14:43:09 +00:00
abhinav
231f71fb95 Disable the database compression if DEBUG is defined.
When debugging makemandb(8), it helps to be able to view the text being
stored in the database.
2017-04-27 08:02:24 +00:00
abhinav
b2c6ef38f4 Teach whatis(1) to handle MLINKS
Similar to apropos(1), whatis did not utilise the mandb_links table till now.
Therefore, if it was asked about one of the links to a man page, it would
error out. This change teaches whatis(1) to look up both the FTS table
as well as the links table, thus ensuring that it is able to answer queries
about MLINKS as well.

Comparision between outputs before this change and after this change:

#Before change
$ whatis realloc
realloc: not found

#after change
$ ./whatis realloc
realloc(3) - general memory allocation operations
realloc(3) - general purpose memory allocation functions
realloc(9) - general-purpose kernel memory allocator
2017-04-23 16:56:49 +00:00
abhinav
e70b83fc18 Better handle MLINKS in apropos(1).
apropos(1) only indexes the first .Nm entry from the NAME section in the full
text index. Rest of the .Nm entries are stored in a separate table: mandb_links.

Till now apropos(1) did not use the mandb_links table. So whenever a query
was being made for one of the man page links, such as realloc(3), it was showing
malloc(3) in the results but not as the first result. And, also the result would
show up as malloc(3), rather than realloc(3) (which can be confusing).

With this change, for single keyword queries, apropos(1) would now utilise the
mandb_links table as well. If the query is for one of the links of a man page,
it would show as the first result. Also, the result would show up as the name
of the link rather than the original man page name. For example, if the query
was for realloc, the output would be realloc(3), rather than malloc(3).

Following are some example queries showing difference in the output before this
change and after this change:

#Before changes
$ apropos -n 5 -M realloc
reallocarr (3)    reallocate array
reallocarray (3)  reallocate memory for an array of elements checking
for overflow
fgetwln (3)       get a line of wide characters from a stream
fgetln (3)        get a line from a stream
posix_memalign (3)        aligned memory allocation

#After changes
$ ./apropos -n 5 -M realloc
realloc (3)       general memory allocation operations
realloc (3)       general purpose memory allocation functions
realloc (9)       general-purpose kernel memory allocator
reallocarr (3)    reallocate array
reallocarray (3)  reallocate memory for an array of elements checking
for overflow

#Before changes
$ apropos -n 5 -M TAILQ_REMOVE
SLIST_HEAD (3) implementations of singly-linked lists, lists, simple
queues, tail queues, and singly-linked tail queues

#After changes
$ ./apropos -n 5 -M TAILQ_REMOVE
TAILQ_REMOVE (3)  implementations of singly-linked lists, lists,
simple queues, tail queues, and singly-linked tail queues

#Before changes
$ apropos -n 5 -M falloc
filedesc (9)      file descriptor tables and operations
file (9)  operations on file entries

#After changes
$ ./apropos -n 5 -M falloc
falloc (9)        file descriptor tables and operations
file (9)  operations on file entries

ok christos@
2017-04-23 13:52:57 +00:00
christos
dec46a9666 libarchive now needs crypto 2017-04-21 23:07:45 +00:00
joerg
c57cca78b1 Use libarchive 3.x interface and not obsolete 2.x versions. 2017-04-20 13:11:35 +00:00
martin
3933c9575a If -x (xsrc location) is passed for "check", display it also in the
"how to fix" invocation instructions.
2017-04-17 18:41:48 +00:00
hannken
256581e1f9 Cleanup after mountlist iterator:
- remove now unused field mnt_list.
- rename mount_list to mountlist and make it local to vfs_mount.c.
- make mountlist_lock local to vfs_mount.c.

Change pstat.c to retrieve vnodes by lru lists.
2017-04-17 08:29:58 +00:00
christos
3bf4d13e2d leave the size alone and set the create_size to include the offset. It
does not matter anyway, but it makes more sense this way.
2017-04-14 15:40:35 +00:00
wiz
0d97bd8ae2 Whitespace fixes. 2017-04-14 07:09:43 +00:00
christos
c02e58cd9e Explain the 's' image size better. 2017-04-13 17:21:29 +00:00
christos
e919fde2d0 for consistency with ffs, don't count the offset into the size. 2017-04-13 17:20:59 +00:00
christos
820702f055 Fix error handling; msdosfs_wfile is supposed to return errno. 2017-04-13 17:10:12 +00:00
roy
de09325dff Use RO_MSGFILTER. 2017-04-12 17:02:51 +00:00
roy
fcede00eff Use RO_MSGFILTER. 2017-04-12 16:47:39 +00:00
roy
08bcff5614 Use RO_MSGFILTER. 2017-04-11 14:29:23 +00:00
roy
f2128fd5cf Use RO_MSGFILTER. 2017-04-11 14:15:08 +00:00
christos
ddac911e7d Protect the right part. 2017-04-10 12:05:52 +00:00
christos
ec999e2a0c fix syntax 2017-04-09 21:57:59 +00:00
christos
1bba784bf1 stack protector issue on sparc 2017-04-09 20:34:00 +00:00
roy
470d822ff7 Move dhcpcd lease files to new location. 2017-04-01 20:14:53 +00:00
roy
27a2ea4c9b Move dhcpcd's rdm monotonic file if it exists. 2017-04-01 20:03:31 +00:00
roy
47092efcec Pluck dhcpcd.conf from dist/src
Move dhcpcd.duid and dhcpcd.secret from /etc to /var/db/dhcpcd/{duid,secret}
2017-04-01 19:14:10 +00:00
christos
624bfdf064 can't call pcap_datalink before activate. 2017-03-25 11:00:27 +00:00
christos
c8429e33e6 Change duplicate 'D' option to 'm'. From Ed Maste @ FreeBSD 2017-03-15 15:33:54 +00:00
wiz
27790f6369 Bump date for previous. 2017-03-15 11:22:47 +00:00
ozaki-r
7c181550a9 Fix build of puffs 2017-03-14 14:05:52 +00:00
bad
4046b64730 Document option console=auto. Works since at least NetBSD 6. [i386,amd64] 2017-03-14 13:50:40 +00:00
mlelstv
ba576b71a7 Enhance disk metrics by calculating a weighted sum that is incremented
by the number of concurrent I/O requests. Also introduce a new disk_wait()
function to measure requests waiting in a bufq.
iostat -y now reports data about waiting and active requests.

So far only drivers using dksubr and dk, ccd, wd and xbd collect data about
waiting requests.
2017-03-05 23:07:12 +00:00
ozaki-r
cd58b07d6c Fix the default value of rltime
According to rtadvd.conf(5), the default value of rltime is 1800 seconds.

PR bin/51994
2017-02-27 05:41:36 +00:00
wiz
2b9a593e7e Fix Dd argument. 2017-02-26 22:18:58 +00:00
mbalmer
57e869fa25 shorten hardware address wording 2017-02-26 19:58:38 +00:00
ozaki-r
00a9cf741d Remove mkludge stuffs
For unknown reasons, IPv6 multicast addresses are linked to a first
IPv6 address assigned to an interface. Due to the design, when removing
a first address having multicast addresses, we need to save them to
somewhere and later restore them once a new IPv6 address is activated.
mkludge stuffs support the operations.

This change links multicast addresses to an interface directly and
throws the kludge away.

Note that as usual some obsolete member variables remain for kvm(3)
users. And also sysctl net.inet6.multicast_kludge remains to avoid
breaking old ifmcstat.

TODO: currently ifnet has a list of in6_multi but obviously the list
should be protocol independent. Provide a common structure (if_multi
or something) to handle in6_multi and in_multi together as well as
ifaddr does for in_ifaddr and in6_ifaddr.
2017-02-23 07:57:09 +00:00
abhinav
8ab56b2aac Fix typo. 2017-02-22 14:15:15 +00:00
maya
b0f6bc04c6 GC some GCC 4.8 specific sh3 HACKS entries.
These existed to avoid compile errors, and haven't been effect
since gcc.old was removed.
2017-02-22 12:17:16 +00:00
abhinav
11852aa12f Remove duplicate word from the sentence. 2017-02-21 18:36:39 +00:00
abhinav
901279cdf1 Fix typos. 2017-02-21 18:28:28 +00:00
abhinav
7197d240e2 Fix spelling of "occurs". 2017-02-21 15:15:19 +00:00
christos
375072cc9c allow 0 timestamp 2017-02-16 22:44:06 +00:00
christos
d372863cc1 need <sys/stat.h> 2017-02-16 22:10:50 +00:00
christos
639cd04dc3 fix msdos reproducible builds! 2017-02-16 19:11:13 +00:00
christos
e93222b74e start fixing msdosfs for reproducible builds; does not work yet. 2017-02-16 18:50:04 +00:00
elric
e8ad4c8a7e Increase buffer size reported to strlcpy() to be one larger than the
length of the string we copy in so that there is space for the '\0'.
2017-02-15 02:48:31 +00:00
wiz
5ef8e05441 file system police. 2017-02-12 14:45:09 +00:00
nat
29b2495b54 RTP timestamp is now set correctly. The streaming socket is set to non
block blocking and connection state machinre improvement.
2017-02-12 08:25:31 +00:00
uwe
13be1262d3 Don't use slow file_exists_exact if we don't have to.
file_exists_exact function was introduced in 1.26 for the benefit of
cross-building on OS X case-insensitive file system.  It is extremely
slow on diskless machines.  That becomes especially noticeable when
you upgrade a system that has a lot of obsolete files, it can take
literally hours.
2017-02-11 19:35:45 +00:00
christos
49c3d03fa6 untorture language. 2017-02-11 16:04:59 +00:00
christos
2bb798b1d6 mention timezone change for -T timestamp 2017-02-11 15:32:51 +00:00