Commit Graph

10568 Commits

Author SHA1 Message Date
joerg
d965d85297 Nesting displays is not valid groff syntax. 2009-08-19 14:54:35 +00:00
dsl
f155f3b8b9 The code that attempted to sort large files by sorting each chunk by the
first key byte and writing to a temp file, then sorting the records from
each temp file that had the same first key byte (and repeating for upto
4 key bytes) was a nice idea, but completely doomed to failure.
Eg PR/9308 where a 70MB file has all but one record the same and short keys.
Not only does the code not work, it is rather guaranteed to be slow.
Instead always use a merge sort for fully sorted chunk of records (each
temporary file contains one lot of sorted records).
The -H option already did this, so just rip out all the code and variables
that can't be used when -H was specified.
Further cleanup to come ...
2009-08-18 18:00:28 +00:00
joerg
81e49626c4 GCC doesn't trace switch (foo & 7) completely, so add a default: abort()
to avoid warnings about unused variables.
Consistently use \t for the output function.
2009-08-17 14:15:07 +00:00
christos
3104786862 back out previous; luke says:
'@' is a reserved URI char per RFC 3986, use %40
2009-08-17 09:08:16 +00:00
dsl
fa81e78b3d 'depth' is used for the number of bytes into the key that the pointers
reference, when we want to find the record header put the larger value
into 'hdr_off' to avoid any confusion that the code might be changing
'depth'!
There is now no need to save the original value as 'odepth' in append.c.
All an a vague attempt to make this code slightly readable.
2009-08-16 20:02:04 +00:00
dsl
9ab8b68075 Replace all uses of sizeof(TRECHEADER) with REC_DATA_OFFSET - which
is defined as offsetof(RECHEADER, data).  Delete TRECHEADER.
2009-08-16 19:53:43 +00:00
martin
f842f249ac More missing <sys/exec_aout.h> 2009-08-16 18:43:08 +00:00
martin
73946a9cc9 More missing <sys/exec_aout.h> includes 2009-08-16 18:15:28 +00:00
christos
3ac3892a2a use strrchr to find the last @ because we might want the username to contain
user@domain.
2009-08-16 02:49:23 +00:00
dsl
59ede5ae24 Always add an REC_D char (usually \n) as the last sort key char - we
almost always need one.
But do ADD it, instead of overwriting the last byte of the last key since
that may be requesting the other end of the sort order.
There is no need to check for space for the line after adding the key,
but we might as well check before - just to optimise that case.
This might fix some of the sort bugs - but not the one I'm looking at!
2009-08-15 21:26:32 +00:00
wiz
e671c9cf08 Fix typo. 2009-08-15 20:44:56 +00:00
christos
bcbc23bd8f add -p <tmpdir> option to override $TMPDIR from the command line like linux
has.
2009-08-15 20:02:28 +00:00
dsl
9987745061 Remove reference to db.h by using separate ptr+len fields for the only
structure that used it.
Pass end of keybuf area, not size to enterkey() - largely to remove a
variable who'se use isn't obvious from the name!
The structute of this code sucks.
2009-08-15 18:40:01 +00:00
dsl
477a33f936 linebuf and linebuf_size are only used inside seq() - which also not
only has its own static variable, but will also extend the buffer.
Remove linebuf/size and change seq() to use a private, locally managed
buffer.
2009-08-15 16:50:29 +00:00
joerg
03c8ba1c27 Add nbperf(1), a minimal perfect hash function generator.
Implemented are the 3-graph BDZ algorithm as well as the
2-graph and 3-graph CHM algorithms. All algorithms have expected
linear run time and the smallest functions need around 2.85 bit/key.
2009-08-15 16:21:04 +00:00
dsl
5e8c7b5dbd Remove the unused 'DBT *key' parameter from seq(). 2009-08-15 16:10:40 +00:00
dsl
a3b5c4400f In makeline() change 'pos' from 'char *' to 'u_char *' and remove all
the casts associated with its use.
None of the uses can possibly care about the signedness of the pointer.
2009-08-15 14:31:48 +00:00
dsl
2a0ab276a2 Ansify.
I'm looking at fixing the 'sort -n' fubars, but this code is an
inpeneterable mess - which needs some fixing first!
2009-08-15 09:48:46 +00:00
drochner
c2819fbfcf avoid NULL dereference in log output if the command line parser
failed to extract a port number from the URL
2009-08-13 17:55:18 +00:00
dholland
69c3e9d213 Pass WARNS=4, not without some gross preprocessor hackery.
XXX: does this program actually do anything useful these days?
2009-08-13 06:59:37 +00:00
dholland
e63a3e7105 Assorted minor cleanup:
- use stdbool.h (partly)
  - move extern declarations of data to header files
  - use right types for calloc() wrapper
  - remove bogus casts on return values
  - remove excessive Pascal-style parentheses in conditionals
  - a couple const fixes
  - fix some typos in comments
