dragonfly.git
15 years agoIf we change obj_rtld.path after initialising __progname, make sure we
Joerg Sonnenberger [Fri, 4 Feb 2005 01:23:16 +0000 (01:23 +0000)]
If we change obj_rtld.path after initialising __progname, make sure we
change __progname to point at the new storage otherwise it ends up
pointing at freed memory which leads to confusing garbled error messages.

rtld.c, 1.95
Obtained-from: FreeBSD

15 years agom_clalloc() was improperly assuming that an mcl malloc would always succeed
Matthew Dillon [Fri, 4 Feb 2005 01:14:27 +0000 (01:14 +0000)]
m_clalloc() was improperly assuming that an mcl malloc would always succeed
when in fact it is allowed not to (because M_NULLOK is specified).

Reported-by: EM <EM1897@aol.com>
15 years agogive out a little more information in case of a missing dependency
Joerg Sonnenberger [Fri, 4 Feb 2005 01:06:05 +0000 (01:06 +0000)]
give out a little more information in case of a missing dependency

rtld.c, 1.96
Obtained-from: FreeBSD

15 years agoRemove -DFREEBSD_ELF.
Joerg Sonnenberger [Fri, 4 Feb 2005 00:33:49 +0000 (00:33 +0000)]
Remove -DFREEBSD_ELF.

Verified-by: md5
15 years agoNo need to zero fill memory, mmapped anonymously. Kernel will
Joerg Sonnenberger [Fri, 4 Feb 2005 00:24:23 +0000 (00:24 +0000)]
No need to zero fill memory, mmapped anonymously. Kernel will
return pre-zeroed pages itself.

i386/reloc.c, 1.12
Obtained-from: FreeBSD

15 years agoGenerate more useful -v information on the console during device attach.
Matthew Dillon [Thu, 3 Feb 2005 23:54:22 +0000 (23:54 +0000)]
Generate more useful -v information on the console during device attach.
The complete device chain is output prior to each attach.

The normal device_print_child() is now moved from before the attach
to after the attach so the correct resource information gets reported,
especially the correct IRQ.

15 years agoRemove duplicate #include of <sys/sysctl.h>
Max Okumoto [Thu, 3 Feb 2005 23:41:05 +0000 (23:41 +0000)]
Remove duplicate #include of <sys/sysctl.h>

15 years agoProvide a mechanism for dumping relocation information.
Joerg Sonnenberger [Thu, 3 Feb 2005 23:28:24 +0000 (23:28 +0000)]
Provide a mechanism for dumping relocation information.

Setting the LD_DUMP_REL_PRE or LD_DUMP_REL_POST environment variables
cause rtld-elf to output a table of all relocations.

This is useful for debugging.

debug.c, 1.3
rtld.c, 1.85
rtld.h, 1.31

Obtained-from: FreeBSD

15 years agoRemove the default VINUMDEBUG option for now. I'll make most of the
Joerg Sonnenberger [Thu, 3 Feb 2005 22:10:57 +0000 (22:10 +0000)]
Remove the default VINUMDEBUG option for now. I'll make most of the
debug code available via KTR later.

15 years agoForced commit to note that I'm removing the default VINUMDEBUG for now.
Joerg Sonnenberger [Thu, 3 Feb 2005 22:07:12 +0000 (22:07 +0000)]
Forced commit to note that I'm removing the default VINUMDEBUG for now.
Most debug informations will be made available via KTR again.

15 years agostrcmp() needs string.h
Joerg Sonnenberger [Thu, 3 Feb 2005 22:05:27 +0000 (22:05 +0000)]
strcmp() needs string.h

15 years agoexit() needs stdlib.h
Joerg Sonnenberger [Thu, 3 Feb 2005 22:03:31 +0000 (22:03 +0000)]
exit() needs stdlib.h

15 years agoUse M_ZERO instead of manual bzero.
Joerg Sonnenberger [Thu, 3 Feb 2005 20:48:08 +0000 (20:48 +0000)]
Use M_ZERO instead of manual bzero.

