liamjfoy
5bafb9022a
reference uptime(1) correctly
...
ok joerg@
2006-05-13 12:41:54 +00:00
he
eb8d767d84
Sorry, fix syntax error in previous.
2006-05-12 07:20:13 +00:00
he
afd5b9b6d3
Appease gcc 3.3.3 -Wuninitialized warning; fixes build problem for
...
a multitude of archtectures (prep, alpha, i386, acorn32 and probably
more).
To be documented in doc/HACKS.
2006-05-12 07:19:43 +00:00
lukem
143c145a8f
Only use -Wno-pointer-sign for gcc4.
2006-05-12 03:52:05 +00:00
mrg
abeaa4f60d
apply -Wno-pointer-sign with GCC4.
2006-05-12 03:29:11 +00:00
mrg
5063b7a180
apply -Wno-pointer-sign with GCC4.
2006-05-12 02:01:15 +00:00
mrg
20265245bf
use -Wno-pointer-sign with GCC4.
2006-05-12 01:26:05 +00:00
mrg
16efbf8575
don't do the -Wno-pointer-sign dance for host programs.
2006-05-12 01:18:25 +00:00
mrg
aadd7d4847
sprinkle some -fno-strict-aliasing and -Wno-pointer-sign with GCC4.
2006-05-11 23:16:28 +00:00
mrg
f066626ffb
char -> u_char in a couple of places to match other variables.
2006-05-11 19:16:42 +00:00
sjg
fc23c7c758
Remove the modterm case from moderrs, the syntax errors
...
generated by /bin/sh on other systems are not consistent.
2006-05-11 18:48:33 +00:00
mrg
117693dfce
when calling compile_tr() add (void *) to the 2nd argument's cast chain.
2006-05-11 17:18:19 +00:00
mrg
6f4493cd5c
xdr sucks. sprinkle some (void *) casts into it's functions taking void **,
...
and shut up GCC4.
2006-05-11 17:11:57 +00:00
sjg
03cbcf6532
Extract the variable modifier logic to a separate function.
...
This cuts Var_Parse in half! and allows the modifier logic to
be used recursively - when getting modifiers via variables.
Add new unit-test, to check that certain error cases are handled
correctly.
2006-05-11 15:37:07 +00:00
liamjfoy
1ee9d337ea
clear errno before using strtol
...
ok christos & joerg
2006-05-11 12:02:08 +00:00
yamt
ee458ef97e
include errno.h directly rather than via user.h.
2006-05-11 12:01:33 +00:00
yamt
49cee5da7c
#include a necessary header directly, rather than via user.h.
...
while i'm here, remove unnecessary #include.
2006-05-11 11:58:04 +00:00
yamt
2416177358
tweak for user.h cleanup.
...
while i'm here, remove unnecessary #include.
2006-05-11 11:56:38 +00:00
mrg
c92f14aaa2
include "rcv.h" so that extern array types are well-known.
2006-05-11 10:45:48 +00:00
mrg
982b2b7938
char -> u_char for a buffer passed to MD5*().
2006-05-11 06:09:44 +00:00
mrg
f145204eb2
XXX build with -Wno-pointer-sign and -fno-strict-aliasing when using GCC4.
2006-05-11 06:01:31 +00:00
mrg
35b9b80e28
build sshconnect1.c with -fno-strict-aliasing.
2006-05-11 01:26:03 +00:00
mrg
130d5d4569
call ctime() with an actual time_t *.
2006-05-11 01:25:23 +00:00
mrg
9588ebc6e5
u_long -> u_int in many places. i guess radioctl(1) was broken on sparc64.
2006-05-11 01:24:14 +00:00
mrg
0e223467a4
nfiles -> ns_nfiles (conflicts with kernel header files and _KERNEL.)
2006-05-11 01:23:20 +00:00
mrg
4a55b2ff97
exp() -> m4_exp().
2006-05-11 01:22:20 +00:00
mrg
9ce2c843f8
maxfiles -> fstat_maxfiles. (this _KERNEL definition code needs to not
...
clash with kernel headers....)
2006-05-11 01:21:23 +00:00
mrg
70daf20d05
no need to cast setlocale()'s return value.
2006-05-11 01:20:33 +00:00
mrg
15aa4e8c07
use -Wno-pointer-sign for GCC4.
2006-05-11 01:19:55 +00:00
mrg
bc3f0566af
variable signed/unsigned cleanup.
2006-05-11 01:19:10 +00:00
mrg
a8177e2129
use socklen_t where appropriate.
2006-05-11 00:27:27 +00:00
mrg
4bc6feceb6
end the argument list to exec*(3) with a NULL instead of a bare '0', as
...
the latter isn't a pointer context in these varargs functions.
2006-05-11 00:22:52 +00:00
lukem
366e1460da
Add -n to the usage message.
...
Noted by Maxim Konovalov <maxim@macomnet.ru>.
2006-05-10 23:35:03 +00:00
mrg
084c052803
quell GCC 4.1 uninitialised variable warnings.
...
XXX: we should audit the tree for which old ones are no longer needed
after getting the older compilers out of the tree..
2006-05-10 21:53:14 +00:00
mrg
2ed99b6c90
need <stdlib.h> for exit(3).
2006-05-10 21:34:20 +00:00
skrll
a9f4c28a3d
Fix a bunch of cast lvalues.
2006-05-10 06:24:02 +00:00
mrg
0c37c63edc
change (mostly) int to socklen_t. GCC 4 doesn't like that int and
...
socklen_t are different signness.
2006-05-09 20:18:05 +00:00
gson
dcf9144a8a
Do not treat all file names of length 1 as meaning standard output.
2006-05-09 15:55:44 +00:00
he
b28792d8d4
Our gcc 3.3.3 (nb3) for hppa gets an "unrecognized insn" internal
...
compiler error when building buf.c with -O2, so reduce optimization
level to -O1 for this single file.
To be documented in docs/HACKS, discussed with skrll.
2006-05-08 11:07:57 +00:00
hubertf
97c6c066c2
Be more liberal about whitespaces when verifying checksums.
...
This allows checking md5/sha1 shecksums generates on Linux, which
add more whitespace.
Based on patch by Jukka Salmi (j+nbsd at 2006 dot salmi dot ch)
2006-05-07 12:22:55 +00:00
elad
00556c3786
remove -1, -2, -4, -5, -6, -m.
2006-05-05 22:07:22 +00:00
rpaulo
de8db47547
Add support for RFC 3542 Adv. Socket API for IPv6 (which obsoletes 2292).
...
* RFC 3542 isn't binary compatible with RFC 2292.
* RFC 2292 support is on by default but can be disabled.
* update ping6, telnet and traceroute6 to the new API.
From the KAME project (www.kame.net).
Reviewed by core.
2006-05-05 00:03:21 +00:00
lukem
e48c097471
getservbyport(3) wants the port in network order.
...
Noted by Hajimu UMEMOTO <ume@freebsd.org>
via Maxim Konovalov <maxim@macomnet.ru>.
2006-05-04 23:22:21 +00:00
christos
394f070a3e
Handle aout m68k; from Izumi Tsutsui.
2006-05-04 18:06:29 +00:00
christos
dc2a3a037e
Sprinkle __dead
2006-05-03 18:08:24 +00:00
yamt
2553980909
- fix --.
...
- fix -e.
- fix patterns starting with -.
- fix "missing argument" message.
2006-05-03 16:48:29 +00:00
christos
d1c2aa7c3b
Coverity CID 1184: Avoid NULL deref.
2006-05-02 22:35:07 +00:00
christos
4e749c0af7
Coverity CID 1185: Avoid NULL deref.
2006-05-02 22:33:42 +00:00
christos
060bb7465d
Coverity CID 1330: Always check str_alloc for NULL returns.
2006-05-02 22:30:25 +00:00
christos
54f258bd85
Coverity CID 1736: close files before returning.
2006-05-02 22:26:46 +00:00
christos
9c8ab46858
Coverity CID 569: Remove dead code.
2006-05-02 22:24:05 +00:00
christos
e649ae6adc
Coverity CID 884: Avoid NULL deref.
2006-05-02 22:19:12 +00:00
christos
10a7a5fd96
Coverity CID 885: Avoid NULL deref.
2006-05-02 22:13:29 +00:00
christos
9b0f17533c
Coverity CID 886: Avoid NULL deref.
2006-05-02 21:40:06 +00:00
christos
a0c086aaf2
Coverity CID 2989: Use the error path to return.
2006-05-01 23:31:10 +00:00
christos
83d63c0a25
Coverity CID 2996: Don't return without closing fp.
2006-05-01 23:22:48 +00:00
christos
0ced32c669
Rename cat to tset_cat so that coverity does not get confused by the global
...
name.
2006-05-01 23:18:37 +00:00
christos
ed5c178a35
Use errx instead of fprintf/fputs.
2006-05-01 23:12:24 +00:00
christos
9136a179f7
Coverity CID 1198: Avoid closing a negative fd.
2006-05-01 23:06:55 +00:00
christos
85576ae019
Coverity CID 1224: Avoid closing a negative fd.
2006-05-01 23:05:24 +00:00
christos
20fe0cf746
Coverity CID 1447: Avoid buffer overflow.
2006-05-01 23:02:03 +00:00
christos
186743bc31
Coverity CID 1448: Avoid static array overflow.
2006-05-01 23:00:33 +00:00
christos
05d6ead1e0
Coverity CID 1223: Avoid calling close with a negative fd.
2006-05-01 22:57:16 +00:00
christos
7c1fafb5f3
Coverity CID 1233: Avoid negative index.
2006-05-01 22:55:50 +00:00
christos
501be8b824
Need assert.h now.
2006-05-01 05:14:22 +00:00
christos
e408cc2631
Coverity CID 766: Add assertion before pointer deref.
2006-05-01 05:13:58 +00:00
christos
76c6077db0
Coverity CID 815: Avoid NULL pointer deref.
2006-05-01 05:04:02 +00:00
christos
f2dd1e3c0c
Coverity CID 1772: Close file on error return.
2006-05-01 00:03:15 +00:00
christos
4f0fad7e36
Coverity CID 814: Add extraneous checks to shut up Coverity.
2006-05-01 00:00:12 +00:00
christos
f5c3fa40c3
Coverity CID 1206: Confusion between && and || leads to indexing an array
...
with negative index.
2006-04-30 23:56:42 +00:00
christos
1af32ba03a
Coverity CID 1566: fix memory leak.
2006-04-30 23:54:40 +00:00
christos
1f74082c09
Coverity CID 1972: Don't leak file descriptor.
2006-04-30 23:52:14 +00:00
christos
781d14720c
Coverity CID 1599: Fix memory leak.
2006-04-30 23:49:34 +00:00
christos
fc56e77334
Coverity CID 1483: Off-by-one stack overflow.
2006-04-30 23:43:31 +00:00
christos
9ff5bf4b8a
Coverity CID 788: Fix null pointer deref.
2006-04-30 23:42:06 +00:00
christos
4f6d3973bf
Coverity CID 787: Fix null pointer deref.
2006-04-30 23:40:20 +00:00
christos
0b78752ab3
Coverity CID 749: Comment out dead code.
2006-04-30 23:38:34 +00:00
christos
f84f0d3321
Coverity CID 2972, 2973: Don't call close() with a negative fd.
2006-04-30 23:34:50 +00:00
christos
011be34f91
Coverity CID 1565: Fix memory leak.
2006-04-30 23:30:13 +00:00
christos
7d7dff8590
Coverity CID 2986: Free lines before returning.
2006-04-30 23:27:15 +00:00
liamjfoy
9a4f3f0f6e
remove an unused variable
...
ok christos
2006-04-30 20:23:02 +00:00
liamjfoy
4ed54cf43d
Remove Pflag variable. its unused.
...
ok christos@
2006-04-30 19:24:50 +00:00
christos
0f2aabcd39
Coverity CID 1858, 1857: Fix leaks. While here, pass lint use warn/warnx
...
instead of perror/fprintf. KNF.
2006-04-28 20:35:15 +00:00
christos
69f8117233
Coverity CID 873: Only align if we printed a string.
2006-04-28 20:07:57 +00:00
christos
61e04d677f
Coverity CID 874: Don't check local; it cannot be NULL.
2006-04-28 20:06:50 +00:00
christos
fc5177078a
Coverity CID 875: local is not allowed to be NULL; don't check for it.
2006-04-28 20:05:43 +00:00
christos
32d85d8f66
Coverity CID 2194: Don't forget to free port.
2006-04-28 20:02:07 +00:00
christos
5c8a52b0f1
Coverity CID 2195: Free path in all code paths, not some.
2006-04-28 19:59:44 +00:00
christos
e8877ca717
Coverity CID 1780, 1779: Fix memory leak.
2006-04-28 19:53:56 +00:00
simonb
47890115bd
Unwrap a not too long line.
2006-04-27 09:04:41 +00:00
christos
63b0d1ab71
Coverity CID 2790: Always free tmp buffer, not somethimes.
2006-04-25 19:34:42 +00:00
christos
4d5030b7d4
Coverity CID 2969: Check for negative stack in the 'P' case like we do in
...
the 0 case.
2006-04-25 19:25:19 +00:00
wiz
61152e3f56
Document more explicitly that -c takes an optional file argument.
2006-04-24 22:00:43 +00:00
hubertf
0b4add3077
Allow reading the checksum list from stdin if no file is given with -c.
...
This allows verifying the checksums e.g. after downloading a NetBSD
release:
cat BSDSUM CKSUM MD5 SHA512 SYSVSUM | cksum -c
2006-04-24 21:07:43 +00:00
hubertf
1e8e9dee9c
Try guessing hash types. Prefix output with hash type,
...
the output format was inspired by Linux & OpenBSD.
This now allows doing something like:
miyu% ( md4 *.c ; md5 *.c ; sha1 *.c ) > /tmp/x
miyu% md5 -c /tmp/x
miyu% cksum -c /tmp/x
miyu% echo $?
0
miyu% date >test.c
miyu% cksum -c /tmp/x
(MD4) test.c: FAILED
(MD5) test.c: FAILED
(SHA1) test.c: FAILED
miyu% echo $?
1
2006-04-24 19:41:41 +00:00
jld
c861d33e38
Make yes exit if a write fails (due to, e.g., EPIPE or revocation).
...
With advice from rillig@; discussed on tech-userlevel on 2005-11-18.
2006-04-24 05:24:03 +00:00
wiz
f255a1f958
A fix for HTML output; punctuation nits.
2006-04-23 17:45:04 +00:00
hubertf
944a4820a3
Document -w, too.
2006-04-23 16:48:02 +00:00
hubertf
f9e91b57ed
Add a switch "-c file" to verify a list of checksums generated by the
...
cksum program and stored in file against files on disk. E.g. first
run "md5 *.tgz >MD5" to generate a list of MD5 checksums in MD5, then
use the following command to verify them use "md5 -c MD5"
Inspired by Linux' md5sum,
called for by Jukka Salmi <j+nbsd@2006.salmi.ch>on netbsd-help@,
reviewed by rui@.
2006-04-23 16:40:16 +00:00
christos
328064d112
Redo the previous change so that we can ignore access errors from find,
...
but also tell when writing to the output file failed, by using a pipeline
to cat. While here change `` to $(). Otherwise this would always fail
since it is ran as nobody and therefore it cannot access some files. Reported
by smb.
2006-04-23 03:04:08 +00:00
christos
731b0f1073
Coverity CID 522: Clarify that there is no overrun here.
2006-04-22 20:51:09 +00:00
christos
3d5b8ce5a8
Coverity CID 529: Call VarFreeEnv to prevent leak.
2006-04-22 19:40:40 +00:00
christos
ac5c384e1b
Coverity CID 534: Free junk variables on return from Var_Parse.
2006-04-22 19:32:35 +00:00
christos
bb46846e03
Coverity CID 533: Plug memory leak.
...
Add a new function VarFreeEnv() to free environment variables and use it.
2006-04-22 19:28:51 +00:00
christos
58c48be0b3
Coverity CID 526: Check for condTop < 0 where we decrement it, not later
...
when the damage is already done.
2006-04-22 18:53:32 +00:00
christos
1c603f6321
Coverity CID 527: Make it painfully obvious that av is freed.
2006-04-22 18:48:46 +00:00
christos
0f515a9e28
Coverity CID 528: Avoid NULL deref.
2006-04-22 18:47:10 +00:00
christos
f2f8f4c25a
Coverity CID 530: Don't leak the argument vector.
2006-04-22 18:43:06 +00:00
christos
1456136e74
Coverity CID 523: Fix off by one mistake.
2006-04-22 18:38:38 +00:00
christos
d64e64f832
Coverity CID 545: Appease coverity. return early if the locally allocated
...
memory is not going to be used (this is an impossible case).
2006-04-22 18:16:13 +00:00
christos
df780f7c38
Coverity CID 546: Add assertion before de-reference.
2006-04-22 18:08:13 +00:00
christos
2d84e02e2f
Coverity CID 552: Close opened file.
2006-04-22 18:02:26 +00:00
christos
ebd63cb6e2
Coverity CID 1748: Free alias on error.
2006-04-22 17:51:09 +00:00
christos
42bccc19d6
Coverity CID 2913: Check for EOF before using char as index to array.
2006-04-22 17:46:48 +00:00
christos
24f29ca641
Coverity CID 95: Fix resource leak.
2006-04-21 16:36:05 +00:00
yamt
1c625a0e79
remove unused files.
2006-04-21 13:45:42 +00:00
hubertf
ce8f04b19d
Don't try to determining the size of what's coming when reading from a pipe.
...
Instead of reporting some bogus values, print no progress at all.
(It's beyond me why stat(2) on a pipe returns funny values...
see the PR below for some examples!)
Fixes PR bin/33207 by myself.
OK'd by mrg@
2006-04-20 23:20:55 +00:00
blymn
10df330c85
Prefix iostat structure elements with io_
2006-04-20 12:13:51 +00:00
christos
862fe20f05
GC old signal handling and merge it in 4 places:
...
1. Immediately ignore all the signals we want to ignore and set the alarm.
2. Before we exit on error, restore all signals we modified
3. Before we exec a shell, restore all signals we modified and ignore TSTP.
Job control aware shells know how to deal with this.
4. Temporarily handle SIGINT while we read motd.
2006-04-17 16:29:44 +00:00
skrll
683ccd8e40
Add RCSId.
2006-04-17 06:53:06 +00:00
blymn
e48af18bc5
Update to use new kernel io statistics.
2006-04-14 13:14:06 +00:00
blymn
7d866d268b
Update statistics reporting to use new kernel framework, rename dkstats*
...
to a more generic name since it no longer just deals with disk.
2006-04-14 13:12:37 +00:00
wiz
3aec927b7b
Bump date for previous.
...
New sentence, new line.
Remove trailing whitespace.
2006-04-13 21:15:50 +00:00
wiz
afd4fdef89
Bump date for previous, slightly reword a sentencen.
2006-04-13 21:10:44 +00:00
sjg
d7df397808
Change ReadMakefile to return 0 on success so that it better meets
...
the expectations of Lst_Find*. This way we only read the first sys.mk
found via sysIncPath.
At the same time we need to add a ReadAllMakefiles() for the case
where multiple -f makefile args are provided (uncommon, but documented).
2006-04-12 20:32:27 +00:00
chuck
02ff9e80b9
fix .Xr to invalid man page that i put in by mistake
2006-04-10 16:20:46 +00:00
chuck
d09fe2c467
modified man(1):
...
- avoid double slashes when displaying man pages (got tired
of '/usr/share/man//cat1/man.0').
- got rid of __P() while working on it.
- incorporate some of my old notes explaining how manpath works into the
comments of the code itself.
- renamed some of the vars so that the code is consistent throughout
(and hopefully clearer and easier to understand)
- fixed relative man paths for multiple man pages (man did a chdir()
on the first man page it had to format --- this broke any remaining
relative path man pages left to process). save old directory and
fchdir() back to it after formatting.
- improved doc on "man -h" which does more than just whatis(1) [e.g.
"man -h fopen" prints the required include files and the prototypes
rather than just the one-liner you get with whatis(1)]
- manconf.c now fills in the "len" length field in the TAG/ENTRY
structures (man now uses len).
revise man.conf file reading stuff to return error on failure in
addentry/gettag (fka getlist) rather than just err()ing out. this
allows man(1) to call cleanup and delete its tmp files rather than
just leave them floating. revise other apps using this code
(makewhatis, apropos, catman, whatis) to expect this. also remove
__P on updated files.
2006-04-10 14:39:06 +00:00
chuck
82ad9348f2
rework the wording in these man pages (mainly in man.conf.5) based on
...
some old notes I found to make it clearer and easier to understand
how the man stuff works (hopefully!).
2006-04-10 14:02:57 +00:00
christos
857164eeb5
Coverity CID 2536: Clarify the error path further.
2006-04-09 20:01:40 +00:00
christos
c5e22666b0
Coverity CID 1596: Plug memory leak.
2006-04-09 19:51:23 +00:00
christos
e550e02b95
Coverity CID 1624: Plug memory leak.
2006-04-09 19:47:43 +00:00
christos
79059c6361
Coverity CID 1563: Fix memory leak.
2006-04-09 19:42:03 +00:00
christos
3bf01f5c84
Duh fixed error printing.
2006-04-09 19:39:17 +00:00
christos
034e8bc313
Coverity CID 1580: Plug memory leak.
2006-04-09 19:37:50 +00:00
christos
c1cd33addf
Coverity CID 2331: Plug memory leak.
2006-04-09 19:27:22 +00:00
christos
5d96bf2cf0
Coverity CID 2333: Fix memory leak.
2006-04-09 19:21:26 +00:00
christos
bd21f84917
Coverity CID 1253, 1254: Don't assign the return of read or write to size_t.
...
It will never be negative.
2006-04-09 19:12:17 +00:00
christos
f5a5211062
It is silly to creat() and close a file just to stat it. open/fstat/close
...
instead checking for errors. From Coverity CID 1276.
2006-04-09 19:06:34 +00:00
christos
5800a5519e
Coverity CID 2078, 2079, 2080: Plug memory leaks.
2006-04-09 19:03:32 +00:00
christos
e90cb419e0
Coverity CID 2355: Checking event for NULL is supefluous; restructure the
...
code to make this obvious.
2006-04-09 18:57:10 +00:00
christos
347d6ce9be
Pass lint. Also fix errx/err confusion.
2006-04-09 18:54:28 +00:00
christos
61894ae043
Coverity CID 894: Avoid NULL dereference that cannot really happen.
2006-04-09 18:47:49 +00:00
christos
9d0203193c
Pass lint.
2006-04-09 18:45:19 +00:00
wiz
498c64811f
Note that -v is broken in this version.
2006-04-08 23:56:39 +00:00
christos
03c0fd3fc6
change an int to size_t
2006-04-08 23:27:03 +00:00
christos
258969c334
Include bsd.own.mk; from Jukka Salmi
2006-04-08 20:07:29 +00:00
mrg
0db1500b43
retire HAVE_GCC3/HAVE_GCC4 and introduce HAVE_GCC that is set to 2, 3 or 4.
2006-04-07 19:38:58 +00:00
rpaulo
32f6ca81fb
snprintf returns int, not size_t. CID 691.
...
From bjh21.
2006-04-06 18:30:31 +00:00
simonb
372d44b647
Use TABs instead of spaces.
2006-04-06 00:48:14 +00:00
yamt
2267ff751f
cuhelp: fix a typo in usage.
2006-04-05 23:30:57 +00:00
dsl
2ab52a9ec8
Rework the way that files are closed and unlinked on error.
...
In particular avoid calling fclose() again once it has failed.
Also multply 'oreg' by 2 once we modify the file - so we know when to
unlink it on error.
Fixes Coverty CIDs 2535 and 2536
2006-04-05 20:24:38 +00:00
dsl
4fe310d596
Avoid iswhite(EOF) - fixes coverty CIDs 365 and 1196
...
I'm not at all sure EOF handling is correct anyway - but it probably only
affects the last line of a file (and maybe last lines without \n).
In particular I suspect that 'ungetc(EOF, file)' doesn't do the expected
thing, and that fseek() needs to be preceeded by clearerr(). But life it short.
2006-04-05 20:03:14 +00:00
dsl
abc6183046
Don't follow node->left after free(node).
...
Optimise out recursion unless both node->left and node->right non-NULL.
Fixes coverty CIDs 26 and 27.
2006-04-05 19:38:47 +00:00
tron
442e61c603
Fix "MKUUCP" check so that "cu" installed if "MKUUCP" is not defined.
2006-04-05 13:04:33 +00:00
christos
a2170ce453
make sure that netid always points to an allocated string. Pointed out by
...
enami; thanks.
2006-04-05 12:57:29 +00:00
christos
c721423ddc
Use the standard macros to compute the ioctl length instead of rolling our
...
own. Thanks to Chuck for noticing.
2006-04-05 00:50:59 +00:00
christos
48cf428279
Turn if/then/elif into a switch
2006-04-04 21:35:20 +00:00
christos
cda1870a45
Coverity CID 28: Fix resource leak.
2006-04-04 21:29:42 +00:00
christos
99f1624bd3
Coverity CID 97: Remove dead code.
2006-04-04 21:27:42 +00:00
wiz
e9821b1244
Sort SEE ALSO; mark up -; end sentence with dot.
2006-04-04 20:45:41 +00:00
dyoung
ca9de39d07
If MKUUCP=no, do not create links for cu and its manual page.
2006-04-04 15:09:50 +00:00
tls
76f2334c55
Use closefrom, don't iterate over file descriptors from 3 to 20.
2006-04-03 16:13:34 +00:00
tls
a973ebec53
Replace abuse of SIGIOT, SIGEMT, SIGSYS for communication between the
...
TIPIN and TIPOUT processes with a third "attention" pipe. While we're
here, fix a few other minor nits like the hardcoded use of fd 3 in
consh().
Now ~+/~C appear to work. This must have been broken for years.
2006-04-03 16:03:50 +00:00
christos
e0b8cfed06
Coverity CID 2287: Fix memory leak.
...
Plus:
- change fprintf -> errx
- remove unneeded casts
- avoid err() shadowing
2006-04-03 15:21:26 +00:00
tls
374e37364a
Move "cucommon" label (ugh) to above the O_NONBLOCK handling for direct
...
connections. This stops the tipout process from spinning.
2006-04-03 14:54:16 +00:00
christos
cb82eb0f6b
Redo the previous in the tip sanctioned way :-)
2006-04-03 14:12:29 +00:00
martin
d6d78510c3
printf format fixes for 64bit archs
2006-04-03 13:30:24 +00:00
he
3a81e1c420
For the benefit of our 64-bit ports, we need to cast via intptr_t when
...
casting from pointer to unsigned int.
2006-04-03 13:00:48 +00:00
scw
34b4a96dbb
Add a kernel driver and userland program for the Topfield TF5000PVR range
...
of digital video recorders popular in Europe and Australia.
These devices have a USB client port which can be used to upload and
download recordings (and other files, such as MIPS binaries for execution
on the DVR's CPU) to/from their internal hard disk, in addition to some
other operations on files and directories.
2006-04-03 08:15:48 +00:00
wiz
e9a003bced
Use Dq, punctuation vs whitespace nits.
2006-04-03 05:56:20 +00:00
yamt
e6e5a0e51b
actually set up baudrate after rev.1.33.
2006-04-03 05:08:40 +00:00
yamt
25e67975a5
fix a typo in LINKS.
2006-04-03 05:05:55 +00:00
christos
c4341bc3e1
Pass a little lint.
2006-04-03 04:53:58 +00:00
perry
29dc02e572
delinting. more needed. (lint found some real bugs that I haven't fixed yet.)
2006-04-03 04:25:30 +00:00
perry
b43b6e6666
Merge a few of the OpenBSD manual page changes. Not yet close to
...
finished but I have to break for now and Thor will probably pick up
from where I left off.
2006-04-03 03:46:34 +00:00
tls
125606b781
Wwwwwwww! Do not remove variables from the vtable in vars.c without
...
changing the indices in tip.h -- what a terrible design.
Okay, "design". Fine. Whatever. ;-) Now we don't dump core all the time.
2006-04-03 03:13:10 +00:00
perry
31f14bb93a
Clean up a bit.
2006-04-03 02:33:19 +00:00
perry
d71f683e39
Remove vestiges of the ACULOG support. It depended on the suid support
...
(which is now gone) and it is woefully obsolete -- if something
analogous is ever needed in the future, syslog is the way to do it.
2006-04-03 02:25:27 +00:00
tls
bc4c5be2bf
Now we use tip-as-cu, not Taylor UUCP cu.
...
These programs are no longer setuid, and now lock devices with flock,
not file locks in /var/spool/. They will no longer lock against UUCP
itself unless we modify UUCP to lock with flock, but this seems highly
unlikely to be an issue in the present day.
2006-04-03 02:21:13 +00:00
perry
8a1d2efb73
remove refs to uucp locking and aculog
2006-04-03 02:14:26 +00:00
tls
6bd8b21472
The ~C / ~+ command is no longer optional.
2006-04-03 02:06:44 +00:00
perry
eee85da04c
Remove support for uucp style locking.
...
This means we can get rid of the suid/sgid parts of the code (which
have been removed). The program is now installed with normal permissions.
To prevent accidents, we now flock the tty line, attempting to get an
exclusive lock.
Reviewed by: tls
2006-04-03 02:01:28 +00:00
tls
896b79dbc8
If we're not given a phone number or system name to dial, use "direct
...
connect" mode -- in other words, set CLOCAL so the user can talk to the
device before CD.
2006-04-03 01:48:22 +00:00
tls
bed8070daa
Whoops. We don't *use* log.o, so don't *build* it.
2006-04-03 01:47:20 +00:00
perry
58c2151f1e
ANSIfy decls, de-__P, clean trailing whitespace
2006-04-03 00:51:13 +00:00
tls
4c0b53d7b4
At Luke Mewburn's suggestion, disable "force" by default, too. Those using
...
the tip frontend who really want ^P used for "send literal" can turn it on
in tiprc or remote.
2006-04-02 23:25:35 +00:00
tls
edddcc4ac8
Add another Taylor compat option, --nostop to disable software flow control
...
(a.k.a. "tandem" mode). While we're here, fix a buglet with --halfduplex,
and add --flow {hard, soft, none}. Note that you can't get *both* hard and
soft flow control using the command-line option; if you want that, you
have to set the variables in tiprc or with ~s once tip is running.
Move all setting of vars.c named variables to *after* the call to vinit().
2006-04-02 22:19:26 +00:00
tls
da6a898cf6
Oddly enough, smashing CRTSCTS into the terminal input flags doesn't do
...
much; it is a control flag.
Now toggling hardware flow control works.
2006-04-02 20:44:20 +00:00
tls
6b0f06d935
Fix the conditional compilation on ACULOG so it actually works.
...
Turn it off by default -- it hardly saves any space, but it's
one of the reasons why the executable is installed setuid, and
other versions of tip/cu don't write a log file anyway. We can
add syslog support later if we ever really want this back, the
file-writing is all encapsulated in log.c.
2006-04-02 19:16:22 +00:00
tls
ad69069bcc
New 'cu' command-line handling, derived from Todd Miller's in OpenBSD,
...
but with some long options added for Taylor 'cu' compatibility, and
with some bugs fixed (in particular, the handling of -# now works as
documented and does not overwrite argv).
2006-04-02 19:04:24 +00:00
tls
0b7476a655
Remove extra \n from call to warn()
2006-04-02 19:03:55 +00:00
tls
b3de57c6bf
Don't build any of the dialers except Hayes. If anyone is using any of
...
the others (maybe "Courier", but I doubt it) we can easily enough turn
them back on.
Saves 20-30K depending on platform. Not totally insignificant, since this
often goes on install media, or very small systems.
2006-04-02 19:00:40 +00:00
tls
b8dc57b8d9
If we might have two links, we'd better print our program name when we
...
emit an error -- and it would be nice if it were the *right* program name.
Since it's convenient, change most perror calls to warn, and a lot of
fprintf ... exit to errx. Fix at least one fprintf that could run off
the end of its arguments (%s but no argument, how did we never catch this?).
2006-04-02 06:11:45 +00:00
tls
82222cd3ac
Default to no parity instead of even parity. OpenBSD made this change
...
long ago, and I think it makes sense.
2006-04-02 04:28:38 +00:00
tls
685d2e5048
Default the "raisechar" value (for the insane old case-mapping) to NULL.
...
As the same change in the OpenBSD tree says, "if you are crazy enough
to want it, then it can be turned on in /etc/remote."
2006-04-02 04:25:36 +00:00
christos
df58c5cd15
Coverity CID 1660: Plug memory leaks.
2006-04-02 04:17:08 +00:00
tls
8139858166
Default baud rate to 9600 (was 1200) to match Taylor cu.
2006-04-02 04:10:54 +00:00
tls
7d1bef10da
Add the rest of the speeds listed in termios.h. This is not, perhaps, as
...
sensible as the way OpenBSD supports arbitrary speeds; but we hardly add
new speeds often and this change is a lot less invasive.
2006-04-02 04:02:00 +00:00
christos
ceb6edafa6
Coverity CID 922: Fix check against NULL.
2006-04-02 03:50:38 +00:00
christos
472d6fbe72
Coverity CID 878: Remove impossible tests against NULL pointers.
2006-04-02 03:47:26 +00:00