2009-08-13 05:53:58 +00:00
dholland
7d59a3fee1 pass -Wshadow 2009-08-13 04:09:53 +00:00
dholland
72efe4fb6f Sprinkle const. 2009-08-13 03:50:02 +00:00
dholland
6c23c8ddec woops (doh!) 2009-08-13 03:10:03 +00:00
dholland
f42113e362 Whitespace. 2009-08-13 03:07:49 +00:00
dholland
b74af21b24 sprinkle static 2009-08-13 02:10:50 +00:00
matt
5f89c92891 Don't build for MIPS anymore 2009-08-12 23:39:13 +00:00
wiz
67bd9cb78f Remove superfluous parenthesis in #ifdef DEBUG.
From Henning Petersen in PR 41844.
2009-08-07 14:05:58 +00:00
wiz
ba544bf010 Add missing parenthesis in commented out code.
From Henning Petersen in PR 41838.
2009-08-07 13:53:54 +00:00
wiz
8356afb2c1 Fix typos in comment. 2009-08-05 19:08:28 +00:00
plunky
018ad52aa7 add new Service Class ID and Protocol UUIDs from the Service Discovery
assigned numbers document at www.bluetooth.com

add detail printing for Message Access Profile v1.0
2009-07-25 17:32:47 +00:00
gson
5861f6c435 When installing via a temporary file, base the name of the temporary
file on the name of the target file, not just the target directory, to
ensure uniqueness when multiple concurrent invocations of install(1)
simultaneously install files in the same directory.  Fixes bin/41512.
2009-07-25 11:45:58 +00:00
dholland
6d977e7b2a de-__P() and ANSIfy; no functional change 2009-07-25 08:20:24 +00:00
dholland
6263c6ea9c (1) reject instead of ignore extra arguments;
(2) reject requests for environment variables containing '='
    (PR 41774, but with different patch)
(3) fix capitalization of usage message
2009-07-25 08:18:33 +00:00
christos
f7c0a24801 the movers came. 2009-07-24 14:28:36 +00:00
njoly
420fe75a02 Delay emulation record output, to be processed after the current
syscall; to avoid picking syscall name from the wrong emulation table.
2009-07-24 11:34:03 +00:00
ahoka
b05ff95e20 Modify to support multibyte characters. 2009-07-21 01:35:02 +00:00
ahoka
d5fb12b51d Apply some ANSI and KNF. 2009-07-21 01:25:14 +00:00
ahoka
e48fb46a99 Change to support multibyte characters. 2009-07-21 01:12:55 +00:00
christos
00bd3af563 ansi prototypes for yyinput. 2009-07-20 21:13:28 +00:00
christos
6a7d49166f ssh has moved 2009-07-20 17:35:05 +00:00
christos
34af4cdada openssl has moved 2009-07-20 17:34:41 +00:00
apb
3ac228d1b2 Declare "com" as volatile in execute(), to make it safe to use
across setjmp/longjmp.