15 years agoCleanup whitespace at end of file.
Max Okumoto [Thu, 3 Feb 2005 18:43:08 +0000 (18:43 +0000)]
Cleanup whitespace at end of file.

15 years agoCleanup some white space.
Max Okumoto [Thu, 3 Feb 2005 18:36:26 +0000 (18:36 +0000)]
Cleanup some white space.

15 years agoRemove debug flag which slipped into last commit.
Joerg Sonnenberger [Thu, 3 Feb 2005 17:44:21 +0000 (17:44 +0000)]
Remove debug flag which slipped into last commit.

15 years agoDon't define _Bool for GCC 3.0 and later. It was added was builtin
Joerg Sonnenberger [Thu, 3 Feb 2005 17:40:15 +0000 (17:40 +0000)]
Don't define _Bool for GCC 3.0 and later. It was added was builtin
on November 13 2000, which is why before the gcc 3.0 release.

15 years agoFully separate the kcore initialisation and the kinfo wrapper.
Joerg Sonnenberger [Thu, 3 Feb 2005 17:28:40 +0000 (17:28 +0000)]
Fully separate the kcore initialisation and the kinfo wrapper.
Call kcore_wrapper_open if you want the kinfo wrapper, otherwise
kcore_open. This fixes the segfaults in pstat.

Reported-by: Sven Willenberger <sven@dmv.com>
15 years agoNo namespace pollution in sys/cdefs.h. Rename VM_CACHELINE_SIZE
Joerg Sonnenberger [Thu, 3 Feb 2005 17:11:54 +0000 (17:11 +0000)]
No namespace pollution in sys/cdefs.h. Rename VM_CACHELINE_SIZE
to __VM_CACHELINE_SIZE and use the protected attribut names.

15 years agoRead eaddr in two parts (32 bit read and 16 bit read). This fixes a
Joerg Sonnenberger [Thu, 3 Feb 2005 12:58:44 +0000 (12:58 +0000)]
Read eaddr in two parts (32 bit read and 16 bit read). This fixes a
compiler warning too.

Tested-by: <jkanowitz@snet.net>
15 years agoGCC 1.x is dead.
Joerg Sonnenberger [Thu, 3 Feb 2005 11:20:31 +0000 (11:20 +0000)]
GCC 1.x is dead.

15 years agoFree temporary buffer in the buffer overflow case too.
Joerg Sonnenberger [Thu, 3 Feb 2005 09:20:27 +0000 (09:20 +0000)]
Free temporary buffer in the buffer overflow case too.

15 years agoAdd information about return code for immutable files.
David Rhodus [Thu, 3 Feb 2005 02:47:26 +0000 (02:47 +0000)]
Add information about return code for immutable files.

Noted by : Guy Harris <guy@alum.mit.edu>

15 years agoAdd information about return code for immutable files.
David Rhodus [Thu, 3 Feb 2005 02:43:44 +0000 (02:43 +0000)]
Add information about return code for immutable files.

Noted by : Guy Harris <guy@alum.mit.edu>

15 years agoDon't use the statfs field f_mntonname in filesystems. For the userland
Joerg Sonnenberger [Wed, 2 Feb 2005 21:34:19 +0000 (21:34 +0000)]
Don't use the statfs field f_mntonname in filesystems. For the userland
export code, it can synthesized from mnt_ncp.
For debugging code, use f_mntfromname, it should be enough to find
culprit. The vfs_unmountall doesn't use code_fullpath to avoid problems
with resource allocation and to make it more likely that a call from ddb
succeds.
Change getfsstat and fhstatfs to not show directories outside a chroot
path, with the exception of the filesystem counting the chroot root itself.

15 years ago- Remove unnecessary header (time.h)
Liam J. Foy [Wed, 2 Feb 2005 20:42:15 +0000 (20:42 +0000)]
- Remove unnecessary header (time.h)
- Tidy up some sentences
- Remove white space

