summaryrefslogtreecommitdiff
path: root/lib/libc/gen/uname.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix SCM ID's.David E. O'Brien2002-02-011-3/+3
| | | | Notes: svn path=/head/; revision=90039
* This is kind of a hack, but it should work. Currently, world is brokenPeter Wemm2001-03-241-78/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | because libc/rpc/key_call.c references uname(), and ps/print.c also defines uname(), and ps is linked statically. This leads to a symbol clash. The userland uname(3) kinda sucked anyway as the hostname etc was too short. And since the libc rpc interface now uses the utsname.nodename which gets truncated, I was tempted into doing something about it. Create a new userland uname function, called __xuname() which takes an extra argument that allows you to change the size of the fields. uname() becomes a static inline function in sys/utsname.h that passes the extra argument in. struct utsname has its field members expanded by default now in userland. We still provide a 'uname' externally linkable function for things that either think that they ``know'' the utsname format and assume 32 character strings and bypass the include file, or objects that are linked against old libcs. ie: just about every plausible case that I can think of is covered. Should we ever change the default lengths again, a libc major bump should not be required as the size is now passed to the function. XXX the uname(2) in the kernel is for FreeBSD 1.1 binary compatability! All the uname(3) functions that are exported to userland are actually implemented in libc with sysctl. uname(1) uses sysctl directly and does not call uname(3). PR: bin/4688 Notes: svn path=/head/; revision=74729
* $Id$ -> $FreeBSD$Peter Wemm1999-08-281-1/+1
| | | | Notes: svn path=/head/; revision=50476
* Revert $FreeBSD$ to $Id$Peter Wemm1997-02-221-1/+1
| | | | Notes: svn path=/head/; revision=22993
* Make the long-awaited change from $Id$ to $FreeBSD$Jordan K. Hubbard1997-01-141-1/+1
| | | | | | | | | | | This will make a number of things easier in the future, as well as (finally!) avoiding the Id-smashing problem which has plagued developers for so long. Boy, I'm glad we're not using sup anymore. This update would have been insane otherwise. Notes: svn path=/head/; revision=21673
* Null terminate all strings returned by the dummy uname() routine,Mike Pritchard1995-07-311-9/+13
| | | | | | | | | | and make sure that the version string is somewhat sane. This closes out PR#462. Reviewed by: Bruce Evans Notes: svn path=/head/; revision=9817
* Remove trailing whitespace.Rodney W. Grimes1995-05-301-4/+4
| | | | Notes: svn path=/head/; revision=8870
* sysctl(3) can return an error (setting errno to ENOMEM) when theGarrett Wollman1994-10-131-14/+45
| | | | | | | | fields in the utsname structure are too small to hold their corresponding MIB variables. Don't return an error in this case. Notes: svn path=/head/; revision=3565
* BSD 4.4 Lite Lib SourcesRodney W. Grimes1994-05-271-0/+90
Notes: svn path=/cvs2svn/branches/unlabeled-1.1.1/; revision=1573