Inspired by PR 41255 from Kurt Lidl, but this change makes "com" a
volatile pointer to const non-volatile data, whereas the PR made it a
non-volatile pointer to const volatile data.
2009-07-14 21:15:48 +00:00
apb
3e4a7fe1fe Don't assume that two identical-looking string literals will have the
same address and will therefore be comparable with the == operator.
Instead, use a const variable.
Inspired by PR 41255 from Kurt Lidl.
2009-07-14 21:08:31 +00:00
apb
4259cd2ab8 Delete unused static smatch() function.
Inspired by PR 41255 from Kurt Lidl (which used #if 0 instead of
deleting the function).
2009-07-14 21:05:34 +00:00
apb
d47a5ef0ce Compare strings with strcmp(), not ==.
Part of PR 41255 from Kurt Lidl.
2009-07-14 21:02:24 +00:00
christos
585ce9eda6 move _KMEMUSER higher! 2009-07-13 21:44:32 +00:00
christos
d96e875904 need _KMEMUSER too. 2009-07-13 21:43:24 +00:00
roy
7027866a09 Rename internal getline() function to get_line() so it does
conflict with the soon to be added getline(3) libc function.
2009-07-13 19:05:39 +00:00
christos
f73facbc14 sys/mqueue.h needs sys/types.h now 2009-07-13 17:57:35 +00:00
joerg
5f6627fa61 mandoc(1): -width is redundant for a item list 2009-07-11 18:38:30 +00:00
joerg
ea92254557 Fix markup. 2009-07-11 18:35:48 +00:00
plunky
447afe8d7e add interpretation of "PNP Information" service class (Device ID profile) 2009-07-04 16:01:15 +00:00
mrg
983926d7bf note that -t can take [.dddddd]. sort -q.
from dhgutteridge@sympatico.ca in PR#36928.
2009-07-02 04:45:27 +00:00
dholland
63eb8c3760 Add some markup to improve clarity. 2009-06-29 03:49:41 +00:00
dholland
69388abb04 Fix typo 2009-06-28 19:02:46 +00:00
wiz
0f05513297 Remove superfluous Pp. Grammar improvement, typo fix, sort sections, fix Xr. 2009-06-26 09:31:04 +00:00
sjg
dd8e1ba252 JobExec: child of vfork must not empty the sigset_t that parent will
restore.  Use a separate mask.
2009-06-26 01:26:32 +00:00
wiz
c16d893d82 Remove trailing whitespace. 2009-06-25 23:20:55 +00:00
hubertf
c8c572c3bf Add an example .windowrc 2009-06-25 21:48:49 +00:00
joerg
a0922fbd98 Add work-in-progress unzip(1) frontend for libarchive.
Derived from FreeBSD's unzip.
2009-06-25 20:27:05 +00:00
wiz
d9d40568a0 Remove superfluous quotes. 2009-06-21 15:05:59 +00:00
wiz
eff7f14d80 Sync usage with man page. 2009-06-21 15:04:56 +00:00
wiz
205b6ccb09 Fix error in previous. 2009-06-21 15:04:07 +00:00
wiz
bd7419a011 Sort options and option descriptions. Use EXIT STATUS header for exit status
description. Use Pa for paths.
2009-06-21 15:02:54 +00:00
wiz
37d95f331f Sync usage with man page. 2009-06-21 14:59:53 +00:00
wiz
65c247649d Use Pa for paths. 2009-06-21 14:58:58 +00:00
wiz
7bba45dc18 Sync usage with man page. 2009-06-21 14:58:16 +00:00
wiz
f29f41d64b Use Pa for paths. 2009-06-21 14:57:33 +00:00
wiz
43ec52d73e Fix Dd argument. New sentence, new line. Remove superfluous .Pp. 2009-06-21 14:56:49 +00:00
christos
75a86bdab6 PR/40274: Takahiro Kambe: "P" flag stops rotating files. 2009-06-20 19:34:19 +00:00
christos
e5962c583f PR/22627: Greywolf: Support for yp nicknames map. 2009-06-20 19:27:26 +00:00
mrg
95c070cab9 - add extended WAVE header support
- attempt to play a bunch more WAV files
2009-06-18 02:37:27 +00:00
sjg
39bb2e98a1 Child of vfork() must not alter the state of parent.
There is no need to touch the state of vars in child anyway.
Change 2nd arg to Var_Export1() to indicate if we are the parent or child,
and only set flags in the parent.
2009-06-16 05:44:06 +00:00
christos
d3f46c621c PR/41581: Der mouse: window SEGV with certain terminals. does strcmp first
and then checks for null pointer for underline and bold.
2009-06-12 15:19:52 +00:00
ginsbach
2248a77687 Add -o output option, which can be used to specify an output file. The
file can even be the same as the input file.  Idea from IRIX unifdef(1).
2009-06-11 03:16:34 +00:00
yamt
6539ec6cea tabify and wrap long lines. 2009-06-08 21:58:44 +00:00
gson
57a8678315 Fix race condition causing "install -d" to randomly fail when multiple
concurrent install processes try to create the same directory.
Modelled after the code handling the "mkdir -p" case in mkdir(1).
2009-06-08 14:22:01 +00:00
christos
e3dfcc9dfe remove file 2009-06-07 23:16:50 +00:00
christos
0587e0bf24 unhook ssh 2009-06-07 22:46:43 +00:00
tron
cef801c39d Chuck Berry was born in St. Louis, Missouri, and not in St. Jose,
California. Patch submitted by Marc Balmer in private e-mail.
2009-06-07 10:25:39 +00:00
joerg
57b5269dad Explicitly include fcntl.h for O_CREAT to not depend on namespace
pollution.
2009-06-05 19:55:43 +00:00
sjg
2428caab9f Missing ':' in .ORDER example 2009-06-01 23:28:39 +00:00
christos
3b9e5891ba fix typo (Silas Silva) 2009-05-28 14:57:42 +00:00
snj
a1602d4a22 Fix some longstanding typos and remove an entry that is both redundant
and wrong at the same time.
2009-05-27 17:17:03 +00:00
ad
d991fcb3b6 More changes to improve kern_descrip.c.
- Avoid atomics in more places.
- Remove the per-descriptor mutex, and just use filedesc_t::fd_lock.
  It was only being used to synchronize close, and in any case we needed
  to take fd_lock to free the descriptor slot.