15 years agoFix a hard-to-find bugaboo in the struct file list sysctl. The code was
Matthew Dillon [Wed, 2 Feb 2005 20:36:09 +0000 (20:36 +0000)]
Fix a hard-to-find bugaboo in the struct file list sysctl.  The code was
not properly calculating the required buffer size because it was ignoring
the fact that descriptor tables are shared between threaded processes.  Simply
adding fp->f_count for the fp's in the filehead list doesn't do the job if
a system is running threaded processes.

Reported-by: "Erik P. Skaalerud" <erik@pentadon.com>
15 years agoRaise WARNS to 6:
Chris Pressey [Wed, 2 Feb 2005 20:27:51 +0000 (20:27 +0000)]
Raise WARNS to 6:

- Rename a local variable to avoid conflict with the name of a global;
- Mark some function arguments as unused;
- Make local functions static and fix up function prototypes;
- Use better logic for checking return value from snprintf().

15 years agoDon't cast int ==> unsigned char ==> char, int ==> char is enough.
Joerg Sonnenberger [Wed, 2 Feb 2005 18:46:01 +0000 (18:46 +0000)]
Don't cast int ==> unsigned char ==> char, int ==> char is enough.

Submitted-by: Andreas Hauser <andy@splashground.de>
15 years ago- Reduce the size of msg (1024 -> 80)
Liam J. Foy [Wed, 2 Feb 2005 15:21:21 +0000 (15:21 +0000)]
- Reduce the size of msg (1024 -> 80)
- Remove double '' when writing a warning
- Remove unnecessary check

15 years agoQuery A records before AAAA records in getaddrinfo() when AF_UNSPEC
Hiroki Sato [Wed, 2 Feb 2005 15:10:55 +0000 (15:10 +0000)]
Query A records before AAAA records in getaddrinfo() when AF_UNSPEC
is specified.  Some broken DNS servers return NXDOMAIN against
non-existent AAAA queries, even when it should return NOERROR
with empty return records.  This is a problem for an IPv4/IPv6 dual
stack node since the NXDOMAIN returned by the first query of
an AAAA record makes it give up querying the A record.  Also, this
behavior has been recognized as a potential denial-of-service attack.

Note that although the query order has been changed, the result
linked-list of (struct addrinfo) set by getaddrinfo() is still
in order of AF_INET6 -> AF_INET.

Reference: http://www.kb.cert.org/vuls/id/714121

15 years agoFix CPP buglet.
Joerg Sonnenberger [Wed, 2 Feb 2005 14:14:20 +0000 (14:14 +0000)]
Fix CPP buglet.

Submitted-by: Andreas Hauser <andy@splashground.de>
15 years agoChange default perl version to 5.8.6
Joerg Sonnenberger [Wed, 2 Feb 2005 12:57:27 +0000 (12:57 +0000)]
Change default perl version to 5.8.6

15 years agoAdd __dead2 to enomem()
Max Okumoto [Wed, 2 Feb 2005 12:29:43 +0000 (12:29 +0000)]
Add __dead2 to enomem()

Taken-from: FreeBSD

15 years agoRaise WARNS to 6:
Chris Pressey [Wed, 2 Feb 2005 07:59:48 +0000 (07:59 +0000)]
Raise WARNS to 6:

- Rename a local variable to avoid conflict with the name of a
  library function.
- Mark some function arguments as unused.
- ANSIfy function definitions.
- Declare local functions as static.

15 years agoIf dhclient fails, an interface could be left with an IP address of 0.0.0.0.
Jeffrey Hsu [Wed, 2 Feb 2005 07:51:19 +0000 (07:51 +0000)]
If dhclient fails, an interface could be left with an IP address of 0.0.0.0.
Ignore attempts to send UDP packets sent this partially configured interface
rather than panic'ing.

Reported by: many including dillon, eirikn, drhodus
Tested by: drhodus

15 years agoRaise WARNS to 6:
Chris Pressey [Wed, 2 Feb 2005 07:00:47 +0000 (07:00 +0000)]
Raise WARNS to 6:

- Use fully specified structures for constant array initializers.
- Declare local functions as static.
- Add/remove prototypes as needed.
- Remove ``register'' keywords.
- Rename local variables where they shadow the names of globals.

