Commit Graph

9320 Commits

Author SHA1 Message Date
Hajimu UMEMOTO
65033d4fcb set IPV6_V6ONLY.
Obtained from:	KAME
MFC after:	1 week
2003-08-17 16:08:56 +00:00
Hajimu UMEMOTO
1dd7cfc46f - die if malloc fails.
- use strlcpy.

Obtained from:	KAME
MFC after:	1 week
2003-08-17 16:07:57 +00:00
Hajimu UMEMOTO
be71e4ad8a use strncpy
Obtained from:	KAME
MFC after:	1 week
2003-08-17 16:06:52 +00:00
Hajimu UMEMOTO
4c4ac8c03d "sin" is a reserved C library function name. use sin6
Obtained from:	KAME
MFC after:	1 week
2003-08-17 16:05:49 +00:00
Hajimu UMEMOTO
e5a9696004 We don't need __ss hack.
MFC after:	1 week
2003-08-17 16:03:58 +00:00
Hajimu UMEMOTO
96316581fc backout 1.11. ifname in struct ifreq should be copyed by strncpy.
Pointed out by:	itojun
2003-08-17 11:54:58 +00:00
Hajimu UMEMOTO
9a364ca35a - improved the -a option. it can probe a interface automatically when
the interface wake up.  it can be started anytime even when there is
  no network interface on the list of intarfaces in the kernel.
- get a correct link ID for each interface at initialization
  (using scope libraries if HAVE_SCOPELIB is defined).
- fill in sin6_scope_id correctly before sendmsg().

Obtained from:	KAME
MFC after:	1 week
2003-08-17 11:11:32 +00:00
Philippe Charnier
96d282ece6 add FBSDID, compare getopt() against -1, use fprintf() + exit() in usage()
instead of errx() to get the message starting with "usage:".
2003-08-17 09:06:08 +00:00
Philippe Charnier
b0fed5c6b6 Make it clear that -a flag and interface parameter are mutually exclusive 2003-08-16 22:23:16 +00:00
Hajimu UMEMOTO
4774e8e607 use strlcpy().
Pointed out by:	Pawel Jakub Dawidek <nick@garage.freebsd.pl>
MFC after:	1 week
2003-08-16 20:19:20 +00:00
Philippe Charnier
336ea56a67 add section name
Approved by: Nate Lawson
2003-08-16 19:59:53 +00:00
Hajimu UMEMOTO
131033d55c - added the case of 802.11 to check link status.
- use strncpy just in case.
- __P() cleanup.

Obtained from:	KAME
MFC after:	1 week
2003-08-16 19:00:32 +00:00
Hajimu UMEMOTO
fc35a81b09 - supported a string notation for xxflags.
- deprecate routes#N, as it is hard to keep consistency with
  rtprefixN.  accept any number of "rtprefix", "rtrefix0",
  ..., "rtprefix99".
- deprecate "addrs#N", as it is difficult for users to keep
  consistency with "addrN".
  accept 100 prefix info in maximum - like "addr", "addr0"
  ... "addr99".  WARNS=2 clean on netbsd.
  old configuration file should work just fine.
  behavior change:
  previously, we rejected "addrN" if there's "addr", and we rejected
  "addr" if there is "addrN".  now we accept both without problem.
- when an advertised prefix configured from the kernel has been added
  or invalidated, notice the change in a short delay.
- when invalidating a prefix, do not bark even if there is
  inconsistency about prefix lifetimes.
- wrap more specific route info code into ROUTEINFO.

Obtained from:	KAME
MFC after:	1 week
2003-08-15 19:13:53 +00:00
Hajimu UMEMOTO
dba14c305c use arc4random.
Obtained from:	KAME
MFC after:	1 week
2003-08-15 17:51:51 +00:00
Hajimu UMEMOTO
51964a1b2b variable shared with signal handler needs to be "volatile sig_atomic_t".
Obtained from:	KAME
MFC after:	1 week
2003-08-15 17:20:49 +00:00
Hajimu UMEMOTO
fbcc332a1d set LOG_PERROR for openlog() when running foreground.
Obtained from:	KAME
MFC after:	1 week
2003-08-15 17:15:10 +00:00
Hajimu UMEMOTO
767b3bfd66 dump the content of route information options
Obtained from:	KAME
MFC after:	1 week
2003-08-15 17:04:28 +00:00
Hajimu UMEMOTO
776fdb8006 logged the fact to dump the status.
Obtained from:	KAME
MFC after:	1 week
2003-08-15 16:50:34 +00:00
Hajimu UMEMOTO
145b960169 daemon() has to be called prior to file descriptor setups
(otherwise file descriptors could be closed mistakenly)

Obtained from:	KAME
MFC after:	1 week
2003-08-14 19:05:24 +00:00
Hajimu UMEMOTO
5c706347d5 support poll(2).
Obtained from:	KAME
MFC after:	1 week
2003-08-14 18:43:57 +00:00
Hajimu UMEMOTO
92bdf888a6 daemon() has to be called prior to file descriptor setups
(otherwise file descriptors could be closed mistakenly)

Obtained from:	KAME
MFC after:	1 week
2003-08-14 18:13:34 +00:00
Hajimu UMEMOTO
4eb4a0e6ec - rename some variables.
- remove unused block.