- Optimize certain paths for the <NDFDFILE case.
- Sprinkle more comments and assertions.
- Cache more stuff in filedesc_t.
- Fix numerous minor bugs spotted along the way.
- Restructure how the open files array is maintained, for clarity and so
  that we can eliminate the membar_consumer() call in fd_getfile().  This is
  mostly syntactic sugar; the main functional change is that fd_nfiles now
  lives alongside the open file array.

Some measurements with libmicro:

- simple file syscalls are like close() are between 1 to 10% faster.
- some nice improvements, e.g. poll(1000) which is ~50% faster.
2009-05-24 21:41:25 +00:00
plunky
9b85369a0a use system provided MAX(a, b) macro instead of defining our own 2009-05-21 14:44:01 +00:00
christos
ebd7e1e10a catch up with rtld changes 2009-05-20 16:20:01 +00:00
wiz
8ab6f9e454 Sort options. Sort sections. Remove superfluous .Pp. 2009-05-18 12:03:06 +00:00
wiz
ea548d35a5 Sort options. 2009-05-18 09:37:44 +00:00
christos
434ce22684 fix dependencies. 2009-05-16 21:37:48 +00:00
plunky
bbb0e93abb add a -P flag to attempt immediate pairing 2009-05-16 07:18:42 +00:00
wiz
7560090357 Whitespace fix. 2009-05-13 22:56:42 +00:00
cube
d502f7a8c0 Dependency on config_time.src was removed today from Makefile.kern.inc, so
starting from that date it's not necessary to create it.  (Of course that
won't happen until config version is bumped for some other reason.)
2009-05-13 18:54:34 +00:00
wiz
b0f5ac9634 Add missing apostrophe. 2009-05-12 18:54:31 +00:00
plunky
a092292999 update rfcomm_sppd to use the new Service Discovery API 2009-05-12 18:43:35 +00:00
plunky
1b7404b7aa update to use the new service discovery API 2009-05-12 18:39:55 +00:00
plunky
384153c15a update sdpquery with a newer version that fetches the whole service
record and displays it in a human readable fashion.
2009-05-12 18:37:50 +00:00
plunky
b2f181453f this needs libsdp no more 2009-05-12 13:15:10 +00:00
plunky
8cea406d3c does no longer need libsdp 2009-05-12 13:13:34 +00:00