Submitted-by: Larry Lansing <lansil_at_fuzzynerd_dot_com>
Additional-tweaks-by: cpressey
15 years agoRaise WARNS to 6:
Chris Pressey [Wed, 2 Feb 2005 06:39:09 +0000 (06:39 +0000)]
Raise WARNS to 6:

- Constify one function argument, mark others as unused.

Submitted-by: Larry Lansing <lansil_at_fuzzynerd_dot_com>
15 years agoRaise WARNS to 6:
Chris Pressey [Wed, 2 Feb 2005 06:22:30 +0000 (06:22 +0000)]
Raise WARNS to 6:

- Add function prototypes.

Submitted-by: Larry Lansing <lansil_at_fuzzynerd_dot_com>
15 years agoMinor adustments to avoid a signed/unsigned comparison compiler warning
Matthew Dillon [Wed, 2 Feb 2005 06:14:51 +0000 (06:14 +0000)]
Minor adustments to avoid a signed/unsigned comparison compiler warning
plus a small cleanup.  No operational changes.

15 years agoThe last commit broke ttyname(), which broke ssh -1. Fix that, plus
Matthew Dillon [Wed, 2 Feb 2005 05:42:01 +0000 (05:42 +0000)]
The last commit broke ttyname(), which broke ssh -1.  Fix that, plus
cleanup a static variable overloading of the name 'buf' to avoid confusion.

Reported-by: Steve Mynott, Peter Avalos
15 years agoFix type-o in last commit.
Matthew Dillon [Wed, 2 Feb 2005 04:57:15 +0000 (04:57 +0000)]
Fix type-o in last commit.

15 years agoChange the ALTQ macro stubs to actually work. For the current ALTQ less
Joerg Sonnenberger [Tue, 1 Feb 2005 23:14:54 +0000 (23:14 +0000)]
Change the ALTQ macro stubs to actually work. For the current ALTQ less
kernel, drv queue and interface queue are identical.

15 years agoAdd a intrmask_t pointer to register_int() and register_swi(), and make
Matthew Dillon [Tue, 1 Feb 2005 22:41:31 +0000 (22:41 +0000)]
Add a intrmask_t pointer to register_int() and register_swi(), and make
the interrupt thread loop set the spl for the duration of the call to the
handler.

Allow interrupt threads to be run with or without a critical section based
on the kern.int_use_crit_section sysctl.  The default is to conservatively
run with a critical section for now.

Turning this off will cause cpu usage in interrupts to be properly accounted
for by top, systat, and ps.

15 years agoFix an invariant test that tries to catch locked tokens being left on the
Matthew Dillon [Tue, 1 Feb 2005 22:36:26 +0000 (22:36 +0000)]
Fix an invariant test that tries to catch locked tokens being left on the
stack after a stack pop.

Submitted-by: Aggelos Economopoulos <aoiko@cc.ece.ntua.gr>
15 years agoGCC 3.4 doesn't include a #pragma weak reference, if the symbol
Joerg Sonnenberger [Tue, 1 Feb 2005 22:35:19 +0000 (22:35 +0000)]
GCC 3.4 doesn't include a #pragma weak reference, if the symbol
doesn't exist anyway. This broke the build obviously.
Change the places in libc which used the pragma to use __weak_reference.

15 years agoCount time spent in interrupts in the overall runtime calculation so ps
Matthew Dillon [Tue, 1 Feb 2005 22:33:43 +0000 (22:33 +0000)]
Count time spent in interrupts in the overall runtime calculation so ps
properly reports the cpu usage of interrupt threads.

15 years ago- Fix some duplicate commenting for struct Job, struct GNode and
Max Okumoto [Tue, 1 Feb 2005 22:05:36 +0000 (22:05 +0000)]
- Fix some duplicate commenting for struct Job, struct GNode and
  struct Shell by removing one version and inlining the comments
  into the structure declaration (the comments have been somewhat
  outdated).

- Remove the 3rd clause (from 4) of the BSD license because those
  files have only the UCB copyright

Taken-from: FreeBSD