Obtained from:	KAME
MFC after:	1 week
2003-08-14 16:51:13 +00:00
Hajimu UMEMOTO
71aa258ee8 signal handler must take "int" arg.
Obtained from:	KAME
MFC after:	1 week
2003-08-14 16:23:39 +00:00
Hajimu UMEMOTO
eaa5529180 avoid fd_set overrun.
Obtained from:	KAME
MFC after:	1 week
2003-08-14 16:19:59 +00:00
Hajimu UMEMOTO
653b3bd48b signal handler must take "int" arg.
Obtained from:	KAME
MFC after:	1 week
2003-08-14 15:57:52 +00:00
Hajimu UMEMOTO
8998f69b13 avoid fd_set overrun.
Obtained from:	KAME
MFC after:	1 week
2003-08-14 15:47:31 +00:00
Hajimu UMEMOTO
7bc56ec444 decreased too-strong log levels.
Obtained from:	KAME
MFC after:	1 week
2003-08-14 15:21:55 +00:00
Garance A Drosehn
53953407b6 Use STDIN_FILENO, STDOUT_FILENO, and STDERR_FILENO in a few more
places (replacing constants 0, 1 & 2).

Noticed by:
Reviewed by:	md5
MFC after:	4 days
2003-08-13 20:31:33 +00:00
Hartmut Brandt
7cfb043cce Make this WARNS=6 clean by just constifying two local char pointers. 2003-08-13 07:51:06 +00:00
Hartmut Brandt
3af5ca9948 Put all the argument-less options together in the synopsis as required
by style(9).
2003-08-13 07:43:08 +00:00
Hartmut Brandt
1cdff5c9f7 Implement two command line options that allow one to change the
file descriptors that are used for input and output. That allows
one, for example, to use nghook to bi-directionally pipe the
input and output into/from another non-netgraph-aware program.
2003-08-13 07:42:07 +00:00
David E. O'Brien
1c327ba712 Imply NOLIBC_R for PowerPC. 2003-08-13 00:13:37 +00:00
Hajimu UMEMOTO
d7f0819bf0 malloc() may return NULL.
Obtained from:	KAME
MFC after:	1 week
2003-08-12 16:58:32 +00:00
Hajimu UMEMOTO
b6ed844ff2 reduce #ifdef.
MFC after:	1 week
2003-08-11 15:51:54 +00:00
Hajimu UMEMOTO
bb58b617fb use strlcpy() and snprintf().
Obtained from:	KAME
MFC after:	1 week
2003-08-11 15:49:47 +00:00
Nate Lawson
c0efcff271 Remove the band-aid to make these compile on amd64/ia64. 2003-08-11 15:49:14 +00:00
Hajimu UMEMOTO
47742de0ef use int64_t instead of long long.
Obtained from:	KAME
MFC after:	1 week
2003-08-11 15:46:37 +00:00
David Schultz
1f80683394 Instead of unconditionally refusing to install if no swap partitions
are specified, prompt the user with a yes/no box.
2003-08-10 01:04:05 +00:00
Marcel Moolenaar
f88faa54e4 Apparently I limited my testing of the ductape and bubblegum solution
to acpidb. The same problem exists in iasl. Add JIT patching there
too.
Add a comment to both makefiles to increase the chance that both
kludges are removed when a real solution is committed.
2003-08-09 19:11:20 +00:00
Marcel Moolenaar
67fdc6b784 Perform first-aid: unbreak the build for amd64 and ia64 by patching
osunixxf.c on the fly. This avoids having to pull it from the vendor
branch or otherwise pollute the repository with new short-lived files.

This should hold until the real fix arrives.
2003-08-09 07:06:09 +00:00
Hajimu UMEMOTO
be9879af48 Drop MIP6 code. We don't support MIP6 yet.
MFC after:	1 week
2003-08-08 20:14:28 +00:00
Hajimu UMEMOTO
fa19f9be04 KNF, correct typos and cleanup spaces.
Obtained from:	KAME
MFC after:	1 week
2003-08-08 16:56:01 +00:00
Hajimu UMEMOTO
5ed8c16b88 drop the code for the environment where getifaddrs(3) is not
supported.

Obtained from:	KAME
MFC after:	1 week
2003-08-08 16:52:31 +00:00
Hajimu UMEMOTO
8198209700 stop use of register.
Obtained from:	KAME
MFC after:	1 week
2003-08-08 16:47:06 +00:00
Hajimu UMEMOTO
86b032af6c Process the "O bit."
If the value of OtherConfigFlag changes from FALSE to TRUE, the
host should invoke the stateful autoconfiguration protocol,
requesting information.
[RFC 2462 Section 5.5.3]

Obtained from:	KAME
MFC after:	1 week
2003-08-08 16:42:37 +00:00
Hajimu UMEMOTO
1533bed05b __FUNCTION__ --> __func__
Obtained from:	KAME
MFC after:	1 week
2003-08-08 16:38:23 +00:00
Ruslan Ermilov
adcb86e214 Fix a bug that caused i386 to produce broken binaries for big-endian
64-bit platforms.  (size_t is 32bit on i386, but Elf_Shdr.sh_size is
64bit on SPARC64.)
2003-08-08 15:44:17 +00:00
Nate Lawson
3e0387b483 Hook acpidb(8) and iasl(8) up to the build and unhook amldb(8). It will
be going away after a short while but still available in ports.
2003-08-08 03:20:59 +00:00
Nate Lawson
8285491e78 Add man pages for acpidb and iasl 2003-08-07 18:09:17 +00:00
Nate Lawson
a42b754313 Add the acpidb and iasl utilities. This is not yet hooked up to the build.
Obtained from:	acpicatools port by Iwasaki-san
2003-08-07 16:51:50 +00:00