15 years agoDon't double assign -W -Wall and some more warning flags.
Joerg Sonnenberger [Tue, 1 Feb 2005 21:55:22 +0000 (21:55 +0000)]
Don't double assign -W -Wall and some more warning flags.
WARNS=1 is -Wunknown-pragmas and for gcc 3.4 -Wsystem-headers.
WARNS=2 adds -Wall
WARNS=3 equals to what was set before for WARNS>0.
For WARNS >= 5 don't specify -Wno-uninitialized anymore.

15 years agoFix bug in last commit that broke 'df'. 'sfsp' is now a structural pointer
Matthew Dillon [Tue, 1 Feb 2005 21:52:11 +0000 (21:52 +0000)]
Fix bug in last commit that broke 'df'.  'sfsp' is now a structural pointer
so we increment it by one, not by sizeof(*sp).

15 years ago- Improve how we handle the APM device. Much cleaner code.
Liam J. Foy [Tue, 1 Feb 2005 19:51:28 +0000 (19:51 +0000)]
- Improve how we handle the APM device. Much cleaner code.

15 years agoMove to ND_IFINFO().
Hiroki Sato [Tue, 1 Feb 2005 19:39:07 +0000 (19:39 +0000)]
Move to ND_IFINFO().

15 years ago- Large cleanup/changes to man page.
Liam J. Foy [Tue, 1 Feb 2005 18:43:15 +0000 (18:43 +0000)]
- Large cleanup/changes to man page.

Submitted by: Maxime Labelle <mlabelle@vt220.com>

15 years ago- Do not depend on stat_warn_cont when executing commands.
Liam J. Foy [Tue, 1 Feb 2005 18:32:01 +0000 (18:32 +0000)]
- Do not depend on stat_warn_cont when executing commands.

15 years ago- Tie battd into the build
Liam J. Foy [Tue, 1 Feb 2005 18:20:32 +0000 (18:20 +0000)]
- Tie battd into the build

15 years agostyle(9)
Eirik Nygaard [Tue, 1 Feb 2005 17:53:01 +0000 (17:53 +0000)]
style(9)

15 years ago- Initial import of the battd utility.
Liam J. Foy [Tue, 1 Feb 2005 17:16:36 +0000 (17:16 +0000)]
- Initial import of the battd utility.

The battd daemon monitors the status of the battery or batteries present
in the system.

15 years ago*_load_pallete's second argument should be const.
Joerg Sonnenberger [Tue, 1 Feb 2005 16:30:02 +0000 (16:30 +0000)]
*_load_pallete's second argument should be const.

15 years ago- Nuke #ifdef SCOPEDROUTING. It was never enabled and is useless now[1].
Hiroki Sato [Tue, 1 Feb 2005 16:09:37 +0000 (16:09 +0000)]
- Nuke #ifdef SCOPEDROUTING.  It was never enabled and is useless now[1].
- Add in6_domifattach(), in6_domifdetach(), and ifp->if_afdata[2].
- ANSIfy.

Obtained from: KAME via FreeBSD
References (FreeBSD):

net/
if.c 1.168[2]
if_var.h 1.59[2]

netinet/
icmp6.h 1.12[2]
tcp_input.c 1.209[2]

netinet6/
icmp6.c 1.38[1], 1.39[2]
in6.c 1.30[1], 1.31[2]
ip6_forward.c 1.20[1]
in6_gif.c 1.15[1]
in6_proto.c 1.25[2]
in6_ifattach.c 1.17[1], 1.18[2]
ip6_input.c 1.53[1], 1.57[2]
ip6_output.c 1.58[1], 1.59[2]
in6_src.c 1.14[2]
in6_var.h 1.14[2]
nd6.c 1.30[1], 1.32[2]
nd6.h 1.13[2]
nd6_nbr.c 1.19[2]
nd6_rtr.c 1.20[2]
scope6.c 1.8[2]
scope6_var.h 1.3[2]

sys/
domain.h 1.18[2]
kernel.h 1.113[2]

15 years agoAlways honor fdp->fd_nrdir as root. Once the loop reached NCF_ROOT,
Joerg Sonnenberger [Tue, 1 Feb 2005 14:43:44 +0000 (14:43 +0000)]
Always honor fdp->fd_nrdir as root. Once the loop reached NCF_ROOT,
fdp->fd_nrdir has to be equal to the current ncp or the original
ncp is not below fdp->fd_nrdir. In the latter case, just return "/"
as fullpath.

15 years agoRemove SCARG junk.
Joerg Sonnenberger [Tue, 1 Feb 2005 13:55:49 +0000 (13:55 +0000)]
Remove SCARG junk.

Suggested-by: drhodus
15 years ago- Add comments to clarify code
Max Okumoto [Tue, 1 Feb 2005 13:05:48 +0000 (13:05 +0000)]
- Add comments to clarify code
- Rewrite compliated for loop as a while loop.

Tested by comparing object files.

15 years agoImport initial version of 1:1 pthread library.
David Xu [Tue, 1 Feb 2005 12:38:27 +0000 (12:38 +0000)]
Import initial version of 1:1 pthread library.

15 years agoAdded code to handle DragonFly tags in expected results files.
Max Okumoto [Tue, 1 Feb 2005 11:19:38 +0000 (11:19 +0000)]
Added code to handle DragonFly tags in expected results files.

15 years agoAdd regression test infrastructure.
Max Okumoto [Tue, 1 Feb 2005 07:07:15 +0000 (07:07 +0000)]
Add regression test infrastructure.

15 years agoencap_getarg() was not properly loading the pointer argument associated
Matthew Dillon [Tue, 1 Feb 2005 05:34:33 +0000 (05:34 +0000)]
encap_getarg() was not properly loading the pointer argument associated
with the m_tag, returning garbage which would then panic the box.  The
code path is primarily used by the GIF interface.

Crash-Reported-by: Peter Avalos <pavalos@theshell.com>
Reviewed-by: Jeffrey Hsu
15 years agoHide pure kernel threads from jailed processes.
Joerg Sonnenberger [Tue, 1 Feb 2005 02:25:45 +0000 (02:25 +0000)]
Hide pure kernel threads from jailed processes.

15 years agoMake const correct.
Joerg Sonnenberger [Tue, 1 Feb 2005 02:19:43 +0000 (02:19 +0000)]
Make const correct.

15 years agoAdd prototype for ciss_print0 in place.
Joerg Sonnenberger [Tue, 1 Feb 2005 02:16:58 +0000 (02:16 +0000)]
Add prototype for ciss_print0 in place.

15 years agoRemove compat code for anything, but DragonFly.
Joerg Sonnenberger [Tue, 1 Feb 2005 00:51:50 +0000 (00:51 +0000)]
Remove compat code for anything, but DragonFly.

15 years agoRemove unused variable.
Joerg Sonnenberger [Tue, 1 Feb 2005 00:05:28 +0000 (00:05 +0000)]
Remove unused variable.

15 years agoRemove GPLed fpemulation, old rp, old awe and pcic.
Joerg Sonnenberger [Mon, 31 Jan 2005 23:44:35 +0000 (23:44 +0000)]
Remove GPLed fpemulation, old rp, old awe and pcic.
dgb is still in, until the persons having the hardware decide that
digi(4) works for them.

Correct spelling of deprecation.

15 years agoMy first commit.
David Xu [Mon, 31 Jan 2005 23:44:17 +0000 (23:44 +0000)]
My first commit.

15 years agoAdd jail_attach support.
Joerg Sonnenberger [Mon, 31 Jan 2005 22:29:59 +0000 (22:29 +0000)]
Add jail_attach support.

Inspired-by: FreeBSD
Manpage-by: Paul Herman
Add sysctl jail.list and jailed() helper functions.

Obtained-from: FreeBSD

Add jexec and jls.

Obtained-from: FreeBSD

Move reference counting into prison_hold / prison_free functions.
Fix an incorrect increment in fork1, the prison structure is not
directly copied and the cr reference counting applies to prison here
too. Begin moving explicit pointer checks for cr_prison != NULL
to the new jailed() function. Move the sys/varsym.h include in
sys/jail.h to the kernel part. Prepare for jail-local securelevel.

15 years agoRemove _THREAD_SAFE depenendancies. Create weakly associated stubs for
Matthew Dillon [Mon, 31 Jan 2005 22:29:48 +0000 (22:29 +0000)]
Remove _THREAD_SAFE depenendancies.  Create weakly associated stubs for
posix threading calls used by libc and weak associations for procedures that
a threading library would otherwise have to override.  This allows a program
to be linked with libc, or linked with libc + a threading library.  libc_r
will be deprecated over time.

Traditionally libc_r had to be linked against a threading library rather then
libc.  Linux, FreeBSD, and other UNIXes have moved either t oa thread-safe
libc or a thread-capable libc.  The threading capability is accomplished by
making the appropriate thread locking calls and providing weakly referenced
dummy stub functions for the case where a threading library is not linked in.
Certain third party software, namely XFree/XOrg, also assume threading
stubs in libc.

This is precursor work to a port of David Xu's 1:1 threading library and is
also intended as a basis to allow DragonFly to support multiple threading
libraries.

Ported-by: David Rhodus <sdrhodus@gmail.com>
Primarily-ported-from: FreeBSD
Testing and bug fixes by David Xu and Matt Dillon

15 years agoInclude jail.h after proc.h to get struct ucred.
Joerg Sonnenberger [Mon, 31 Jan 2005 22:03:48 +0000 (22:03 +0000)]
Include jail.h after proc.h to get struct ucred.
Fix the printfs for cp_time, it's uint64_t now.

15 years agoAdd missing "return(error)".
Joerg Sonnenberger [Mon, 31 Jan 2005 21:55:18 +0000 (21:55 +0000)]
Add missing "return(error)".

15 years agoDefine in_inithead in net/route.h, it's purpose is the initialisation
Joerg Sonnenberger [Mon, 31 Jan 2005 21:44:10 +0000 (21:44 +0000)]
Define in_inithead in net/route.h, it's purpose is the initialisation
of the AF_INET routing table. This fixes a warning about a missing
prototype in netinet/in_rmx.c and removes the local extern in in_proto.c

15 years agoRemove unused local variable.
Joerg Sonnenberger [Mon, 31 Jan 2005 21:41:00 +0000 (21:41 +0000)]
Remove unused local variable.

15 years agoBuglet in last commit, the first argument of bpf_ptap is the actual bpf_if.
Joerg Sonnenberger [Mon, 31 Jan 2005 21:40:04 +0000 (21:40 +0000)]
Buglet in last commit, the first argument of bpf_ptap is the actual bpf_if.

15 years agoUse PRIx32 to fix compiler warning correctly.
Joerg Sonnenberger [Mon, 31 Jan 2005 21:39:32 +0000 (21:39 +0000)]
Use PRIx32 to fix compiler warning correctly.

15 years agoFix warning by adding explicit () around addition.
Joerg Sonnenberger [Mon, 31 Jan 2005 21:37:52 +0000 (21:37 +0000)]
Fix warning by adding explicit () around addition.
cmp proves that this is identical to before.

15 years agosys/types.h ==> sys/param.h
Joerg Sonnenberger [Mon, 31 Jan 2005 21:27:56 +0000 (21:27 +0000)]
sys/types.h ==> sys/param.h

15 years agosys/types.h ==> sys/param.h
Joerg Sonnenberger [Mon, 31 Jan 2005 21:20:58 +0000 (21:20 +0000)]
sys/types.h ==> sys/param.h

15 years ago- Move deallocation of Buffer object to end of routine.
Max Okumoto [Mon, 31 Jan 2005 21:13:07 +0000 (21:13 +0000)]
- Move deallocation of Buffer object to end of routine.

15 years agoFixes in main.c
Max Okumoto [Mon, 31 Jan 2005 21:11:26 +0000 (21:11 +0000)]
Fixes in main.c
- Cleanup VPATH variable expansion and parsing.
- Cleanup -V flag handling.
- Added comments.
- Fixed negative logic in if-statements.

15 years agoThe last commit couldn't handle cases when $GZIP contained
YONETANI Tomokazu [Mon, 31 Jan 2005 19:28:57 +0000 (19:28 +0000)]
The last commit couldn't handle cases when $GZIP contained
more than one argument and still crashed.
NetBSD CVS keyword is left unchanged as we don't have changes
1.68 and 1.69 yet.

Obtained-from: NetBSD gzip.c revision 1.70

15 years agoRegen.
Joerg Sonnenberger [Mon, 31 Jan 2005 18:18:21 +0000 (18:18 +0000)]
Regen.

15 years agoCleanup last commit. Remove local ncp, it shadows the parameter, add
Joerg Sonnenberger [Mon, 31 Jan 2005 18:11:06 +0000 (18:11 +0000)]
Cleanup last commit. Remove local ncp, it shadows the parameter, add
return(0) and remove unused locals in vn_fullpath.

15 years agoTake advantage of our new namecache topology to generate the actual paths
Matthew Dillon [Mon, 31 Jan 2005 18:05:09 +0000 (18:05 +0000)]
Take advantage of our new namecache topology to generate the actual paths
associated with open file descriptors, root, and working directories,
and the exec binary's file path.

Adjust the width and alignment of some of the columns.

15 years agoDon't copy blindly MAXPATHLEN byte from fullpath. vn_fullpath
Joerg Sonnenberger [Mon, 31 Jan 2005 17:53:57 +0000 (17:53 +0000)]
Don't copy blindly MAXPATHLEN byte from fullpath. vn_fullpath
allocates MAXPATHLEN, but the buffer is utilized from the end.

15 years agoRegen.
Joerg Sonnenberger [Mon, 31 Jan 2005 17:38:30 +0000 (17:38 +0000)]
Regen.

15 years agoAdd jail_attach syscall.
Joerg Sonnenberger [Mon, 31 Jan 2005 17:35:35 +0000 (17:35 +0000)]
Add jail_attach syscall.

15 years agoUncomment the entry for kern_chrot in kern_syscall.h and change the
Joerg Sonnenberger [Mon, 31 Jan 2005 17:20:48 +0000 (17:20 +0000)]
Uncomment the entry for kern_chrot in kern_syscall.h and change the
implementation to take the namecache entry directly.

15 years agoSplit vn_fullpath into cache_fullpath and vn_fullpath. The former just
Joerg Sonnenberger [Mon, 31 Jan 2005 17:17:58 +0000 (17:17 +0000)]
Split vn_fullpath into cache_fullpath and vn_fullpath. The former just
takes a namespace entry directly.

15 years agosys/types.h ==> sys/param.h
Joerg Sonnenberger [Mon, 31 Jan 2005 16:51:09 +0000 (16:51 +0000)]
sys/types.h ==> sys/param.h

15 years agoIn preparation for the jail commit, include sys/param.h instead of sys/types.h.
Joerg Sonnenberger [Mon, 31 Jan 2005 16:50:33 +0000 (16:50 +0000)]
In preparation for the jail commit, include sys/param.h instead of sys/types.h.

15 years agoRemove unused compat code like FXP_LOCK, a fake struct mtx.
Joerg Sonnenberger [Mon, 31 Jan 2005 15:39:12 +0000 (15:39 +0000)]
Remove unused compat code like FXP_LOCK, a fake struct mtx.
Remove FXP_UNIT. Don't define sc_if, use the arpcom entry
directly. Use PCIR_BAR instead of PCIR_MAPS.

15 years ago- Add missing disclamer.
Max Okumoto [Mon, 31 Jan 2005 09:49:14 +0000 (09:49 +0000)]
- Add missing disclamer.

15 years ago- Convert negative logic, so code is easyer to read.
Max Okumoto [Mon, 31 Jan 2005 08:30:51 +0000 (08:30 +0000)]
- Convert negative logic, so code is easyer to read.

- Start using Buffer objects, instead of c strings.  That way we
  can pass back one object, instead of passing back seperate length
  and character arrays.