Update from main archive 961219 cvs/libc-961220
authorUlrich Drepper <drepper@redhat.com>
Fri, 20 Dec 1996 01:39:50 +0000 (01:39 +0000)
committerUlrich Drepper <drepper@redhat.com>
Fri, 20 Dec 1996 01:39:50 +0000 (01:39 +0000)
Thu Dec 19 23:28:33 1996  Ulrich Drepper  <drepper@cygnus.com>

* resolv/resolv.h: Update from BIND 4.9.5-P1.
* resolv/res_comp.c: Likewise.
* resolv/res_debug.c: Likewise.
* resolv/Banner: Update version number.

Thu Dec 19 20:58:53 1996  Ulrich Drepper  <drepper@cygnus.com>

* elf/dlfcn.h: Add extern "C" wrapper.

* io/utime.h: Don't define NULL since this isn't allowed in POSIX.
* io/sys/stat.h: Declare `lstat' only if __USE_BSD ||
__USE_XOPEN_EXTENDED.
* locale/locale.h: Define NULL.
* math/math.c: Don't include <errno.h> to define math errors.
* stdlib/stdlib.h: Likewise.
* posix/unistd.h: Don't declare environ.
* posix/sys/utsname.h (struct utsname): Declare member domainname
as __domainname is !__USE_GNU.
* signal/signal.h: Declare size_t only if __USE_BSD ||
__USE_XOPEN_EXTENDED.
* stdio/stdio.h: Don't declare cuserid when __USE_POSIX, but
instead when __USE_XOPEN.
* string/string.h: Define strndup only if __USE_GNU.
* sysdeps/unix/sysv/linux/clock.c: New file.
* sysdeps/unix/sysv/linux/timebits.h: Define CLOCKS_PER_SEC as
1000000 per X/Open standard.
* features.h: Add code to recognize _POSIX_C_SOURCE value 199309.
Define __USE_POSIX199309.
* posix/unistd.h: Declare fdatasync only if __USE_POSIX199309.
* time/time.c: Declare nanosleep only if __USE_POSIX199309.
Patches by RĂ¼diger Helsch <rh@unifix.de>.

* locale/locale.h: Add declaration of newlocale and freelocale.

* new-malloc/Makefile (distibute): Add mtrace.awk.
(dist-routines): Add mcheck and mtrace.
(install-lib, non-lib.a): Define as libmcheck.a.
* new-malloc/malloc.h: Add declaration of __malloc_initialized.
* new-malloc/mcheck.c: New file.
* new-malloc/mcheck.h: New file.
* new-malloc/mtrace.c: New file.
* new-malloc/mtrace.awk: New file.

* posix/unistd.h: Correct prototype for usleep.
* sysdeps/unix/bsd/usleep.c: De-ANSI-declfy.  Correct return type.
* sysdeps/unix/sysv/linux/usleep.c: Real implementation based on
nanosleep.

* signal/signal.h: Change protoype of __sigpause to take two
arguments.  Remove prototype for sigpause.  Add two different
macros named sigpause selected when __USE_BSD or __USE_XOPEN
are defined.  This is necessary since the old BSD definition
of theis function collides with the X/Open definition.
* sysdeps/posix/sigpause.c: Change function definition to also
fit X/Open definition.

* sysdeps/libm-i387/e_exp.S: Make sure stack is empty when the
function is left.
* sysdeps/libm-i387/e_expl.S: Likewise.
Patch by HJ Lu.

1996-12-17  Paul Eggert  <eggert@twinsun.com>

* many, many files: Spelling corrections.
* catgets/catgetsinfo.h (mmapped):
Renamed from mmaped (in struct catalog_info.status).
* mach/err_kern.sub (err_codes_unix), string/stratcliff.c (main):
Fix spelling in message.
* po/libc.pot: Fix spelling in message for `zic'; this anticipates
a fix in the tzcode distribution.

Wed Dec 18 15:48:02 1996  Ulrich Drepper  <drepper@cygnus.com>

* time/strftime.c: Implement ^ flag to cause output be converted
to use upper case characters.

* time/zic.c: Update from ADO tzcode1996n.

Wed Dec 18 14:29:24 1996  Erik Naggum  <erik@naggum.no>

* time/strftime.c (add): Don't change global `i' until all is over.
Define NULL is not already defined.

Tue Dec 17 09:49:03 1996  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>

* libio/iovsprintf.c (_IO_vsprintf): Change `&sf' to `&sf._sbf._f'
to avoid the need for a cast.
* libio/iovsscanf.c (_IO_vsscanf): Likewise.

* sunrpc/rpc/xdr.h: Add prototype for xdr_free.

262 files changed:
ChangeLog
Makeconfig
NEWS
PROJECTS
Rules
catgets/catgets.c
catgets/catgetsinfo.h
catgets/gencat.c
catgets/open_catalog.c
csu/Makefile
csu/gmon-start.c
csu/initfini.c
db/btree/bt_seq.c
db/btree/bt_utils.c
db/btree/btree.h
db/hash/hash.h
db/recno/rec_utils.c
dirent/dirent.h
elf/dlfcn.h
elf/ldd.bash.in
elf/ldd.sh.in
features.h
gmon/Makefile
hurd/hurd.h
hurd/hurd/lookup.h
hurd/hurdmalloc.c
hurd/hurdmalloc.h
hurd/path-lookup.c
hurd/report-wait.c
inet/arpa/telnet.h
inet/protocols/talkd.h
interp.c
intl/dcgettext.c
intl/explodename.c
intl/finddomain.c
intl/l10nflist.c
intl/localealias.c
io/fstat.c
io/lstat.c
io/mknod.c
io/stat.c
io/sys/stat.h
io/utime.h
libio/fileops.c
libio/genops.c
libio/iofgetpos.c
libio/iofsetpos.c
libio/iovsprintf.c
libio/iovsscanf.c
libio/libioP.h
libio/strops.c
locale/C-collate.c
locale/C-ctype.c
locale/iso-4217.def
locale/locale.h
locale/programs/charset.h
locale/programs/ld-collate.c
locale/programs/ld-ctype.c
locale/programs/ld-time.c
locale/programs/locale.c
locale/programs/localedef.c
locale/programs/locfile.c
locale/programs/locfile.h
locale/weight.h
login/logwtmp.c
login/pty.h
mach/Makefile
mach/err_kern.sub
mach/mach/error.h
mach/mach/mach_traps.h
mach/msgserver.c
malloc/Makefile
malloc/malloc.c
malloc/malloc.h
malloc/mcheck-init.c [new file with mode: 0644]
malloc/mcheck.c [new file with mode: 0644]
malloc/mcheck.h [new file with mode: 0644]
malloc/mtrace.awk [new file with mode: 0644]
malloc/mtrace.c [new file with mode: 0644]
manual/arith.texi
manual/creature.texi
manual/errno.texi
manual/filesys.texi
manual/intro.texi
manual/job.texi
manual/libc.texinfo
manual/locale.texi
manual/math.texi
manual/nss.texi
manual/pattern.texi
manual/signal.texi
manual/startup.texi
manual/stdio.texi
manual/terminal.texi
manual/users.texi
math/math.h
math/mathcalls.h
misc/getpass.c
misc/hsearch_r.c
misc/search.h
misc/syslog.c
misc/tsearch.c
nss/XXX-lookup.c
nss/nss_files/files-netgrp.c
nss/nsswitch.h
posix/fnmatch.c
posix/posix1_lim.h
posix/sys/utsname.h
posix/unistd.h
resolv/Banner
resolv/arpa/nameser.h
resolv/inet_net_pton.c
resolv/netdb.h
resolv/nss_dns/dns-network.c
resolv/res_comp.c
resolv/res_debug.c
resolv/res_init.c
resolv/res_send.c
resolv/resolv.h
signal/signal.h
stdio-common/_itoa.c
stdio-common/printf_fp.c
stdio-common/vfprintf.c
stdio-common/vfscanf.c
stdio/internals.c
stdio/stdio.h
stdlib/grouping.h
stdlib/monetary.h
stdlib/qsort.c
stdlib/random.c
stdlib/random_r.c
stdlib/stdlib.h
stdlib/strfmon.c
stdlib/strtod.c
string/envz.c
string/envz.h
string/stratcliff.c
string/strerror.c
string/strerror_r.c
string/string.h
string/strxfrm.c
sunrpc/clnt_raw.c
sunrpc/clnt_tcp.c
sunrpc/clnt_udp.c
sunrpc/pmap_rmt.c
sunrpc/rpc/auth.h
sunrpc/rpc/auth_des.h
sunrpc/rpc/clnt.h
sunrpc/rpc/svc.h
sunrpc/rpc/xdr.h
sunrpc/rpc_clntout.c
sunrpc/rpc_cout.c
sunrpc/rpcsvc/mount.x
sunrpc/rpcsvc/nfs_prot.x
sunrpc/rpcsvc/rex.x
sunrpc/rpcsvc/rusers.x
sunrpc/rpcsvc/sm_inter.x
sunrpc/svc.c
sunrpc/svc_auth.c
sunrpc/svc_raw.c
sunrpc/svc_tcp.c
sunrpc/xdr.c
sunrpc/xdr_array.c
sunrpc/xdr_float.c
sunrpc/xdr_rec.c
sunrpc/xdr_ref.c
sunrpc/xdr_stdio.c
sysdeps/alpha/dl-machine.h
sysdeps/alpha/elf/crtbegin.S
sysdeps/alpha/strrchr.S
sysdeps/generic/crypt-entry.c
sysdeps/generic/crypt.h
sysdeps/generic/memchr.c
sysdeps/generic/memmove.c
sysdeps/generic/strcasecmp.c
sysdeps/generic/strchr.c
sysdeps/generic/strcmp.c
sysdeps/generic/strcspn.c
sysdeps/generic/strncmp.c
sysdeps/generic/strpbrk.c
sysdeps/generic/strrchr.c
sysdeps/generic/strstr.c
sysdeps/gnu/errlist.c
sysdeps/i386/i486/strcat.S
sysdeps/i386/i586/lshift.S
sysdeps/i386/i586/rshift.S
sysdeps/i386/i586/strchr.S
sysdeps/i386/i586/strlen.S
sysdeps/i386/memchr.S
sysdeps/i386/stpcpy.S
sysdeps/i386/stpncpy.S
sysdeps/i386/strchr.S
sysdeps/i386/strcspn.S
sysdeps/i386/strrchr.S
sysdeps/i386/strspn.S
sysdeps/ieee754/ieee754.h
sysdeps/libm-i387/e_exp.S
sysdeps/libm-i387/e_expl.S
sysdeps/libm-i387/s_ceil.S
sysdeps/libm-i387/s_ceilf.S
sysdeps/libm-i387/s_ceill.S
sysdeps/libm-i387/s_floor.S
sysdeps/libm-i387/s_floorf.S
sysdeps/libm-i387/s_floorl.S
sysdeps/libm-ieee754/e_log.c
sysdeps/libm-ieee754/e_sqrt.c
sysdeps/libm-ieee754/k_rem_pio2.c
sysdeps/m68k/lshift.S
sysdeps/m68k/rshift.S
sysdeps/mach/hurd/dirfd.c
sysdeps/mach/hurd/dl-sysdep.c
sysdeps/mach/hurd/getlogin_r.c
sysdeps/mach/hurd/pipe.c
sysdeps/mach/hurd/select.c
sysdeps/mach/thread_state.h
sysdeps/mips/dl-machine.h
sysdeps/posix/sigpause.c
sysdeps/standalone/i960/i960ca.h
sysdeps/standalone/m68k/m68020/mvme136/console.c
sysdeps/stub/dirfd.c
sysdeps/stub/getlogin_r.c
sysdeps/stub/libc-lock.h
sysdeps/stub/local_lim.h
sysdeps/stub/pipe.c
sysdeps/stub/sigpause.c
sysdeps/stub/sys/sem_buf.h
sysdeps/stub/sys/shm_buf.h
sysdeps/stub/tcsetattr.c
sysdeps/stub/tempname.c
sysdeps/unix/bsd/osf/sigaction.h
sysdeps/unix/bsd/sys/reboot.h
sysdeps/unix/bsd/usleep.c
sysdeps/unix/dirfd.c
sysdeps/unix/getlogin_r.c
sysdeps/unix/sysv/linux/clock.c [new file with mode: 0644]
sysdeps/unix/sysv/linux/configure
sysdeps/unix/sysv/linux/configure.in
sysdeps/unix/sysv/linux/gethostid.c
sysdeps/unix/sysv/linux/m68k/mremap.S [new file with mode: 0644]
sysdeps/unix/sysv/linux/sigaction.h
sysdeps/unix/sysv/linux/signum.h
sysdeps/unix/sysv/linux/sleep.c
sysdeps/unix/sysv/linux/sys/module.h
sysdeps/unix/sysv/linux/sys/mtio.h
sysdeps/unix/sysv/linux/sys/sem_buf.h
sysdeps/unix/sysv/linux/sys/shm_buf.h
sysdeps/unix/sysv/linux/termbits.h
sysdeps/unix/sysv/linux/timebits.h
sysdeps/unix/sysv/linux/usleep.c
sysdeps/vax/memchr.s
sysdeps/vax/strchr.s
sysdeps/vax/strncmp.s
sysdeps/vax/strrchr.s
time/strftime.c
time/time.h
time/zic.c
values.h
wcsmbs/wchar.h
wcsmbs/wcschr.c
wcsmbs/wcsncmp.c
wcsmbs/wcspbrk.c
wcsmbs/wcsrchr.c

index 2cdf7b4cbee8d32a3e1fad146daf0f06a789fb66..19d6230b9fb343578c709a21c510a5e04765a753 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,94 @@
+Thu Dec 19 23:28:33 1996  Ulrich Drepper  <drepper@cygnus.com>
+
+       * resolv/resolv.h: Update from BIND 4.9.5-P1.
+       * resolv/res_comp.c: Likewise.
+       * resolv/res_debug.c: Likewise.
+       * resolv/Banner: Update version number.
+
+Thu Dec 19 20:58:53 1996  Ulrich Drepper  <drepper@cygnus.com>
+
+       * elf/dlfcn.h: Add extern "C" wrapper.
+
+       * io/utime.h: Don't define NULL since this isn't allowed in POSIX.
+       * io/sys/stat.h: Declare `lstat' only if __USE_BSD ||
+       __USE_XOPEN_EXTENDED.
+       * locale/locale.h: Define NULL.
+       * math/math.c: Don't include <errno.h> to define math errors.
+       * stdlib/stdlib.h: Likewise.
+       * posix/unistd.h: Don't declare environ.
+       * posix/sys/utsname.h (struct utsname): Declare member domainname
+       as __domainname is !__USE_GNU.
+       * signal/signal.h: Declare size_t only if __USE_BSD ||
+       __USE_XOPEN_EXTENDED.
+       * stdio/stdio.h: Don't declare cuserid when __USE_POSIX, but
+       instead when __USE_XOPEN.
+       * string/string.h: Define strndup only if __USE_GNU.
+       * sysdeps/unix/sysv/linux/clock.c: New file.
+       * sysdeps/unix/sysv/linux/timebits.h: Define CLOCKS_PER_SEC as
+       1000000 per X/Open standard.
+       * features.h: Add code to recognize _POSIX_C_SOURCE value 199309.
+       Define __USE_POSIX199309.
+       * posix/unistd.h: Declare fdatasync only if __USE_POSIX199309.
+       * time/time.c: Declare nanosleep only if __USE_POSIX199309.
+       Patches by RĂ¼diger Helsch <rh@unifix.de>.
+
+       * locale/locale.h: Add declaration of newlocale and freelocale.
+
+       * new-malloc/Makefile (distibute): Add mtrace.awk.
+       (dist-routines): Add mcheck and mtrace.
+       (install-lib, non-lib.a): Define as libmcheck.a.
+       * new-malloc/malloc.h: Add declaration of __malloc_initialized.
+       * new-malloc/mcheck.c: New file.
+       * new-malloc/mcheck.h: New file.
+       * new-malloc/mtrace.c: New file.
+       * new-malloc/mtrace.awk: New file.
+
+       * posix/unistd.h: Correct prototype for usleep.
+       * sysdeps/unix/bsd/usleep.c: De-ANSI-declfy.  Correct return type.
+       * sysdeps/unix/sysv/linux/usleep.c: Real implementation based on
+       nanosleep.
+
+       * signal/signal.h: Change protoype of __sigpause to take two
+       arguments.  Remove prototype for sigpause.  Add two different
+       macros named sigpause selected when __USE_BSD or __USE_XOPEN
+       are defined.  This is necessary since the old BSD definition
+       of theis function collides with the X/Open definition.
+       * sysdeps/posix/sigpause.c: Change function definition to also
+       fit X/Open definition.
+
+       * sysdeps/libm-i387/e_exp.S: Make sure stack is empty when the
+       function is left.
+       * sysdeps/libm-i387/e_expl.S: Likewise.
+       Patch by HJ Lu.
+
+1996-12-17  Paul Eggert  <eggert@twinsun.com>
+
+       * many, many files: Spelling corrections.
+       * catgets/catgetsinfo.h (mmapped):
+       Renamed from mmaped (in struct catalog_info.status).
+       * mach/err_kern.sub (err_codes_unix), string/stratcliff.c (main):
+       Fix spelling in message.
+       * po/libc.pot: Fix spelling in message for `zic'; this anticipates
+       a fix in the tzcode distribution.
+
+Wed Dec 18 15:48:02 1996  Ulrich Drepper  <drepper@cygnus.com>
+
+       * time/strftime.c: Implement ^ flag to cause output be converted
+       to use upper case characters.
+
+       * time/zic.c: Update from ADO tzcode1996n.
+
+Wed Dec 18 14:29:24 1996  Erik Naggum  <erik@naggum.no>
+
+       * time/strftime.c (add): Don't change global `i' until all is over.
+       Define NULL is not already defined.
+
+Tue Dec 17 09:49:03 1996  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
+
+       * libio/iovsprintf.c (_IO_vsprintf): Change `&sf' to `&sf._sbf._f'
+       to avoid the need for a cast.
+       * libio/iovsscanf.c (_IO_vsscanf): Likewise.
+
 Wed Dec 18 03:31:58 1996  Ulrich Drepper  <drepper@cygnus.com>
 
        * dirent/scandir.c: Undo change from Mon Dec  2 15:32:15 1996.
@@ -21,7 +112,7 @@ Wed Dec 18 03:31:58 1996  Ulrich Drepper  <drepper@cygnus.com>
        * new-malloc/malloc.h: Likewise.
 
        * nis/ypclnt.c: Remove prototype for xdr_free.
-       * snrpc/rpc/xdr.h: Add prototype for xdr_free.
+       * sunrpc/rpc/xdr.h: Add prototype for xdr_free.
 
        * manual/nss.texi: Correct description of default values and don't
        meantion NSS as an add-on.
index b61af28b0b95043b8b1d7aaa35d37c732ed0b52e..4f65e6d476a84aada1e1b916d8b80f68433f1f02 100644 (file)
@@ -403,7 +403,7 @@ M4 = m4
 .NOEXPORT:
 
 # We want to echo the commands we're running without
-# umpteem zillion filenames along with it (we use `...' instead)
+# umpteen zillion filenames along with it (we use `...' instead)
 # but we don't want this echoing done when the user has said
 # he doesn't want to see commands echoed by using -s.
 ifneq  "$(findstring s,$(MAKEFLAGS))" ""       # if -s
diff --git a/NEWS b/NEWS
index 0828e574ea7aa69f0739c76feb89c00f0f27df91..37678e12c706d9b7da8f3d6da077f79d70e42d02 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -190,7 +190,7 @@ Version 2.0
   `struct sockaddr *' type, does not generate a type-clash warning.
 
 * New function `error' declared in header file <error.h> is a convenient
-  function for printing error messages and optionally exitting; this is the
+  function for printing error messages and optionally exiting; this is the
   canonical function used in GNU programs.  The new functions `err', `warn',
   and friends in header file <err.h> are the canonical 4.4 BSD interface for
   doing the same thing.
@@ -205,7 +205,7 @@ Version 2.0
 * We have incorporated the 4.4 BSD `db' library (version 1.85).  New header
   files <db.h> and <mpool.h> provide a rich set of functions for several
   types of simple databases stored in memory and in files, and <ndbm.h> is
-  an old `ndbm'-compatbile interface using the `db' functions.  Link with
+  an old `ndbm'-compatible interface using the `db' functions.  Link with
   `-ldb' to get these functions.
 
 * New macro `strdupa' copies a string like `strdup', but uses local stack
index fb3897c7d317c2547d3298eca37557c98c46c298..b7272eee9056a2dff1c7d83f468694e6a3c4ffb4 100644 (file)
--- a/PROJECTS
+++ b/PROJECTS
@@ -74,26 +74,13 @@ contact <bug-glibc@prep.ai.mit.edu>
      It is planed to do a complete rewrite.
 
 
-[10] Add mmap() support to malloc().
-     Doug Lea's malloc implementation might give some ideas.  Perhaps
-     switching completly to his implementation is an option if it
-     a) can work without mmap() support (not all system GNU libc
-       is running on have mmap)
-     b) is without mmap support at least as fast as the current
-       implementation
-     c) will be extended with the current hooks and additional functions
-
-     Please contact bug-glibc@prep.ai.mit.edu before starting to avoid
-     duplicated work.
-
-
-[11] Write access function for netmasks, bootparams, and automount
+[10] Write access function for netmasks, bootparams, and automount
      databases for nss_files and nss_db module.
      The functions should be embedded in the nss scheme.  This is not
      hard and not all services must be supported at once.
 
 
-[12] Rewrite utmp/wtmp functions to use database functions.  This is much
+[11] Rewrite utmp/wtmp functions to use database functions.  This is much
      better than the normal flat file format.
 
      Please contact bug-glibc@prep.ai.mit.edu before starting to avoid
diff --git a/Rules b/Rules
index a06dc041dfb593621f81d6fed8b1822103780321..0cf6c002c0bb379e6aa50e570363e1429a0f951b 100644 (file)
--- a/Rules
+++ b/Rules
@@ -77,7 +77,7 @@ $(common-objpfx)empty.c:
        cp -f /dev/null $@
 common-generated := $(common-generated) dummy.o dummy.c empty.c empty.o
 \f
-# This makes all the auxilliary and test programs.
+# This makes all the auxiliary and test programs.
 
 .PHONY: others tests
 others: $(addprefix $(objpfx),$(others) $(extra-objs))
index ab7d28a68212d23f8d646bac52cf6e36db2b839b..b8e5bf0750c80ded32971973743dfc3626a720d2 100644 (file)
@@ -154,7 +154,7 @@ catclose (nl_catd catalog_desc)
 
   catalog = (__nl_catd) catalog_desc;
 
-  if (catalog->status == mmaped)
+  if (catalog->status == mmapped)
     munmap ((void *) catalog->file_ptr, catalog->file_size);
   else if (catalog->status == malloced)
     free ((void *) catalog->file_ptr);
index 7e0a26f79862c7aa6bd7f501a47e90a28606cee3..292572decfc4d342929c4a19199ed895a73cf5b5 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sys/types.h>
 
@@ -34,7 +34,7 @@ struct catalog_obj
 /* This structure will be filled after loading the catalog.  */
 typedef struct catalog_info
 {
-  enum { closed, nonexisting, mmaped, malloced } status;
+  enum { closed, nonexisting, mmapped, malloced } status;
 
   const char *cat_name;
   const char *env_var;
index 9e7404295ee0d6642118c84f0dab4c978290a169..561b0e523092f30683db67f9c5d1da70d2ecc0ca 100644 (file)
@@ -353,7 +353,7 @@ read_input_file (struct catalog *current, const char *fname)
                    }
                  else
                    {
-                     /* We have found seomthing which looks like a
+                     /* We have found seomthing that looks like a
                         correct identifier.  */
                      struct set_list *runp;
 
@@ -980,7 +980,7 @@ read_old (struct catalog *catalog, const char *file_name)
   /* Try to open catalog, but don't look through the NLSPATH.  */
   __open_catalog (&old_cat_obj, 0);
 
-  if (old_cat_obj.status != mmaped && old_cat_obj.status != malloced)
+  if (old_cat_obj.status != mmapped && old_cat_obj.status != malloced)
     if (errno == ENOENT)
       /* No problem, the catalog simply does not exist.  */
       return;
index 5335b433c74dd1fbd08a1fc5d893fb823612d360..80d2899a36bcd021fd2dbed7eb5694888e0ee296 100644 (file)
@@ -185,7 +185,7 @@ __open_catalog (__nl_catd catalog, int with_path)
                                   MAP_FILE|MAP_COPY|MAP_INHERIT, fd, 0);
   if (catalog->file_ptr != (struct catalog_obj *) -1)
     /* Tell the world we managed to mmap the file.  */
-    catalog->status = mmaped;
+    catalog->status = mmapped;
   else
     {
       /* mmap failed perhaps because the system call is not
@@ -229,7 +229,7 @@ __open_catalog (__nl_catd catalog, int with_path)
     {
       /* Illegal file.  Free he resources and mark catalog as not
         usable.  */
-      if (catalog->status == mmaped)
+      if (catalog->status == mmapped)
        __munmap ((void *) catalog->file_ptr, catalog->file_size);
       else
        free (catalog->file_ptr);
index b61b1d74a3f31dbfdea45eca5be2676aa23c5fb2..790a8feb8cece76fbccd245d66132d107ea57734 100644 (file)
@@ -14,9 +14,9 @@
 # Library General Public License for more details.
 
 # You should have received a copy of the GNU Library General Public
-# License along with the GNU C Library; see the file COPYING.LIB.  If
-# not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-# Cambridge, MA 02139, USA.
+# License along with the GNU C Library; see the file COPYING.LIB.  If not,
+# write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
 
 # This directory contains the C startup code (that which calls main).  This
 # consists of the startfile, built from start.c and installed as crt0.o
@@ -71,7 +71,7 @@ generated += $(crtstuff:=.s)
 omit-deps += $(crtstuff)
 
 # Compile initfini.c to assembly code, which contains embedded shell
-# commands that prodice crti.s-new and crtn.s-new when run.  We need to
+# commands that produce crti.s-new and crtn.s-new when run.  We need to
 # disable emission of .size directives and debugging information, since
 # they will get confused by the splitting of the output we do.
 $(objpfx)cr%i.s $(objpfx)cr%n.s: initfini.c; $(initfini)
@@ -113,4 +113,3 @@ $(addprefix $(objpfx),$(filter-out $(start-installed-name),$(csu-dummies))):
        cp /dev/null $(@:.o=.c)
        $(COMPILE.c) $(@:.o=.c) $(OUTPUT_OPTION)
        rm -f $(@:.o=.c)
-
index 9139306575a807c507219215e8271ef346a1a85f..02c44e2fcfdab083560e493e7a14d6109edf51a1 100644 (file)
@@ -1,21 +1,21 @@
 /* Code to enable profiling at program startup.
-Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sys/types.h>
 #include <sys/gmon.h>
@@ -52,7 +52,7 @@ __gmon_start__ (void)
   /* Start keeping profiling records.  */
   monstartup ((u_long) &_start, (u_long) &etext);
 
-  /* Call _mcleanup before exitting; it will write out gmon.out from the
+  /* Call _mcleanup before exiting; it will write out gmon.out from the
      collected data.  */
   atexit (&_mcleanup);
 }
index dc78e84c2d347183c53d26fd600cdc975ebb5ac0..0fdfe5dcb83f7fdbbb9014678f730df47cabddba 100644 (file)
@@ -11,7 +11,7 @@
    License, the Free Software Foundation gives you unlimited
    permission to link the compiled version of this file with other
    programs, and to distribute those programs without any restriction
-   coming from the use of this file.  (The Libraty General Public
+   coming from the use of this file.  (The Library General Public
    License restrictions do apply in other respects; for example, they
    cover modification of the file, and distribution when not linked
    into another program.)
index eacef2998f9b66304e3138d28081254fc51f7fd9..90f896036f5cd55ef822de0bc03cd77e820e9c6e 100644 (file)
@@ -92,7 +92,7 @@ __bt_seq(dbp, key, data, flags)
        }
 
        /*
-        * If scan unitialized as yet, or starting at a specific record, set
+        * If scan uninitialized as yet, or starting at a specific record, set
         * the scan to a specific key.  Both __bt_seqset and __bt_seqadv pin
         * the page the cursor references if they're successful.
         */
@@ -364,7 +364,7 @@ __bt_first(t, key, erval, exactp)
                        *erval = *ep;
                        return (RET_SUCCESS);
                }
-                       
+
                /*
                 * Walk backwards, as long as the entry matches and there are
                 * keys left in the tree.  Save a copy of each match in case
index 9c1438eb8425d7ab915b3143f039b28c32e75736..1416c7862d7a145b3fb547ca38a680365779a6a1 100644 (file)
@@ -76,7 +76,7 @@ __bt_ret(t, e, key, rkey, data, rdata, copy)
        bl = GETBLEAF(e->page, e->index);
 
        /*
-        * We must copy big keys/data to make them contigous.  Otherwise,
+        * We must copy big keys/data to make them contiguous.  Otherwise,
         * leave the page pinned and don't copy unless the user specified
         * concurrent access.
         */
index 36d35c998bfd59d7ceb89d77f5333bd858b09ada..ab4c5b5ec4e6d388ee5a2466b87de660fa875d7f 100644 (file)
@@ -161,7 +161,7 @@ typedef struct _rinternal {
 #define NRINTERNAL                                                     \
        LALIGN(sizeof(recno_t) + sizeof(pgno_t))
 
-/* Copy a RINTERAL entry to the page. */
+/* Copy a RINTERNAL entry to the page. */
 #define        WR_RINTERNAL(p, nrecs, pgno) {                                  \
        *(recno_t *)p = nrecs;                                          \
        p += sizeof(recno_t);                                           \
index 1c599c112c54f26a5965b11eb975597365f72245..62176d7b1fc9e931d9a3cce7fefb7364967b4bbd 100644 (file)
@@ -104,7 +104,7 @@ typedef struct htab  {              /* Memory resident data structure */
        int             cbucket;        /* Current bucket */
        int             cndx;           /* Index of next item on cpage */
        int             errnum;         /* Error Number -- for DBM
-                                        * compatability */
+                                        * compatibility */
        int             new_file;       /* Indicates if fd is backing store
                                         * or no */
        int             save_file;      /* Indicates whether we need to flush
index baea3fad5066f78fffee38ed3949070b6fd60099..c4c0380461eedebc2c050bcfedeeb006ff502de0 100644 (file)
@@ -90,7 +90,7 @@ dataonly:
                return (RET_SUCCESS);
 
        /*
-        * We must copy big keys/data to make them contigous.  Otherwise,
+        * We must copy big keys/data to make them contiguous.  Otherwise,
         * leave the page pinned and don't copy unless the user specified
         * concurrent access.
         */
index c357be2bcfa71ce393ade8f4aebf0bb18cf7d5cf..ac85b5f1c6131becefffe02c71e0238a1ca6988c 100644 (file)
@@ -117,7 +117,7 @@ extern struct dirent *__readdir __P ((DIR *__dirp));
 extern struct dirent *readdir __P ((DIR *__dirp));
 
 #ifdef __USE_REENTRANT
-/* Reentrant versio of `readdir'.  Return in RESULT a pointer to the
+/* Reentrant version of `readdir'.  Return in RESULT a pointer to the
    next entry.  */
 extern int __readdir_r __P ((DIR *__dirp, struct dirent *entry,
                             struct dirent **result));
index c2b66a7797b452a770bb935f90369423e662451d..973c7e1cc8e11377671005ae7a9f79dc9d491518 100644 (file)
@@ -38,6 +38,8 @@
    objects were loaded.  */
 #define RTLD_NEXT      ((void *) -1l)
 
+__BEGIN_DECLS
+
 /* Open the shared object FILE and map it in; return a handle that can be
    passed to `dlsym' to get symbol values from it.  */
 extern void *dlopen __P ((__const char *__file, int __mode));
@@ -66,4 +68,6 @@ typedef struct
   } Dl_info;
 extern int dladdr __P ((void *__address, Dl_info *__info));
 
+__END_DECLS
+
 #endif /* dlfcn.h */
index 5269708f4358e332c01e3cf37a36a10c2c1bcc56..311ef825503e4b96c02c7b3c3178f0b17d00683d 100644 (file)
@@ -44,7 +44,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
   --version        print version information and exit
 Report bugs to <bug-glibc@prep.ai.mit.edu>."
     exit 0 ;;
-  --)          # Stop option prcessing.
+  --)          # Stop option processing.
     shift; break ;;
   *)
     break ;;
index f8df62d223c326b340a0bc6d500429071411ce18..7b7276f544513d5f1a09c38070f1b431935836ef 100644 (file)
@@ -40,7 +40,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.'
   --version        print version information and exit
 Report bugs to <bug-glibc@prep.ai.mit.edu>.'
     exit 0 ;;
-  --)          # Stop option prcessing.
+  --)          # Stop option processing.
     shift; break ;;
   *)
     break ;;
index 9b20512c513ae2431070e37dbe89d00f7b546a24..4bcff2a19006cb076efb8479c02b618eb06c210e 100644 (file)
@@ -25,7 +25,8 @@
 
    __STRICT_ANSI__     ANSI Standard C.
    _POSIX_SOURCE       IEEE Std 1003.1.
-   _POSIX_C_SOURCE     If ==1, like _POSIX_SOURCE; if ==2 add IEEE Std 1003.2.
+   _POSIX_C_SOURCE     If ==1, like _POSIX_SOURCE; if >=2 add IEEE Std 1003.2;
+                       if >=199309L, add IEEE Std 1003.1b-1993
    _XOPEN_SOURCE       Includes POSIX and XPG things.
    _XOPEN_SOURCE_EXTENDED XPG things and X/Open Unix extensions.
    _BSD_SOURCE         ANSI, POSIX, and 4.3BSD things.
@@ -45,6 +46,7 @@
 
    __USE_POSIX         Define IEEE Std 1003.1 things.
    __USE_POSIX2                Define IEEE Std 1003.2 things.
+   __USE_POSIX199309   Define IEEE Std 1003.1b things.
    __USE_XOPEN         Define XPG things.
    __USE_XOPEN_EXTENDED        Define X/Open Unix things.
    __USE_BSD           Define 4.3BSD things.
@@ -66,6 +68,7 @@
 /* Undefine everything, so we get a clean slate.  */
 #undef __USE_POSIX
 #undef __USE_POSIX2
+#undef __USE_POSIX199309
 #undef __USE_XOPEN
 #undef __USE_XOPEN_EXTENDED
 #undef __USE_BSD
 #undef _POSIX_SOURCE
 #define        _POSIX_SOURCE   1
 #undef _POSIX_C_SOURCE
-#define        _POSIX_C_SOURCE 2
+#define        _POSIX_C_SOURCE 199309L
 #undef _XOPEN_SOURCE
 #define        _XOPEN_SOURCE   1
 #undef _XOPEN_SOURCE_EXTENDED
 #define        _SVID_SOURCE    1
 #endif
 
-/* If none of the ANSI/POSIX macros are defined, use POSIX.1 and POSIX.2.  */
+/* If none of the ANSI/POSIX macros are defined, use POSIX.1 and POSIX.2
+   (and IEEE Std 1003.1b-1993 unless _XOPEN_SOURCE is defined).  */
 #if (!defined (__STRICT_ANSI__) && !defined (_POSIX_SOURCE) && \
      !defined (_POSIX_C_SOURCE))
 #define        _POSIX_SOURCE   1
+#if defined(_XOPEN_SOURCE)
 #define        _POSIX_C_SOURCE 2
+#else
+#define        _POSIX_C_SOURCE 199309L
+#endif
 #endif
 
 #if    (defined (_POSIX_SOURCE) || _POSIX_C_SOURCE >= 1 || \
 #define        __USE_POSIX2    1
 #endif
 
+#if    (defined (_POSIX_C_SOURCE) && _POSIX_C_SOURCE >= 199309L)
+#define        __USE_POSIX199309       1
+#endif
+
 #ifdef _XOPEN_SOURCE
 #define        __USE_XOPEN     1
 #ifdef _XOPEN_SOURCE_EXTENDED
index eff18ee029ccc4e7aad9fc0906febb100ea0e48f..fbbc8175712b7adf1776280da350d4e2bee0dbaa 100644 (file)
@@ -31,7 +31,7 @@ include ../Rules
 CFLAGS-mcount.c := -fno-omit-frame-pointer
 
 # We cannot compile mcount.c with -pg because that would
-# create resursive calls.  Just copy the normal static object.
+# create recursive calls.  Just copy the normal static object.
 # On systems where `profil' is not a system call, the same
 # problem exists for the internal functions in profil.c.
 
index 212db45753e373fe5ce64f18936fa47abc137f9e..bb8e2e7c1112df404dc46a9b1c16c758ca19d8ca 100644 (file)
@@ -222,7 +222,7 @@ extern error_t _hurd_exec (task_t task,
                           char *const envp[]);
 
 
-/* Inform the proc server we have exitted with STATUS, and kill the
+/* Inform the proc server we have exited with STATUS, and kill the
    task thoroughly.  This function never returns, no matter what.  */
 
 extern void _hurd_exit (int status) __attribute__ ((noreturn));
index df5f38ba33dc8d542857e64048cabbf581a72e87..09760be59be94c84c51afa555826e648e586e6ff 100644 (file)
@@ -143,7 +143,7 @@ error_t file_name_path_scan (const char *file_name, const char *path,
 
 /* Lookup FILE_NAME and return the node opened with FLAGS & MODE in result
    (see hurd_file_name_lookup for details), but a simple filename (without
-   any directory prefixes) will be consectutively prefixed with the pathnames
+   any directory prefixes) will be consecutively prefixed with the pathnames
    in the `:' separated list PATH until one succeeds in a successful lookup.
    If none succeed, then the first error that wasn't ENOENT is returned, or
    ENOENT if no other errors were returned.  If PREFIXED_NAME is non-NULL,
index d95b0c34dd790132802d1c852763ab81d5dbe873..cabcdcf0dab358123078bdf562ad14cd111d7b4d 100644 (file)
@@ -37,6 +37,9 @@
 /*
  * HISTORY
  * $Log$
+ * Revision 1.13  1996/12/20 01:32:01  drepper
+ * Update from main archive 961219
+ *
  * Revision 1.12  1996/11/15 19:44:13  thomas
  * Tue Nov 12 16:58:41 1996  Thomas Bushnell, n/BSG  <thomas@gnu.ai.mit.edu>
  *
@@ -58,8 +61,8 @@
  *   (union header): Only define if !MCHECK.
  *   (HEADER_SIZE, HEADER_NEXT, HEADER_FREE, HEADER_CHECK): New macros.
  *   [MCHECK] (MIN_SIZE): Add correct definition for this case.
- *   (more_memory, malloc, free, realloc): Use above macros, and add appropiate
- *     checks & frobs in MCHECK case.
+ *   (more_memory, malloc, free, realloc): Use above macros, and add
+ *     appropriate checks & frobs in MCHECK case.
  *
  * Revision 1.6  1996/03/07 21:13:08  miles
  * (realloc):
  * (HEADER_SIZE, HEADER_NEXT, HEADER_FREE, HEADER_CHECK): New macros.
  * [MCHECK] (MIN_SIZE): Add correct definition for this case.
  * (more_memory, malloc, free, realloc):
- *   Use above macros, and add appropiate checks & frobs in MCHECK case.
+ *   Use above macros, and add appropriate checks & frobs in MCHECK case.
  *
  * Revision 1.4  1994/05/05 11:21:42  roland
  * entered into RCS
  *
  * Revision 2.7  91/05/14  17:57:34  mrt
  *     Correcting copyright
- * 
+ *
  * Revision 2.6  91/02/14  14:20:26  mrt
  *     Added new Mach copyright
  *     [91/02/13  12:41:21  mrt]
- * 
+ *
  * Revision 2.5  90/11/05  14:37:33  rpd
  *     Added malloc_fork* code.
  *     [90/11/02            rwd]
- * 
+ *
  *     Add spin_lock_t.
  *     [90/10/31            rwd]
- * 
+ *
  * Revision 2.4  90/08/07  14:31:28  rpd
  *     Removed RCS keyword nonsense.
- * 
+ *
  * Revision 2.3  90/06/02  15:14:00  rpd
  *     Converted to new IPC.
  *     [90/03/20  20:56:57  rpd]
- * 
+ *
  * Revision 2.2  89/12/08  19:53:59  rwd
  *     Removed conditionals.
  *     [89/10/23            rwd]
- * 
+ *
  * Revision 2.1  89/08/03  17:09:46  rwd
  * Created.
- * 
+ *
  *
  * 13-Sep-88  Eric Cooper (ecc) at Carnegie Mellon University
  *     Changed realloc() to copy min(old size, new size) bytes.
@@ -330,7 +333,7 @@ free(base)
 
 #ifdef MCHECK
        assert (HEADER_CHECK (h) == CHECK_BUSY);
-#endif 
+#endif
 
        fl = HEADER_FREE (h);
        i = fl - malloc_free_list;
@@ -352,7 +355,7 @@ free(base)
        HEADER_NEXT (h) = fl->head;
 #ifdef MCHECK
        HEADER_CHECK (h) = CHECK_FREE;
-#endif 
+#endif
        fl->head = h;
 #ifdef DEBUG
        fl->in_use -= 1;
@@ -454,7 +457,7 @@ print_malloc_free_list()
 }
 #endif DEBUG
 
-static void 
+static void
 malloc_fork_prepare(void)
 /*
  * Prepare the malloc module for a fork by insuring that no thread is in a
@@ -462,13 +465,13 @@ malloc_fork_prepare(void)
  */
 {
     register int i;
-    
+
     for (i = 0; i < NBUCKETS; i++) {
        spin_lock(&malloc_free_list[i].lock);
     }
 }
 
-static void 
+static void
 malloc_fork_parent(void)
 /*
  * Called in the parent process after a fork() to resume normal operation.
index 91286093c46fc5853978dd1674e4cd7fadb19c0b..e11c208a8f44cdcdbdb663305963c0b99fbdcdb3 100644 (file)
@@ -1,4 +1,4 @@
-/* XXX this file is a tempoary hack.
+/* XXX this file is a temporary hack.
 
    All hurd-internal code which uses malloc et al includes this file so it
    will use the internal malloc routines _hurd_{malloc,realloc,free}
index cc1245430335406ac3555493df095b01fc1860a4..04baab06348cc7875403f2b3da60b4b471f915ac 100644 (file)
@@ -80,7 +80,7 @@ file_name_path_scan (const char *file_name, const char *path,
 
 /* Lookup FILE_NAME and return the node opened with FLAGS & MODE in result
    (see hurd_file_name_lookup for details), but a simple filename (without
-   any directory prefixes) will be consectutively prefixed with the pathnames
+   any directory prefixes) will be consecutively prefixed with the pathnames
    in the `:' separated list PATH until one succeeds in a successful lookup.
    If none succeed, then the first error that wasn't ENOENT is returned, or
    ENOENT if no other errors were returned.  If PREFIXED_NAME is non-NULL,
index 20cc1663562e929fcfb72a3c2532a97194bfcab5..491b566d04a04bee70be8306c73d8d3070781ae6 100644 (file)
@@ -93,7 +93,7 @@ describe_port (string_t description, mach_port_t port)
 }
 
 
-/* Common defn so we don't link in the itimer code unnecssarily.  */
+/* Common defn so we don't link in the itimer code unnecessarily.  */
 thread_t _hurd_itimer_thread; /* XXX */
 
 kern_return_t
index 10155a84a87ca1619616bfe5e6d0de4ee604fadd..17255a1c7bb679e5dec0d775a42500d751df917d 100644 (file)
@@ -96,7 +96,7 @@ extern char *telcmds[];
 #define TELOPT_NAOVTS  14      /* negotiate about vertical tab stops */
 #define TELOPT_NAOVTD  15      /* negotiate about vertical tab disposition */
 #define TELOPT_NAOLFD  16      /* negotiate about output LF disposition */
-#define TELOPT_XASCII  17      /* extended ascic character set */
+#define TELOPT_XASCII  17      /* extended ascii character set */
 #define        TELOPT_LOGOUT   18      /* force logout */
 #define        TELOPT_BM       19      /* byte macro */
 #define        TELOPT_DET      20      /* data entry terminal */
@@ -200,7 +200,7 @@ char *telopts[NTELOPTS+1] = {
 #define        NSLC            18
 
 /*
- * For backwards compatability, we define SLC_NAMES to be the
+ * For backwards compatibility, we define SLC_NAMES to be the
  * list of names if SLC_NAMES is not defined.
  */
 #define        SLC_NAMELIST    "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", \
index c523bf590ddf78b701167138778a79a2b97ccac8..6d893adfb53830d9f2e9069dcce07dd79c6f5cb9 100644 (file)
@@ -81,7 +81,7 @@ typedef struct {
 typedef struct {
        u_char  vers;           /* protocol version */
        u_char  type;           /* type of request message, see below */
-       u_char  answer;         /* respose to request message, see below */
+       u_char  answer;         /* response to request message, see below */
        u_char  pad;
        u_int32_t id_num;       /* message id */
        struct  osockaddr addr; /* address for establishing conversation */
index d8a188230361a4c94e49be59aceb8da47d4dfc0d..e08cf22d21ea81934610e7c509313e1b4bea4702 100644 (file)
--- a/interp.c
+++ b/interp.c
@@ -1,4 +1,4 @@
-/* interp - add information about dynamic loader to shared libray obejcts.
+/* interp - add information about dynamic loader to shared library obejcts.
    Copyright (C) 1996 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
index 592f724eb12a1f46b9b4e41689c02700b0f94bd5..fe7299cda1820d69f8a321e12006fb06efaf167b 100644 (file)
@@ -336,7 +336,7 @@ DCGETTEXT (domainname, msgid, category)
        {
          /* The whole contents of CATEGORYVALUE has been searched but
             no valid entry has been found.  We solve this situation
-            by implicitely appending a "C" entry, i.e. no translation
+            by implicitly appending a "C" entry, i.e. no translation
             will take place.  */
          single_locale[0] = 'C';
          single_locale[1] = '\0';
index 7a0d015f3e05480d72ce6653b1a885a2ae701366..7436836f3bc09f1bb140e66a2c435191f49088b4 100644 (file)
@@ -166,7 +166,7 @@ _nl_explode_name (name, language, modifier, territory, codeset,
        }
     }
 
-  /* For CEN sytnax values it might be important to have the
+  /* For CEN syntax values it might be important to have the
      separator character in the file name, not for XPG syntax.  */
   if (syntax == xpg)
     {
index a2977d10c585a30bb37af5eae9a80c74c1215333..ad03a459236a922f6fbfe9c95eac2e13d83a1e1e 100644 (file)
@@ -171,7 +171,7 @@ _nl_find_domain (dirname, locale, domainname)
                           &sponsor, &revision);
 
   /* Create all possible locale entries which might be interested in
-     generalzation.  */
+     generalization.  */
   retval = _nl_make_l10nflist (&_nl_loaded_domains, dirname,
                               strlen (dirname) + 1, mask, language, territory,
                               codeset, normalized_codeset, modifier, special,
index b50eff465ffc0d62f426f7a97da52da03aeb672b..0d8c9b48c89bf9ab64c35985af6897271508fb25 100644 (file)
@@ -318,8 +318,8 @@ _nl_make_l10nflist (l10nfile_list, dirlist, dirlist_len, mask, language,
     }
 
   entries = 0;
-  /* If the DIRLIST is a real list the RETVAL entry correcponds not to
-     a real file.  So we have to use the DIRLIST separation machanism
+  /* If the DIRLIST is a real list the RETVAL entry corresponds not to
+     a real file.  So we have to use the DIRLIST separation mechanism
      of the inner loop.  */
   cnt = __argz_count (dirlist, dirlist_len) == 1 ? mask - 1 : mask;
   for (; cnt >= 0; --cnt)
index 6e2b27d51b26a6e7dd9e02c9053ffe0580b12edf..e08cdf94a99e5141d4300e31bafc030311cf036c 100644 (file)
@@ -297,7 +297,7 @@ read_alias_file (fname, fname_len)
            }
        }
 
-      /* Possibily not the whole line fitted into the buffer.  Ignore
+      /* Possibly not the whole line fits into the buffer.  Ignore
         the rest of the line.  */
       while (strchr (cp, '\n') == NULL)
        {
index 63341555ad4ad92015003d4a387b6a4842fd82ce..df558daa5819be9d299272b175e1b4a06f48faa2 100644 (file)
@@ -10,7 +10,7 @@
    License, the Free Software Foundation gives you unlimited
    permission to link the compiled version of this file with other
    programs, and to distribute those programs without any restriction
-   coming from the use of this file.  (The Libraty General Public
+   coming from the use of this file.  (The Library General Public
    License restrictions do apply in other respects; for example, they
    cover modification of the file, and distribution when not linked
    into another program.)
index 84be8f7bfd17b985efeb5fe02dd426ad1978288a..9510eac23777364b47cabdce7e93c34c8f533183 100644 (file)
@@ -10,7 +10,7 @@
    License, the Free Software Foundation gives you unlimited
    permission to link the compiled version of this file with other
    programs, and to distribute those programs without any restriction
-   coming from the use of this file.  (The Libraty General Public
+   coming from the use of this file.  (The Library General Public
    License restrictions do apply in other respects; for example, they
    cover modification of the file, and distribution when not linked
    into another program.)
index b5d51a203cf6798cb8589b157f8431c189cf829f..8d1dde254658fc307afc9531b28a94b0352f73eb 100644 (file)
@@ -10,7 +10,7 @@
    License, the Free Software Foundation gives you unlimited
    permission to link the compiled version of this file with other
    programs, and to distribute those programs without any restriction
-   coming from the use of this file.  (The Libraty General Public
+   coming from the use of this file.  (The Library General Public
    License restrictions do apply in other respects; for example, they
    cover modification of the file, and distribution when not linked
    into another program.)
index faadce862cfef06c082639cb70b4c718016d992a..c4d1f53257745f8dd8160d8c7afac8074191fee7 100644 (file)
--- a/io/stat.c
+++ b/io/stat.c
@@ -10,7 +10,7 @@
    License, the Free Software Foundation gives you unlimited
    permission to link the compiled version of this file with other
    programs, and to distribute those programs without any restriction
-   coming from the use of this file.  (The Libraty General Public
+   coming from the use of this file.  (The Library General Public
    License restrictions do apply in other respects; for example, they
    cover modification of the file, and distribution when not linked
    into another program.)
index 5bc497c671c27d9459fa0d15564871221c625a98..f51c56aabd60f9f80128e7e7fb64e1997a29156c 100644 (file)
@@ -214,8 +214,10 @@ extern __inline__ int stat (__const char *__path, struct stat *__statbuf)
 
 extern __inline__ int __lstat(__const char *__path, struct stat *__statbuf)
 { return __lxstat (_STAT_VER, __path, __statbuf); }
+#if defined(__USE_BSD) || defined(__USE_XOPEN_EXTENDED)
 extern __inline__ int lstat(__const char *__path, struct stat *__statbuf)
 { return __lxstat (_STAT_VER, __path, __statbuf); }
+#endif
 
 extern __inline__ int __fstat (int __fd, struct stat *__statbuf)
 { return __fxstat (_STAT_VER, __fd, __statbuf); }
index 9f2f569b119427f47867aa9a33cfbf2a75a03768..7ab772b0420c44b0f9d8fe383062c2ea3324421a 100644 (file)
@@ -27,9 +27,6 @@
 
 __BEGIN_DECLS
 
-#define        __need_NULL
-#include <stddef.h>
-
 #include <gnu/types.h>
 
 /* Structure describing file times.  */
@@ -46,4 +43,4 @@ extern int utime __P ((__const char *__file,
 
 __END_DECLS
 
-#endif /* utime.h      */
+#endif /* utime.h */
index dd1f57340053a2664fff175eebdb402e0cc859af..12b2ead1256dbd021e8753fe95ba9aee69229eb8 100644 (file)
@@ -46,7 +46,7 @@ extern int errno;
    Putback mode is a variant of get mode.
 
    In a filebuf, there is only one current position, instead of two
-   separate get and put pointers.  In get mode, the current posistion
+   separate get and put pointers.  In get mode, the current position
    is that of gptr(); in put mode that of pptr().
 
    The position in the buffer that corresponds to the position
index 7679445c2bd3a720d7ded9f9179dc6284b25e249..3267aa32c9c5018c576d478050e2d3079dd8430b 100644 (file)
@@ -635,7 +635,7 @@ DEFUN_VOID(_IO_cleanup)
 
   /* We currently don't have a reliable mechanism for making sure that
      C++ static destructors are executed in the correct order.
-     So it is possible that other static destructord might want to
+     So it is possible that other static destructors might want to
      write to cout - and they're supposed to be able to do so.
 
      The following will make the standard streambufs be unbuffered,
@@ -691,7 +691,7 @@ DEFUN(_IO_marker_difference, (mark1, mark2),
   return mark1->_pos - mark2->_pos;
 }
 
-/* Return difference between MARK and current posistion of MARK's stream. */
+/* Return difference between MARK and current position of MARK's stream. */
 int
 DEFUN(_IO_marker_delta, (mark),
       struct _IO_marker *mark)
index cae5df7b391db67088c3621186ee59f74d3ae6c1..53a359ee7602464fb825c88a8aebd27c02ce3607 100644 (file)
@@ -24,7 +24,7 @@ the executable file might be covered by the GNU General Public License. */
 
 #include "libioP.h"
 #include <errno.h>
-/* ANSI explicily requires setting errno to a positive value on failure. */
+/* ANSI explicitly requires setting errno to a positive value on failure. */
 
 int
 _IO_fgetpos (fp, posp)
index ec913e3e2fa9ae13ac082f7229e5d3e62c492edf..2d29fa7cbb48bf2133363154bbe4070e3de95668 100644 (file)
@@ -36,7 +36,8 @@ _IO_fsetpos (fp, posp)
   _IO_flockfile (fp);
   if (_IO_seekpos (fp, *posp, _IOS_INPUT|_IOS_OUTPUT) == _IO_pos_BAD)
     {
-      /*ANSI explicily requires setting errno to a positive value on failure.*/
+      /* ANSI explicitly requires setting errno to a positive value on
+        failure.  */
 #ifdef EIO
       if (errno == 0)
        __set_errno (EIO);
index fc01d82ee04e15b8ebcb479d69ef027e126e85e7..11904e36b3cfbb0e95921671884a6bc914670bd1 100644 (file)
@@ -40,13 +40,14 @@ _IO_vsprintf (string, format, args)
 #ifdef _IO_MTSAFE_IO
   sf._sbf._f._lock = &lock;
 #endif
-  _IO_init ((_IO_FILE *) &sf, 0);
-  _IO_JUMPS ((_IO_FILE *) &sf) = &_IO_str_jumps;
+  _IO_init (&sf._sbf._f, 0);
+  _IO_JUMPS (&sf._sbf._f) = &_IO_str_jumps;
+  _IO_str_init_static (&sf._sbf._f, string, -1, string);
   _IO_str_init_static ((_IO_FILE *) &sf, string, -1, string);
   _IO_cleanup_region_start ((void (*) __P ((void *))) _IO_funlockfile, &sf);
-  _IO_flockfile ((_IO_FILE *) &sf);
-  ret = _IO_vfprintf ((_IO_FILE *) &sf, format, args);
-  _IO_putc_unlocked ('\0', (_IO_FILE *) &sf);
+  _IO_flockfile (&sf._sbf._f);
+  ret = _IO_vfprintf (&sf._sbf._f, format, args);
+  _IO_putc_unlocked ('\0', &sf._sbf._f);
   _IO_cleanup_region_end (1);
   return ret;
 }
index 4a21cce4b0ff0ae961e76c8e13497b91bfd80015..c0c2ef0bf12119daf07cce28f90fe52dd991a174 100644 (file)
@@ -35,12 +35,12 @@ DEFUN(_IO_vsscanf, (string, format, args),
   _IO_lock_t lock;
   sf._sbf._f._lock = &lock;
 #endif
-  _IO_init((_IO_FILE*)&sf, 0);
-  _IO_JUMPS((_IO_FILE*)&sf) = &_IO_str_jumps;
-  _IO_str_init_static ((_IO_FILE*)&sf, (char*)string, 0, NULL);
+  _IO_init(&sf._sbf._f, 0);
+  _IO_JUMPS(&sf._sbf._f) = &_IO_str_jumps;
+  _IO_str_init_static (&sf._sbf._f, (char*)string, 0, NULL);
   _IO_cleanup_region_start ((void (*) __P ((void *))) _IO_funlockfile, &sf);
-  _IO_flockfile ((_IO_FILE *) &sf);
-  ret = _IO_vfscanf((_IO_FILE*)&sf, format, args, NULL);
+  _IO_flockfile (&sf._sbf._f);
+  ret = _IO_vfscanf(&sf._sbf._f, format, args, NULL);
   _IO_cleanup_region_end (1);
   return ret;
 }
index 4fa3fd911c7a5a6ce688b54e5b95c7343b7d81f5..c80bdf30c666d08896f8548571ac9bef2cc8feef 100644 (file)
@@ -66,11 +66,11 @@ extern "C" {
  * a jump table (of pointers to functions).  The pointer is accessed
  * with the _IO_JUMPS macro.  The jump table has a eccentric format,
  * so as to be compatible with the layout of a C++ virtual function table.
- * (as implemented by g++).  When a pointer to a steambuf object is
+ * (as implemented by g++).  When a pointer to a streambuf object is
  * coerced to an (_IO_FILE*), then _IO_JUMPS on the result just
  * happens to point to the virtual function table of the streambuf.
  * Thus the _IO_JUMPS function table used for C stdio/libio does
- * double duty as the virtual functiuon table for C++ streambuf.
+ * double duty as the virtual function table for C++ streambuf.
  *
  * The entries in the _IO_JUMPS function table (and hence also the
  * virtual functions of a streambuf) are described below.
@@ -112,7 +112,7 @@ typedef int (*_IO_overflow_t) __P((_IO_FILE*, int));
 
 /* The 'underflow' hook tries to fills the get buffer.
    It returns the next character (as an unsigned char) or EOF.  The next
-   character remains in the get buffer, and the get postion is not changed.
+   character remains in the get buffer, and the get position is not changed.
    It matches the streambuf::underflow virtual function. */
 typedef int (*_IO_underflow_t) __P((_IO_FILE*));
 #define _IO_UNDERFLOW(FP) JUMP0(__underflow, FP)
@@ -178,7 +178,7 @@ typedef int (*_IO_doallocate_t) __P((_IO_FILE*));
 
 /* The following four hooks (sysread, syswrite, sysclose, sysseek, and
    sysstat) are low-level hooks specific to this implementation.
-   There is no correspondance in the ANSI/ISO C++ standard library.
+   There is no correspondence in the ANSI/ISO C++ standard library.
    The hooks basically correspond to the Unix system functions
    (read, write, close, lseek, and stat) except that a _IO_FILE*
    parameter is used instead of a integer file descriptor;  the default
@@ -190,21 +190,21 @@ typedef int (*_IO_doallocate_t) __P((_IO_FILE*));
 /* The 'sysread' hook is used to read data from the external file into
    an existing buffer.  It generalizes the Unix read(2) function.
    It matches the streambuf::sys_read virtual function, which is
-   specific to this implementaion. */
+   specific to this implementation. */
 typedef _IO_ssize_t (*_IO_read_t) __P((_IO_FILE*, void*, _IO_ssize_t));
 #define _IO_SYSREAD(FP, DATA, LEN) JUMP2(__read, FP, DATA, LEN)
 
 /* The 'syswrite' hook is used to write data from an existing buffer
    to an external file.  It generalizes the Unix write(2) function.
    It matches the streambuf::sys_write virtual function, which is
-   specific to this implementaion. */
+   specific to this implementation. */
 typedef _IO_ssize_t (*_IO_write_t) __P((_IO_FILE*,const void*,_IO_ssize_t));
 #define _IO_SYSWRITE(FP, DATA, LEN) JUMP2(__write, FP, DATA, LEN)
 
 /* The 'sysseek' hook is used to re-position an external file.
    It generalizes the Unix lseek(2) function.
    It matches the streambuf::sys_seek virtual function, which is
-   specific to this implementaion. */
+   specific to this implementation. */
 typedef _IO_fpos_t (*_IO_seek_t) __P((_IO_FILE*, _IO_off_t, int));
 #define _IO_SYSSEEK(FP, OFFSET, MODE) JUMP2(__seek, FP, OFFSET, MODE)
 
@@ -218,7 +218,7 @@ typedef int (*_IO_close_t) __P((_IO_FILE*)); /* finalize */
 /* The 'sysstat' hook is used to get information about an external file
    into a struct stat buffer.  It generalizes the Unix fstat(2) call.
    It matches the streambuf::sys_stat virtual function, which is
-   specific to this implementaion. */
+   specific to this implementation. */
 typedef int (*_IO_stat_t) __P((_IO_FILE*, void*));
 #define _IO_SYSSTAT(FP, BUF) JUMP1(__stat, FP, BUF)
 
index 281141eba78a38ac5562d5b7d41ae6465c20e60d..31c5df4e80dbc7558903eb1523961612fd363ef3 100644 (file)
@@ -28,7 +28,7 @@ the executable file might be covered by the GNU General Public License. */
 
 #if 0
 /* The following definitions are for exposition only.
-   They map the terminlogy used in the ANSI/ISO C++ draft standard
+   They map the terminology used in the ANSI/ISO C++ draft standard
    to the implementation. */
 
 /* allocated:  set  when a dynamic array object has been allocated, and
index 0d7be6b7e07fa885b064a381239b97c738c5f32f..5388237045898d1bb4dfba4f3d0feabf44266c42 100644 (file)
@@ -1,27 +1,27 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <endian.h>
 #include "localeinfo.h"
 
 /* These tables' entries contain values which make the function behave
-   accoriding to POSIX.2 Table 2-8 ``LC_COLLATE Category Definition in
+   according to POSIX.2 Table 2-8 ``LC_COLLATE Category Definition in
    the POSIX Locale''.  */
 
 const u_int32_t _nl_C_LC_COLLATE_symbol_hash[446] =
index 0b9f1a0bd24d73074ac224a5bd0d03ba920cfbd7..d45c32c34b9d94b6c70ff8f5445c4f0e0dd28dfd 100644 (file)
@@ -1,27 +1,27 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include "localeinfo.h"
 #include <endian.h>
 
 /* This table's entries are taken from POSIX.2 Table 2-6
-   ``LC_CTYPE Category Definitionin the POSIX Locale''.
+   ``LC_CTYPE Category Definition in the POSIX Locale''.
 
    The `_nl_C_LC_CTYPE_width' array is a GNU extension.
 
index 095ccdf311ecbc3b4ab997ac403b55c401d5687b..46880a234847fbfc4c9aae9b1ecdcf239e31f32e 100644 (file)
@@ -6,7 +6,7 @@
  *
  * !!! The list has to be sorted !!!
  */
-DEFINE_INT_CURR("AED ")                /* United Arab Emirats  */
+DEFINE_INT_CURR("AED ")                /* United Arab Emirates  */
 DEFINE_INT_CURR("AFA ")                /* Afghanistan  */
 DEFINE_INT_CURR("ALL ")                /* Albania  */
 DEFINE_INT_CURR("ANG ")                /* Netherlands Antilles  */
@@ -91,7 +91,7 @@ DEFINE_INT_CURR("LKR ")               /* Sri Lanka  */
 DEFINE_INT_CURR("LRD ")                /* Liberia  */
 DEFINE_INT_CURR("LSM ")                /* Lesotho  */
 DEFINE_INT_CURR("LTL ")                /* Lithuania  */
-DEFINE_INT_CURR("LUF ")                /* Luxemburg  */
+DEFINE_INT_CURR("LUF ")                /* Luxembourg  */
 DEFINE_INT_CURR("LVL ")                /* Latvia  */
 DEFINE_INT_CURR("LYD ")                /* Libyan Arab Jamahiriya  */
 DEFINE_INT_CURR("MAD ")                /* Morocco  */
index 39b04d7270236e91317ceff557ea8bb77065c75a..37f5434de1778d996debe837bc2bbaa0b88a7989 100644 (file)
@@ -1,23 +1,23 @@
 /* Copyright (C) 1991, 1992, 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /*
- *     ANSI Standard: 4.4 LOCALIZATION <locale.h>
+ *     ISO C Standard: 4.4 LOCALIZATION        <locale.h>
  */
 
 #ifndef        _LOCALE_H
@@ -25,6 +25,9 @@ Cambridge, MA 02139, USA.  */
 #define        _LOCALE_H       1
 #include <features.h>
 
+#define __need_NULL
+#include <stddef.h>
+
 __BEGIN_DECLS
 
 /* These are the possibilities for the first argument to setlocale.
@@ -76,9 +79,9 @@ struct lconv
   /* Positive and negative sign positions:
      0 Parentheses surround the quantity and currency_symbol.
      1 The sign string precedes the quantity and currency_symbol.
-     2 The sign string succedes the quantity and currency_symbol.
+     2 The sign string follows the quantity and currency_symbol.
      3 The sign string immediately precedes the currency_symbol.
-     4 The sign string immediately succedes the currency_symbol.  */
+     4 The sign string immediately follows the currency_symbol.  */
   char p_sign_posn;
   char n_sign_posn;
 };
@@ -90,6 +93,37 @@ extern char *setlocale __P ((int __category, __const char *__locale));
 /* Return the numeric/monetary information for the current locale.  */
 extern struct lconv *localeconv __P ((void));
 
+#ifdef __USE_GNU
+/* The concept of one static locale per category is not very well
+   thought out.  Many applications will need to process its data using
+   information from several different locales.  Another application is
+   the implementation of the internationalization handling in the
+   upcoming ISO C++ standard library.  To support this another set of
+   the functions using locale data exist which have an additional
+   argument.
+
+   Attention: all these functions are *not* standardized in any form.
+   This is a proof-of-concept implementation.  */
+
+/* Structure for reentrant locale using functions.  This is an opaque
+   type for the user level programs.  */
+typedef struct locale_data *locale_t[LC_ALL];
+
+/* Return a reference to a data structure representing a set of locale
+   datasets.  Unlike for the CATEGORY parameter for `setlocale' the
+   CATEGORY_MASK parameter here uses a single bit for each category.
+   I.e., 1 << LC_CTYPE means to load data for this category.  If
+   BASE is non-null the appropriate category information in the BASE
+   record is replaced.  */
+extern __const locale_t *__newlocale __P ((int __category_mask,
+                                          __const char *__locale,
+                                          __const locale_t *__base));
+
+/* Free the data associated with a locale dataset previously returned
+   by a call to `setlocale_r'.  */
+extern void __freelocale __P ((__const locale_t *__dataset));
+#endif
+
 __END_DECLS
 
 #endif /* locale.h  */
index 620e4d54da344ef473f8e68289d56cae6d95e7b0..eccce9102f05388af74902ef19fac60f21af2556 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifndef _CHARSET_H
 #define _CHARSET_H
@@ -59,7 +59,7 @@ struct charset_t
 /* Prototypes for charmap handling functions.  */
 struct charset_t *charmap_read (const char *filename);
 
-/* Prototypes for funciton to insert new character.  */
+/* Prototypes for function to insert new character.  */
 void charset_new_char (struct linereader *lr, struct charset_t *cs, int bytes,
                       unsigned int value, const char *from, const char *to);
 
index c8741e83cb82964498d62713b7507a17a5eaad1c..19f26c8688d8a9558c441ab39c5dcd35011765de 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifdef HAVE_CONFIG_H
 # include <config.h>
@@ -119,7 +119,7 @@ struct locale_collate_t
   /* What kind of symbol is current element.  */
   enum coll_symbol kind;
 
-  /* While collecting the weigths we need some temporary space.  */
+  /* While collecting the weights we need some temporary space.  */
   unsigned int current_order;
   int *weight_cnt;
   unsigned int weight_idx;
@@ -379,8 +379,8 @@ Computing table size for collation information might take a while..."),
     = collate->nrules * sizeof (u_int32_t);
   /* Another trick here.  Describing the collation method needs only a
      few bits (3, to be exact).  But the binary file should be
-     accessible by maschines with both endianesses and so we store both
-     information in the same word.  */
+     accessible by machines with both endianesses and so we store both
+     forms in the same word.  */
   for (cnt = 0; cnt < collate->nrules; ++cnt)
     table[cnt] = collate->rules[cnt] | SWAPU32 (collate->rules[cnt]);
 
@@ -646,7 +646,7 @@ Computing table size for collation information might take a while..."),
      where N is the number of keys.
 
      If we now choose M to be the next prime bigger than 4 / 3 * N,
-     we get the values 4 and 1.85 resp.  Because unsuccesful searches
+     we get the values 4 and 1.85 resp.  Because unsuccessful searches
      are unlikely this is a good value.  Formulas: [Knuth, The Art of
      Computer Programming, Volume 3, Sorting and Searching, 1973,
      Addison Wesley]  */
@@ -880,7 +880,7 @@ Computing table size for collation information might take a while..."),
     symbols_class_ob[cnt] = SWAPU32 (symbols_class[cnt]);
 
 
-  /* Store table adresses and lengths.   */
+  /* Store table addresses and lengths.   */
 #if __BYTE_ORDER == __BIG_ENDIAN
   iov[2 + _NL_ITEM_INDEX (_NL_COLLATE_TABLE_EB)].iov_base = table;
   iov[2 + _NL_ITEM_INDEX (_NL_COLLATE_TABLE_EB)].iov_len
@@ -1659,7 +1659,7 @@ collate_simple_weight (struct linereader *lr, struct localedef_t *locale,
 
     case tok_string:
       /* This can become difficult.  We have to get the weights which
-        correspind the the single wide chars in the string.  But some
+        correspond to the single wide chars in the string.  But some
         of the `chars' might not be real characters, but collation
         elements or symbols.  And so the string decoder might have
         signaled errors.  The string at this point is not translated.
index bc3e391ace73fa1a0c5af4658920aedc9396fa04..fb352e53edc519abfa3bed9830b2f498f1394fd0 100644 (file)
@@ -1119,7 +1119,7 @@ character `%s' not defined while needed as default value"),
     }
 
   if (ctype->toupper_done == 0)
-    /* "If this keyword [toupper] is not spcified, the lowercase letters
+    /* "If this keyword [toupper] is not specified, the lowercase letters
         `a' through `z', and their corresponding uppercase letters `A' to
        `Z', ..., shall automatically be included, with implementation-
        defined character values."  [P1003.2, 2.5.2.1]  */
@@ -1181,16 +1181,17 @@ allocate_arrays (struct locale_ctype_t *ctype, struct charset_t *charset)
 {
   size_t idx;
 
-  /* First we have to decide how we organize the arrays.  It is easy for
-     a one-byte character set.  But multi-byte character set cannot be
-     stored flat because they might be sparsly used.  So we determine an
-     optimal hashing function for the used characters.
-
-     We use a very trivial hashing function to store the sparse table.
-     CH % TABSIZE is used as an index.  To solve multiple hits we have
-     N planes.  This gurantees a fixed search time for a character [N
-     / 2].  In the following code we determine the minmum value for
-     TABSIZE * N, where TABSIZE >= 256.  */
+  /* First we have to decide how we organize the arrays.  It is easy
+     for a one-byte character set.  But multi-byte character set
+     cannot be stored flat because the chars might be sparsely used.
+     So we determine an optimal hashing function for the used
+     characters.
+
+     We use a very trivial hashing function to store the sparse
+     table.  CH % TABSIZE is used as an index.  To solve multiple hits
+     we have N planes.  This guarantees a fixed search time for a
+     character [N / 2].  In the following code we determine the minmum
+     value for TABSIZE * N, where TABSIZE >= 256.  */
   size_t min_total = UINT_MAX;
   size_t act_size = 256;
 
index 6be7309ae986084c7621c216344b7a84e5dc92ba..abd21dbc59241a760a7e69af960204caf3bf89f3 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifdef HAVE_CONFIG_H
 # include <config.h>
@@ -260,7 +260,7 @@ time_finish (struct localedef_t *locale)
                }
            }
 
-         /* Next is the stoping date in ISO format.  */
+         /* Next is the stopping date in ISO format.  */
          if (strncmp (str, "-*", 2) == 0)
            {
              time->era_entries[idx].stop_date[0] =
index fa824fb96c0820b92d6c7e3f1baa241a4fcf81c7..9a2c6c4aa1ad5fb90d17ff9115258444d2c82cbf 100644 (file)
@@ -1,22 +1,22 @@
 /* locale - Implementation of the locale program according to POSIX 1003.2
-Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifdef HAVE_CONFIG_H
 # include <config.h>
@@ -145,7 +145,7 @@ main (int argc, char *argv[])
   show_keyword_name = 0;
 
   /* Set locale.  Do not set LC_ALL because the other categories must
-     not be affected (acccording to POSIX.2).  */
+     not be affected (according to POSIX.2).  */
   setlocale (LC_CTYPE, "");
   setlocale (LC_MESSAGES, "");
 
@@ -446,7 +446,7 @@ show_info (const char *name)
          }
     }
 
-  /* When we get to here the name is not standard ones.  For testing
-     and perhpas advanced use we allow some more symbols.  */
+  /* The name is not a standard one.
+     For testing and perhaps advanced use allow some more symbols.  */
   locale_special (name, show_category_name, show_keyword_name);
 }
index 997126b625ebb294f6e57f8b2edaa448286e83e6..e9b934c533456602a62e719b26a10ad559d3cfa1 100644 (file)
@@ -112,14 +112,14 @@ main (int argc, char *argv[])
   struct localedef_t *localedef;
   struct copy_def_list_t *act_add_locdef;
 
-  /* Set initial values for global varaibles.  */
+  /* Set initial values for global variables.  */
   copy_list = NULL;
   posix_conformance = getenv ("POSIXLY_CORRECT") != NULL;
   error_print_progname = error_print;
   verbose = 0;
 
   /* Set locale.  Do not set LC_ALL because the other categories must
-     not be affected (acccording to POSIX.2).  */
+     not be affected (according to POSIX.2).  */
   setlocale (LC_MESSAGES, "");
   setlocale (LC_CTYPE, "");
 
@@ -187,7 +187,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\
   /* Help is requested.  */
   if (do_help)
     /* Possible violation: POSIX.2 4.35.8 defines the return value 0 as
-       "No errors occured and the locale(s) were successfully created."
+       "No errors occurred and the locale(s) were successfully created."
        But giving a other value than 0 does not make sense here.  It
        is perhaps not that important because POSIX does not specify the
        -h option for localedef.  */
@@ -424,7 +424,7 @@ error_print ()
 
 
 /* The parameter to localedef describes the output path.  If it does
-   contain a '/' character it is a relativ path.  Otherwise it names the
+   contain a '/' character it is a relative path.  Otherwise it names the
    locale this definition is for.  */
 static const char *
 construct_output_path (char *path)
index 97629e5132c39afcef04105f6c31404a50fbb3c9..4717fe22bd359e46a8f0978991e5fe06306ad700 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifdef HAVE_CONFIG_H
 # include <config.h>
@@ -628,7 +628,7 @@ syntax error in `order_start' directive"));
            }
 
          /* If no argument to `order_start' is given, one `forward'
-            argument is implicitely assumed.  */
+            argument is implicitly assumed.  */
          if (cnt == 0)
            collate_new_order (ldfile, result, sort_forward);
 
index a0fe06b674e314d7fb5b819ee960370c7f5adf91..003082ca61b775d1e55eb6a05eecaf7e0968ce62 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifndef _LOCFILE_H
 #define _LOCFILE_H
@@ -24,7 +24,7 @@ Boston, MA 02111-1307, USA.  */
 
 #include "charset.h"
 
-/* Opaque types for the different loales.  */
+/* Opaque types for the different locales.  */
 struct locale_ctype_t;
 struct locale_collate_t;
 struct locale_monetary_t;
index c7a9f96c241c5a0d51f15b9655ddd755927ba9bc..1b7b6eae811883cf92e91960e58bde7a7a8562ab 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Written by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   This file is part of the GNU C Library.
+   Written by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <alloca.h>
 #include <langinfo.h>
@@ -41,8 +41,8 @@ typedef struct weight_t
 } weight_t;
 
 
-/* The following five macros grant access to the non-byte order
-   dependend values in the collate locale file.  */
+/* The following five macros grant access to the values in the
+   collate locale file that do not depend on byte order.  */
 #define collate_nrules \
   (_NL_CURRENT_WORD (LC_COLLATE, _NL_COLLATE_NRULES))
 #define collate_hash_size \
index 0d5e48e51f058fe106705c3b240f0b6226798bc6..876388323fb6fd81d10ea315acbc23d8b7ba2148 100644 (file)
@@ -67,7 +67,7 @@ logwtmp (const char *line, const char *name, const char *host)
       __flock (fd, LOCK_EX | LOCK_NB);
     }
 
-  /* Remeber original size of log file: */
+  /* Remember original size of log file: */
   if (__fstat (fd, &st) < 0)
     goto done;
 
index da78742cf7170e4df11937264da55c13be236566..09024a787a95f43d672799f9ee64d56b6b66e57f 100644 (file)
@@ -1,21 +1,21 @@
-/* pty.h - Functions for pseudo TTY handlung.
-Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+/* pty.h - Functions for pseudo TTY handling.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifndef _PTY_H
 
index f7f0c09420001ee5e8432a80e1b20f0a595bb7d9..986c2dad5129104c0c4857f4aa676cfdb8426d31 100644 (file)
@@ -130,7 +130,7 @@ $(objpfx)mach-shortcuts.h: $(objpfx)mach/mach_interface.h \
                           $(objpfx)mach/mach_port.h
 # The first line gets us one paragraph per line, with @s separating real lines.
 # The second line selects paragraphs for the shortcutted functions.
-# The third line removes `_rpc' from the names and rerealifies the lines.
+# The third line removes `_rpc' from the names and reconstitutes the lines.
        cat $^ | tr \\012 @ | sed s/@@/@%/g | tr % \\012 \
        | grep '^/\* Routine [a-z0-9_]*_rpc \*/' \
        | sed 's/_rpc//g' | tr @ \\012 > $@-new
index d5290b4e9bda0554d785b0464eb7ac13919acf7f..e2e498d2b728d539f5a95274ce611dff9f485323 100644 (file)
@@ -1,48 +1,54 @@
-/* 
+/*
  * Mach Operating System
  * Copyright (c) 1991,1990,1989 Carnegie Mellon University
  * All Rights Reserved.
- * 
+ *
  * Permission to use, copy, modify and distribute this software and its
  * documentation is hereby granted, provided that both the copyright
  * notice and this permission notice appear in all copies of the
  * software, derivative works or modified versions, and any portions
  * thereof, and that both notices appear in supporting documentation.
- * 
- * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS 
+ *
+ * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS
  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
- * 
+ *
  * Carnegie Mellon requests users of this software to return to
- * 
+ *
  *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
  *  School of Computer Science
  *  Carnegie Mellon University
  *  Pittsburgh PA 15213-3890
- * 
+ *
  * any improvements or extensions that they make and grant Carnegie the
  * rights to redistribute these changes.
  */
 /*
  * HISTORY
  * $Log$
+ * Revision 1.5  1996/12/20 01:32:34  drepper
+ * Update from main archive 961219
+ *
+ * Revision 1.5  1996/12/19 20:23:39  drepper
+ * Spelling corrections.
+ *
  * Revision 1.4  1993/12/17 06:14:52  mib
  * entered into RCS
  *
  * Revision 2.3  92/04/01  19:38:02  rpd
  *     Added err_codes_device.
  *     [92/03/09            rpd]
- * 
+ *
  * Revision 2.2  92/01/16  00:08:50  rpd
  *     Moved from user collection to mk collection.
- * 
+ *
  * Revision 2.3  91/08/29  15:51:22  rpd
  *     Updated err_codes_kern.
  *     [91/08/15            rpd]
- * 
+ *
  * Revision 2.2  91/03/27  16:05:27  mrt
  *     First checkin
- * 
+ *
  */
 /*
  *     File:   err_kern.sub
@@ -130,12 +136,12 @@ static char * err_codes_unix[] = {
        "(os/unix) result is out of range",
        "(os/unix) operation on device would block",
        "(os/unix) operation is now in progress",
-       "(os/unix) operation is already in progress",   
+       "(os/unix) operation is already in progress",
        "(os/unix) socket operation attempted on non-socket object",
        "(os/unix) destination address is required",
        "(os/unix) message is too long",
        "(os/unix) protocol type is incorrect for socket",
-       "(os/unix) protocol type is not availaible",
+       "(os/unix) protocol type is not available",
        "(os/unix) protocol type is not supported",
        "(os/unix) socket type is not supported",
        "(os/unix) operation is not supported on sockets",
index e75ccf3f66b8398e8cb99dd801d4467213a27a67..83cf61ef8f74df51628be41a161b368cc191a51c 100644 (file)
@@ -3,71 +3,77 @@
  * Mach Operating System
  * Copyright (c) 1991,1990,1989,1988,1987 Carnegie Mellon University
  * All Rights Reserved.
- * 
+ *
  * Permission to use, copy, modify and distribute this software and its
  * documentation is hereby granted, provided that both the copyright
  * notice and this permission notice appear in all copies of the
  * software, derivative works or modified versions, and any portions
  * thereof, and that both notices appear in supporting documentation.
- * 
+ *
  * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
- * 
+ *
  * Carnegie Mellon requests users of this software to return to
- * 
+ *
  *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
  *  School of Computer Science
  *  Carnegie Mellon University
  *  Pittsburgh PA 15213-3890
- * 
+ *
  * any improvements or extensions that they make and grant Carnegie Mellon
  * the rights to redistribute these changes.
  */
 /*
  * HISTORY
  * $Log$
+ * Revision 1.2  1996/12/20 01:32:36  drepper
+ * Update from main archive 961219
+ *
+ * Revision 1.2  1996/12/19 20:23:56  drepper
+ * Spelling corrections.
+ *
  * Revision 1.1  1993/12/17 21:40:28  roland
  * entered into RCS
  *
  * Revision 2.6  93/01/14  17:41:31  danner
  *     Standardized include symbol name.
  *     [92/06/10            pds]
- * 
+ *
  * Revision 2.5  92/03/31  15:18:11  rpd
  *     Added err_bootstrap for bootstrap errors.
  *     [92/03/09            rpd]
- * 
+ *
  * Revision 2.4  91/05/14  16:51:24  mrt
  *     Correcting copyright
- * 
+ *
  * Revision 2.3  91/02/05  17:31:48  mrt
  *     Changed to new Mach copyright
  *     [91/02/01  17:16:50  mrt]
- * 
+ *
  * Revision 2.2  90/06/02  14:57:47  rpd
  *     Added err_mach_ipc for new IPC.
  *     [90/03/26  22:28:42  rpd]
- * 
+ *
  * Revision 2.1  89/08/03  16:02:07  rwd
  * Created.
- * 
+ *
  * Revision 2.4  89/02/25  18:13:18  gm0w
  *     Changes for cleanup.
- * 
+ *
  * Revision 2.3  89/02/07  00:51:57  mwyoung
  * Relocated from sys/error.h
- * 
+ *
  * Revision 2.2  88/10/18  00:37:31  mwyoung
- *     Added {system,sub and code}_emask 
+ *     Added {system,sub and code}_emask
  *     [88/10/17  17:06:58  mrt]
- * 
- *     Added {system,sub and code}_emask 
+ *
+ *     Added {system,sub and code}_emask
  *
  *  12-May-88 Mary Thompson (mrt) at Carnegie Mellon
  *     Changed mach_error_t from unsigned int to kern_return_t
  *     which is a 32 bit integer regardless of machine type.
- *      insigned int was incompatible with old usages of mach_error.
+ *      unsigned int was incompatible with old usages of mach_error.
  *
  *  10-May-88 Douglas Orr (dorr) at Carnegie-Mellon University
  *     Missing endif replaced
index e741e16996a4d417900eab3e95e2214ff08ac82d..17fee75fae7b102006b580076d9743e3ff8f9719 100644 (file)
@@ -1,20 +1,20 @@
-/* Copyright (C) 1994 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* Declare the few Mach system calls (except mach_msg, in <mach/message.h>).
    This does not include the kernel RPC shortcut calls (in <mach-shortcuts.h>).
@@ -52,12 +52,12 @@ extern boolean_t __swtch (void);
 
 /* Attempt to context switch the current thread off the processor.  Lower
    the thread's priority as much as possible.  The thread's priority will
-   be restored when it runs again.  PRIORITY is currently unused.  Return 
+   be restored when it runs again.  PRIORITY is currently unused.  Return
    true if there are other threads that can be run and false if not.  */
 extern boolean_t swtch_pri (int priority);
 extern boolean_t __swtch_pri (int priority);
 
-/* Attempt to context switch the current thread of the rpocessor.  Try
+/* Attempt to context switch the current thread of the processor.  Try
    to run NEW_THREAD next, ignoring normal scheduling policies.  The
    OPTION value comes from <mach/thread_switch.h>.  If OPTION is
    SWITCH_OPTION_WAIT, then block the current thread for TIME
@@ -67,7 +67,7 @@ extern boolean_t __swtch_pri (int priority);
 kern_return_t thread_switch (mach_port_t new_thread, int option, int time);
 kern_return_t __thread_switch (mach_port_t new_thread, int option, int time);
 
-/* Block the current thread until the kernel (or device) event 
+/* Block the current thread until the kernel (or device) event
    identified by EVENT occurs.  */
 kern_return_t evc_wait (unsigned int event);
 kern_return_t __evc_wait (unsigned int event);
index da64b89c9443d05e686f81ed09e3b48cbe204579..c11ea9a699a1400af6310d7c75aeaada58a747d7 100644 (file)
@@ -1,20 +1,20 @@
-/* Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* Based on CMU's mach_msg_server.c revision 2.4 of 91/05/14, and thus
    under the following copyright.  Rewritten by Roland McGrath (FSF)
@@ -49,6 +49,12 @@ Cambridge, MA 02139, USA.  */
 /*
  * HISTORY
  * $Log$
+ * Revision 1.5  1996/12/20 01:32:35  drepper
+ * Update from main archive 961219
+ *
+ * Revision 1.5  1996/12/19 20:23:45  drepper
+ * Spelling corrections.
+ *
  * Revision 1.4  1996/01/29 15:44:23  roland
  * Declare DEMUX arg with prototype.
  *
@@ -162,7 +168,7 @@ __mach_msg_server_timeout (boolean_t (*demux) (mach_msg_header_t *request,
        {
        case MACH_RCV_TOO_LARGE:
          /* The request message is larger than MAX_SIZE, and has not
-            been dequued.  The message header has the actual size of
+            been dequeued.  The message header has the actual size of
             the message.  We recurse here in hopes that the compiler
             will optimize the tail-call and allocate some more stack
             space instead of way too much.  */
@@ -171,7 +177,7 @@ __mach_msg_server_timeout (boolean_t (*demux) (mach_msg_header_t *request,
 
        case MACH_SEND_INVALID_DEST:
          /* The reply can't be delivered, so destroy it.  This error
-            indicates only that the requestor went away, so we
+            indicates only that the requester went away, so we
             continue and get the next request.  */
          __mach_msg_destroy (&request->Head);
          break;
index 63fe786168ea102adbde988b570b8249ee98fbd3..c98bea686ccf823344ad92dcf86a3f3f5dda9547 100644 (file)
@@ -27,15 +27,27 @@ dist-headers := malloc.h
 headers := $(dist-headers) obstack.h
 tests := mallocbug
 
-distribute = thread-m.h
+distribute = thread-m.h mtrace.awk
 
 # Things which get pasted together into gmalloc.c.
 gmalloc-routines := malloc morecore
 # Things to include in the standalone distribution.
-dist-routines = $(gmalloc-routines)
+dist-routines = $(gmalloc-routines) mcheck mtrace
 routines = $(dist-routines) obstack
 
+install-lib := libmcheck.a
+non-lib.a := libmcheck.a
+
+# These should be removed by `make clean'.
+extra-objs = mcheck-init.o libmcheck.a
+
 include ../Rules
 
+$(objpfx)libmcheck.a: $(objpfx)mcheck-init.o
+       -rm -f $@
+       ln $< $@
+
+lib: $(objpfx)libmcheck.a
+
+
 CPPFLAGS-malloc.o += -DMALLOC_DEBUG
-CFLAGS-obstack.c = -Wno-strict-prototypes
index c2a94a4f8def9fb63843158f2c0b91dd4c622d0c..840655f4dbb535fb7986e447a81185e42ba23198 100644 (file)
 
   Maximum overhead wastage per allocated chunk: normally 15 bytes
 
-       Alignnment demands, plus the minimum allocatable size restriction
+       Alignment demands, plus the minimum allocatable size restriction
        make the normal worst-case wastage 15 bytes (i.e., up to 15
        more bytes will be allocated than were requested in malloc), with
        two exceptions:
@@ -343,7 +343,7 @@ extern "C" {
     checking is fairly extensive, and will slow down execution
     noticeably. Calling malloc_stats or mallinfo with MALLOC_DEBUG set will
     attempt to check every non-mmapped allocated and free chunk in the
-    course of computing the summmaries. (By nature, mmapped regions
+    course of computing the summaries. (By nature, mmapped regions
     cannot be checked very much automatically.)
 
     Setting MALLOC_DEBUG may also be helpful if you are trying to modify
@@ -999,7 +999,7 @@ nextchunk-> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     the malloc code, but "mem" is the pointer that is returned to the
     user.  "Nextchunk" is the beginning of the next contiguous chunk.
 
-    Chunks always begin on even word boundries, so the mem portion
+    Chunks always begin on even word boundaries, so the mem portion
     (which is returned to the user) is also on an even word boundary, and
     thus double-word aligned.
 
@@ -1144,7 +1144,7 @@ typedef struct _arena {
 } arena;
 
 
-/* A heap is a single contiguous memory region holding (coalescable)
+/* A heap is a single contiguous memory region holding (coalesceable)
    malloc_chunks.  It is allocated with mmap() and always starts at an
    address aligned to HEAP_MAX_SIZE.  Not used unless compiling for
    multiple threads. */
@@ -1489,6 +1489,8 @@ static unsigned long max_mmapped_mem = 0;
 
 
 \f
+/* Already initialized?  */
+int __malloc_initialized;
 
 
 /* Initialization routine. */
@@ -1504,13 +1506,12 @@ void
 ptmalloc_init __MALLOC_P((void))
 #endif
 {
-  static int first = 1;
 #if defined(_LIBC) || defined(MALLOC_HOOKS)
   const char* s;
 #endif
 
-  if(!first) return;
-  first = 0;
+  if(__malloc_initialized) return;
+  __malloc_initialized = 1;
 #if defined(_LIBC)
   /* Initialize the pthreads interface. */
   if (__pthread_initialize != NULL)
@@ -3589,7 +3590,7 @@ dump_heap(heap) heap_info *heap;
 
   malloc_stats:
 
-    For all arenas seperately and in total, prints on stderr the
+    For all arenas separately and in total, prints on stderr the
     amount of space obtained from the system, and the current number
     of bytes allocated via malloc (or realloc, etc) but not yet
     freed. (Note that this is the number of bytes allocated, not the
@@ -3964,10 +3965,10 @@ History:
         Wolfram Gloger (Gloger@lrz.uni-muenchen.de).
       * Use last_remainder in more cases.
       * Pack bins using idea from  colin@nyx10.cs.du.edu
-      * Use ordered bins instead of best-fit threshhold
+      * Use ordered bins instead of best-fit threshold
       * Eliminate block-local decls to simplify tracing and debugging.
       * Support another case of realloc via move into top
-      * Fix error occuring when initial sbrk_base not word-aligned.
+      * Fix error occurring when initial sbrk_base not word-aligned.
       * Rely on page size for units instead of SBRK_UNIT to
         avoid surprises about sbrk alignment conventions.
       * Add mallinfo, mallopt. Thanks to Raymond Nijssen
index ad36ca7592c60fd9cb1e3b838016ba51fc744f45..ddbc69449138399856a7a5a28a3deb268e71f357 100644 (file)
@@ -73,6 +73,9 @@
 extern "C" {
 #endif
 
+/* Nonzero if the malloc is already initialized.  */
+extern int __malloc_initialized;
+
 /* Initialize global configuration.  Not needed with GNU libc. */
 #ifndef __GLIBC__
 extern void ptmalloc_init __MALLOC_P ((void));
diff --git a/malloc/mcheck-init.c b/malloc/mcheck-init.c
new file mode 100644 (file)
index 0000000..a1cb7c9
--- /dev/null
@@ -0,0 +1,30 @@
+/* Copyright (C) 1991, 1994, 1995 Free Software Foundation, Inc.
+This file is part of the GNU C Library.
+
+The GNU C Library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Library General Public License as
+published by the Free Software Foundation; either version 2 of the
+License, or (at your option) any later version.
+
+The GNU C Library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+Library General Public License for more details.
+
+You should have received a copy of the GNU Library General Public
+License along with the GNU C Library; see the file COPYING.LIB.  If
+not, write to the Free Software Foundation, Inc., 675 Mass Ave,
+Cambridge, MA 02139, USA.  */
+
+/* The object of this file should be installed as libmcheck.a,
+   so one can do -lmcheck to turn on mcheck.  */
+
+#include <malloc.h>
+
+static void
+turn_on_mcheck __P ((void))
+{
+  mcheck (NULL);
+}
+
+void (*__malloc_initialize_hook) __P ((void)) = turn_on_mcheck;
diff --git a/malloc/mcheck.c b/malloc/mcheck.c
new file mode 100644 (file)
index 0000000..7f1112e
--- /dev/null
@@ -0,0 +1,232 @@
+/* Standard debugging hooks for `malloc'.
+   Copyright (C) 1990,91,92,93,94,95,96 Free Software Foundation, Inc.
+   Written May 1989 by Mike Haertel.
+
+   This library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   This library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with this library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.
+
+   The author may be reached (Email) at the address mike@ai.mit.edu,
+   or (US mail) as Mike Haertel c/o Free Software Foundation.  */
+
+#ifndef        _MALLOC_INTERNAL
+#define        _MALLOC_INTERNAL
+#include <malloc.h>
+#include <mcheck.h>
+#include <stdio.h>
+#endif
+
+/* Old hook values.  */
+static void (*old_free_hook) __P ((__ptr_t ptr));
+static __ptr_t (*old_malloc_hook) __P ((__malloc_size_t size));
+static __ptr_t (*old_realloc_hook) __P ((__ptr_t ptr, __malloc_size_t size));
+
+/* Function to call when something awful happens.  */
+static void (*abortfunc) __P ((enum mcheck_status));
+
+/* Arbitrary magical numbers.  */
+#define MAGICWORD      0xfedabeeb
+#define MAGICFREE      0xd8675309
+#define MAGICBYTE      ((char) 0xd7)
+#define MALLOCFLOOD    ((char) 0x93)
+#define FREEFLOOD      ((char) 0x95)
+
+struct hdr
+  {
+    __malloc_size_t size;              /* Exact size requested by user.  */
+    unsigned long int magic;   /* Magic number to check header integrity.  */
+  };
+
+#if    defined(_LIBC) || defined(STDC_HEADERS) || defined(USG)
+#define flood memset
+#else
+static void flood __P ((__ptr_t, int, __malloc_size_t));
+static void
+flood (ptr, val, size)
+     __ptr_t ptr;
+     int val;
+     __malloc_size_t size;
+{
+  char *cp = ptr;
+  while (size--)
+    *cp++ = val;
+}
+#endif
+
+static enum mcheck_status checkhdr __P ((const struct hdr *));
+static enum mcheck_status
+checkhdr (hdr)
+     const struct hdr *hdr;
+{
+  enum mcheck_status status;
+  switch (hdr->magic)
+    {
+    default:
+      status = MCHECK_HEAD;
+      break;
+    case MAGICFREE:
+      status = MCHECK_FREE;
+      break;
+    case MAGICWORD:
+      if (((char *) &hdr[1])[hdr->size] != MAGICBYTE)
+       status = MCHECK_TAIL;
+      else
+       status = MCHECK_OK;
+      break;
+    }
+  if (status != MCHECK_OK)
+    (*abortfunc) (status);
+  return status;
+}
+
+static void freehook __P ((__ptr_t));
+static void
+freehook (ptr)
+     __ptr_t ptr;
+{
+  if (ptr)
+    {
+      struct hdr *hdr = ((struct hdr *) ptr) - 1;
+      checkhdr (hdr);
+      hdr->magic = MAGICFREE;
+      flood (ptr, FREEFLOOD, hdr->size);
+      ptr = (__ptr_t) hdr;
+    }
+  __free_hook = old_free_hook;
+  free (ptr);
+  __free_hook = freehook;
+}
+
+static __ptr_t mallochook __P ((__malloc_size_t));
+static __ptr_t
+mallochook (size)
+     __malloc_size_t size;
+{
+  struct hdr *hdr;
+
+  __malloc_hook = old_malloc_hook;
+  hdr = (struct hdr *) malloc (sizeof (struct hdr) + size + 1);
+  __malloc_hook = mallochook;
+  if (hdr == NULL)
+    return NULL;
+
+  hdr->size = size;
+  hdr->magic = MAGICWORD;
+  ((char *) &hdr[1])[size] = MAGICBYTE;
+  flood ((__ptr_t) (hdr + 1), MALLOCFLOOD, size);
+  return (__ptr_t) (hdr + 1);
+}
+
+static __ptr_t reallochook __P ((__ptr_t, __malloc_size_t));
+static __ptr_t
+reallochook (ptr, size)
+     __ptr_t ptr;
+     __malloc_size_t size;
+{
+  struct hdr *hdr;
+  __malloc_size_t osize;
+
+  if (ptr)
+    {
+      hdr = ((struct hdr *) ptr) - 1;
+      osize = hdr->size;
+
+      checkhdr (hdr);
+      if (size < osize)
+       flood ((char *) ptr + size, FREEFLOOD, osize - size);
+    }
+  else
+    {
+      osize = 0;
+      hdr = NULL;
+    }
+  __free_hook = old_free_hook;
+  __malloc_hook = old_malloc_hook;
+  __realloc_hook = old_realloc_hook;
+  hdr = (struct hdr *) realloc ((__ptr_t) hdr, sizeof (struct hdr) + size + 1);
+  __free_hook = freehook;
+  __malloc_hook = mallochook;
+  __realloc_hook = reallochook;
+  if (hdr == NULL)
+    return NULL;
+
+  hdr->size = size;
+  hdr->magic = MAGICWORD;
+  ((char *) &hdr[1])[size] = MAGICBYTE;
+  if (size > osize)
+    flood ((char *) (hdr + 1) + osize, MALLOCFLOOD, size - osize);
+  return (__ptr_t) (hdr + 1);
+}
+
+static void mabort __P ((enum mcheck_status status));
+static void
+mabort (status)
+     enum mcheck_status status;
+{
+  const char *msg;
+  switch (status)
+    {
+    case MCHECK_OK:
+      msg = _("memory is consistent, library is buggy");
+      break;
+    case MCHECK_HEAD:
+      msg = _("memory clobbered before allocated block");
+      break;
+    case MCHECK_TAIL:
+      msg = _("memory clobbered past end of allocated block");
+      break;
+    case MCHECK_FREE:
+      msg = _("block freed twice");
+      break;
+    default:
+      msg = _("bogus mcheck_status, library is buggy");
+      break;
+    }
+#ifdef _LIBC
+  __libc_fatal (msg);
+#else
+  fprintf (stderr, "mcheck: %s\n", msg);
+  fflush (stderr);
+  abort ();
+#endif
+}
+
+static int mcheck_used = 0;
+
+int
+mcheck (func)
+     void (*func) __P ((enum mcheck_status));
+{
+  abortfunc = (func != NULL) ? func : &mabort;
+
+  /* These hooks may not be safely inserted if malloc is already in use.  */
+  if (!__malloc_initialized && !mcheck_used)
+    {
+      old_free_hook = __free_hook;
+      __free_hook = freehook;
+      old_malloc_hook = __malloc_hook;
+      __malloc_hook = mallochook;
+      old_realloc_hook = __realloc_hook;
+      __realloc_hook = reallochook;
+      mcheck_used = 1;
+    }
+
+  return mcheck_used ? 0 : -1;
+}
+
+enum mcheck_status
+mprobe (__ptr_t ptr)
+{
+  return mcheck_used ? checkhdr (ptr) : MCHECK_DISABLED;
+}
diff --git a/malloc/mcheck.h b/malloc/mcheck.h
new file mode 100644 (file)
index 0000000..17ab0a9
--- /dev/null
@@ -0,0 +1,70 @@
+/* Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#ifndef _MCHECK_H
+#define _MCHECK_H      1
+
+#ifdef  __cplusplus
+extern "C" {
+#endif
+
+#if defined (__cplusplus) || (defined (__STDC__) && __STDC__)
+#undef  __P
+#define __P(args)       args
+#undef  __ptr_t
+#define __ptr_t         void *
+#else /* Not C++ or ANSI C.  */
+#undef  __P
+#define __P(args)       ()
+#undef  __ptr_t
+#define __ptr_t         char *
+#endif /* C++ or ANSI C.  */
+
+
+/* Return values for `mprobe': these are the kinds of inconsistencies that
+   `mcheck' enables detection of.  */
+enum mcheck_status
+  {
+    MCHECK_DISABLED = -1,       /* Consistency checking is not turned on.  */
+    MCHECK_OK,                  /* Block is fine.  */
+    MCHECK_FREE,                /* Block freed twice.  */
+    MCHECK_HEAD,                /* Memory before the block was clobbered.  */
+    MCHECK_TAIL                 /* Memory after the block was clobbered.  */
+  };
+
+
+/* Activate a standard collection of debugging hooks.  This must be called
+   before `malloc' is ever called.  ABORTFUNC is called with an error code
+   (see enum above) when an inconsistency is detected.  If ABORTFUNC is
+   null, the standard function prints on stderr and then calls `abort'.  */
+extern int mcheck __P ((void (*__abortfunc) __P ((enum mcheck_status))));
+
+/* Check for aberrations in a particular malloc'd block.  You must have
+   called `mcheck' already.  These are the same checks that `mcheck' does
+   when you free or reallocate a block.  */
+extern enum mcheck_status mprobe __P ((__ptr_t __ptr));
+
+/* Activate a standard collection of tracing hooks.  */
+extern void mtrace __P ((void));
+extern void muntrace __P ((void));
+
+#ifdef  __cplusplus
+}
+#endif
+
+#endif /* mcheck.h */
diff --git a/malloc/mtrace.awk b/malloc/mtrace.awk
new file mode 100644 (file)
index 0000000..06844d1
--- /dev/null
@@ -0,0 +1,50 @@
+#
+#  Awk program to analyze mtrace.c output.
+#
+{
+  if ($1 == "@") {
+    where = " (" $2 ")"
+    n = 3
+  } else {
+    where = ""
+    n = 1
+  }
+  if ($n == "+") {
+    if (allocated[$(n+1)] != "")
+      print "+", $(n+1), "Alloc", NR, "duplicate:", allocated[$(n+1)], wherewas[$(n+1)], where;
+    else {
+      wherewas[$(n+1)] = where;
+      allocated[$(n+1)] = $(n+2);
+    }
+  } else if ($n == "-") {
+    if (allocated[$(n+1)] != "") {
+      wherewas[$(n+1)] = "";
+      allocated[$(n+1)] = "";
+      if (allocated[$(n+1)] != "")
+       print "DELETE FAILED", $(n+1), allocated[$(n+1)];
+    } else
+      print "-", $(n+1), "Free", NR, "was never alloc'd", where;
+  } else if ($n == "<")        {
+    if (allocated[$(n+1)] != "") {
+      wherewas[$(n+1)] = "";
+      allocated[$(n+1)] = "";
+    } else
+      print "-", $(n+1), "Realloc", NR, "was never alloc'd", where;
+  } else if ($n == ">") {
+    if (allocated[$(n+1)] != "")
+      print "+", $(n+1), "Realloc", NR, "duplicate:", allocated[$(n+1)], where;
+    else {
+      wherewas[$(n+1)] = $(n+2);
+      allocated[$(n+1)] = $(n+2);
+    }
+  } else if ($n == "=") {
+    # Ignore "= Start"
+  } else if ($n == "!") {
+    # Ignore failed realloc attempts for now
+  }
+}
+END {
+  for (x in allocated) 
+    if (allocated[x] != "")
+      print "+", x, allocated[x], wherewas[x];
+}
diff --git a/malloc/mtrace.c b/malloc/mtrace.c
new file mode 100644 (file)
index 0000000..35380a0
--- /dev/null
@@ -0,0 +1,211 @@
+/* More debugging hooks for `malloc'.
+   Copyright (C) 1991, 1992, 1993, 1994, 1996 Free Software Foundation, Inc.
+                Written April 2, 1991 by John Gilmore of Cygnus Support.
+                Based on mcheck.c by Mike Haertel.
+
+   This library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   This library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with this library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.
+
+   The author may be reached (Email) at the address mike@ai.mit.edu,
+   or (US mail) as Mike Haertel c/o Free Software Foundation.  */
+
+#ifndef        _MALLOC_INTERNAL
+#define        _MALLOC_INTERNAL
+#include <malloc.h>
+#include <mcheck.h>
+#include <libc-lock.h>
+#endif
+
+#include <stdio.h>
+
+#ifndef        __GNU_LIBRARY__
+extern char *getenv ();
+#else
+#include <stdlib.h>
+#endif
+
+static FILE *mallstream;
+static char mallenv[]= "MALLOC_TRACE";
+static char mallbuf[BUFSIZ];   /* Buffer for the output.  */
+
+__libc_lock_define_initialized (static, lock);
+
+/* Address to breakpoint on accesses to... */
+__ptr_t mallwatch;
+
+/* File name and line number information, for callers that had
+   the foresight to call through a macro.  */
+char *_mtrace_file;
+int _mtrace_line;
+
+/* Old hook values.  */
+static void (*tr_old_free_hook) __P ((__ptr_t ptr));
+static __ptr_t (*tr_old_malloc_hook) __P ((__malloc_size_t size));
+static __ptr_t (*tr_old_realloc_hook) __P ((__ptr_t ptr, __malloc_size_t size));
+
+/* This function is called when the block being alloc'd, realloc'd, or
+   freed has an address matching the variable "mallwatch".  In a debugger,
+   set "mallwatch" to the address of interest, then put a breakpoint on
+   tr_break.  */
+
+void tr_break __P ((void));
+void
+tr_break ()
+{
+}
+
+static void tr_where __P ((void));
+static void
+tr_where ()
+{
+  if (_mtrace_file)
+    {
+      fprintf (mallstream, "@ %s:%d ", _mtrace_file, _mtrace_line);
+      _mtrace_file = NULL;
+    }
+}
+
+static void tr_freehook __P ((__ptr_t));
+static void
+tr_freehook (ptr)
+     __ptr_t ptr;
+{
+  tr_where ();
+  fprintf (mallstream, "- %p\n", ptr); /* Be sure to print it first.  */
+  if (ptr == mallwatch)
+    tr_break ();
+  __libc_lock_lock (lock);
+  __free_hook = tr_old_free_hook;
+  free (ptr);
+  __free_hook = tr_freehook;
+  __libc_lock_unlock (lock);
+}
+
+static __ptr_t tr_mallochook __P ((__malloc_size_t));
+static __ptr_t
+tr_mallochook (size)
+     __malloc_size_t size;
+{
+  __ptr_t hdr;
+
+  __libc_lock_lock (lock);
+
+  __malloc_hook = tr_old_malloc_hook;
+  hdr = (__ptr_t) malloc (size);
+  __malloc_hook = tr_mallochook;
+
+  __libc_lock_unlock (lock);
+
+  tr_where ();
+  /* We could be printing a NULL here; that's OK.  */
+  fprintf (mallstream, "+ %p %lx\n", hdr, (unsigned long)size);
+
+  if (hdr == mallwatch)
+    tr_break ();
+
+  return hdr;
+}
+
+static __ptr_t tr_reallochook __P ((__ptr_t, __malloc_size_t));
+static __ptr_t
+tr_reallochook (ptr, size)
+     __ptr_t ptr;
+     __malloc_size_t size;
+{
+  __ptr_t hdr;
+
+  if (ptr == mallwatch)
+    tr_break ();
+
+  __libc_lock_lock (lock);
+
+  __free_hook = tr_old_free_hook;
+  __malloc_hook = tr_old_malloc_hook;
+  __realloc_hook = tr_old_realloc_hook;
+  hdr = (__ptr_t) realloc (ptr, size);
+  __free_hook = tr_freehook;
+  __malloc_hook = tr_mallochook;
+  __realloc_hook = tr_reallochook;
+
+  __libc_lock_unlock (lock);
+
+  tr_where ();
+  if (hdr == NULL)
+    /* Failed realloc.  */
+    fprintf (mallstream, "! %p %lx\n", ptr, (unsigned long)size);
+  else if (ptr == NULL)
+    fprintf (mallstream, "+ %p %lx\n", hdr, (unsigned long)size);
+  else
+    fprintf (mallstream, "< %p\n> %p %lx\n", ptr, hdr, (unsigned long)size);
+
+  if (hdr == mallwatch)
+    tr_break ();
+
+  return hdr;
+}
+
+/* We enable tracing if either the environment variable MALLOC_TRACE
+   is set, or if the variable mallwatch has been patched to an address
+   that the debugging user wants us to stop on.  When patching mallwatch,
+   don't forget to set a breakpoint on tr_break!  */
+
+void
+mtrace ()
+{
+  char *mallfile;
+
+  /* Don't panic if we're called more than once.  */
+  if (mallstream != NULL)
+    return;
+
+#ifdef _LIBC
+  /* When compiling the GNU libc we use the secure getenv function
+     which prevents the misuse in case of SUID or SGID enabled
+     programs.  */
+  mallfile = __secure_getenv (mallenv);
+#else
+  mallfile = getenv (mallenv);
+#endif
+  if (mallfile != NULL || mallwatch != NULL)
+    {
+      mallstream = fopen (mallfile != NULL ? mallfile : "/dev/null", "w");
+      if (mallstream != NULL)
+       {
+         /* Be sure it doesn't malloc its buffer!  */
+         setbuf (mallstream, mallbuf);
+         fprintf (mallstream, "= Start\n");
+         tr_old_free_hook = __free_hook;
+         __free_hook = tr_freehook;
+         tr_old_malloc_hook = __malloc_hook;
+         __malloc_hook = tr_mallochook;
+         tr_old_realloc_hook = __realloc_hook;
+         __realloc_hook = tr_reallochook;
+       }
+    }
+}
+
+void
+muntrace ()
+{
+  if (mallstream == NULL)
+    return;
+
+  fprintf (mallstream, "= End\n");
+  fclose (mallstream);
+  mallstream = NULL;
+  __free_hook = tr_old_free_hook;
+  __malloc_hook = tr_old_malloc_hook;
+  __realloc_hook = tr_old_realloc_hook;
+}
index e60216ed11d0212e7c95a72b0665b913ff1d7916..59ddbd626fdf62ed9400d6e6279a543b1dc0b747 100644 (file)
@@ -11,7 +11,7 @@ fractional parts.  These functions are declared in the header file
 * Predicates on Floats::        Testing for infinity and for NaNs.
 * Absolute Value::              Absolute value functions.
 * Normalization Functions::     Hacks for radix-2 representations.
-* Rounding and Remainders::     Determinining the integer and
+* Rounding and Remainders::     Determining the integer and
                                 fractional parts of a float.
 * Integer Division::            Functions for performing integer
                                 division.
@@ -495,8 +495,8 @@ to @code{ERANGE} to indicate there was overflow.
 
 Because the value @code{0l} is a correct result for @code{strtol} the
 user who is interested in handling errors should set the global variable
-@code{errno} to @code{0} before calling this function.  So it can be
-tested whether an error occured or not.
+@code{errno} to @code{0} before calling this function, so that the program
+can later test whether an error occurred.
 
 There is an example at the end of this section.
 @end deftypefun
@@ -699,7 +699,7 @@ call since all failures set @code{errno} to a non-zero value.
 @deftypefun float strtof (const char *@var{string}, char **@var{tailptr})
 This function is similar to the @code{strtod} function but it returns a
 @code{float} value instead of a @code{double} value.  If the precision
-of a @code{float} value is sufficent this function should be used since
+of a @code{float} value is sufficient this function should be used since
 it is much faster than @code{strtod} on some architectures.  The reasons
 are obvious: @w{IEEE 754} defines @code{float} to have a mantissa of 23
 bits while @code{double} has 53 bits and every additional bit of
@@ -718,9 +718,9 @@ This function is a GNU extension.
 @deftypefun {long double} strtold (const char *@var{string}, char **@var{tailptr})
 This function is similar to the @code{strtod} function but it returns a
 @code{long double} value instead of a @code{double} value.  It should be
-used when high presision is used.  On systems which define a @code{long
+used when high precision is needed.  On systems which define a @code{long
 double} type (i.e., on which it is not the same as @code{double})
-running this function might take significently more time since more bits
+running this function might take significantly more time since more bits
 of precision are required.
 
 If the string has valid syntax for a floating-point number but the value
index d5dfb6aa19df44c7591a50337bbb1e9e3a58c9c1..5eb665d2efc926029f6fd836958dcd16646f4efc 100644 (file)
@@ -73,13 +73,13 @@ included as well as the @w{ISO C}, POSIX.1, POSIX.2, and X/Open material.
 @comment (none)
 @comment XOPEN
 @defvr Macro _XOPEN_SOURCE
-If you define these macro, functionality described in the X/Open
-Portability Guide is included.  This is an superset of the POSIX.1 and
+If you define this macro, functionality described in the X/Open
+Portability Guide is included.  This is a superset of the POSIX.1 and
 POSIX.2 functionality and in fact @code{_POSIX_SOURCE} and
-@code{_POSIX_C_SOURCE} get automatically be defined.
+@code{_POSIX_C_SOURCE} are automatically defined.
 
-But as the great unifiction of all Unices there is also functionality
-only available in BSD and SVID is included.
+As the unification of all Unices, functionality only available in
+BSD and SVID is also included.
 
 If the macro @code{_XOPEN_SOURCE_EXTENDED} is also defined, even more
 functionality is available.  The extra functions will make all functions
index 47d9857dde1c3619daf08c20ae5124ffd1d0ad8a..e346dd5f1f0b4fa2fb93fefe88b63fcb7515a7d9 100644 (file)
@@ -144,7 +144,7 @@ No process matches the specified process ID.
 @comment POSIX.1: Interrupted system call
 @deftypevr Macro int EINTR
 @comment errno 4 @c DO NOT REMOVE
-Interrupted function call; an asynchronous signal occured and prevented
+Interrupted function call; an asynchronous signal occurred and prevented
 completion of the call.  When this happens, you should try the call
 again.
 
index 39d4082b7fc0e40eb97b12f350be6de31bf464c4..54ea99cfd46ce178ff80a3c6bc0f987e988d23f0 100644 (file)
@@ -338,15 +338,15 @@ value.  Use @code{readdir_r} when this is critical.
 @deftypefun int readdir_r (DIR *@var{dirstream}, struct *@var{entry}, struct **@var{result})
 This function is the reentrant version of @code{reentrant}.  Like
 @code{readdir} it returns the next entry from the directory.  But to
-prevent conflicts for simultanously running threads the result is not
+prevent conflicts for simultaneously running threads the result is not
 stored in some internal memory.  Instead the argument @var{entry} has to
 point to a place where the result is stored.
 
 The return value is @code{0} in case the next entry was read
 successfully.  In this case a pointer to the result is returned in
 *@var{result}.  It is not required that *@var{result} is the same as
-@var{entry}.  If somethings goes wrong while exeucting @code{readdir_r}
-the function return @code{-1}.  The @code{errno} variable is set like
+@var{entry}.  If something goes wrong while executing @code{readdir_r}
+the function returns @code{-1}.  The @code{errno} variable is set like
 described for @code{readdir}.
 
 @strong{Portability Note:} On some systems, @code{readdir_r} may not
index b4cb344915ef5220448b6a858bbc9b389ab689a2..e0447b6d92178070593263f7199a58f430637692 100644 (file)
@@ -92,7 +92,7 @@ standards each function or symbol comes from.
 The GNU C library is compatible with the C standard adopted by the
 American National Standards Institute (ANSI):
 @cite{American National Standard X3.159-1989---``ANSI C''} and later
-by the International Standardization Organizaion (ISO):
+by the International Standardization Organization (ISO):
 @cite{ISO/IEC 9899:1990, ``Programming languages---C''}.
 We here refer to the standard as @w{ISO C} since this is the more
 general standard in respect of ratification.
index 1ac15fffc4e4735104c0053cc325db45b156f6d7..f97aceb61cf91d43c487b0d965933a3c9b9a319f 100644 (file)
@@ -54,7 +54,7 @@ terminate all the processes in the foreground process group.
 
 @cindex session
 A @dfn{session} is a larger group of processes.  Normally all the
-proccesses that stem from a single login belong to the same session.
+processes that stem from a single login belong to the same session.
 
 Every process belongs to a process group.  When a process is created, it
 becomes a member of the same process group and session as its parent
@@ -154,7 +154,7 @@ calls @code{setsid} to become the leader of a new session.
 @cindex controlling terminal, access to
 
 Processes in the foreground job of a controlling terminal have
-unrestricted access to that terminal; background proesses do not.  This
+unrestricted access to that terminal; background processes do not.  This
 section describes in more detail what happens when a process in a
 background job tries to access its controlling terminal.
 
@@ -213,7 +213,7 @@ involved.
 
 @iftex
 @itemize @bullet
-@item 
+@item
 @ref{Data Structures}, introduces the example and presents
 its primary data structures.
 
@@ -310,7 +310,7 @@ job *
 find_job (pid_t pgid)
 @{
   job *j;
-  
+
   for (j = first_job; j; j = j->next)
     if (j->pgid == pgid)
       return j;
@@ -324,7 +324,7 @@ int
 job_is_stopped (job *j)
 @{
   process *p;
-  
+
   for (p = j->first_process; p; p = p->next)
     if (!p->completed && !p->stopped)
       return 0;
@@ -338,7 +338,7 @@ int
 job_is_completed (job *j)
 @{
   process *p;
-  
+
   for (p = j->first_process; p; p = p->next)
     if (!p->completed)
       return 0;
@@ -355,7 +355,7 @@ job_is_completed (job *j)
 
 When a shell program that normally performs job control is started, it
 has to be careful in case it has been invoked from another shell that is
-already doing its own job control.  
+already doing its own job control.
 
 A subshell that runs interactively has to ensure that it has been placed
 in the foreground by its parent shell before it can enable job control
@@ -413,7 +413,7 @@ int shell_is_interactive;
 void
 init_shell ()
 @{
-  
+
   /* @r{See if we are running interactively.}  */
   shell_terminal = STDIN_FILENO;
   shell_is_interactive = isatty (shell_terminal);
@@ -512,7 +512,7 @@ send a @code{SIGTSTP} signal to the process group of the process, not
 just to the process itself.  @xref{Signaling Another Process}.
 
 Finally, each child process should call @code{exec} in the normal way.
-This is also the point at which redirection of the standard input and 
+This is also the point at which redirection of the standard input and
 output channels should be handled.  @xref{Duplicating Descriptors},
 for an explanation of how to do this.
 
@@ -564,9 +564,9 @@ launch_process (process *p, pid_t pgid,
     @{
       dup2 (errfile, STDERR_FILENO);
       close (errfile);
-    @}    
-  
-  /* @r{Exec the new process.  Make sure we exit.}  */ 
+    @}
+
+  /* @r{Exec the new process.  Make sure we exit.}  */
   execvp (p->argv[0], p->argv);
   perror ("execvp");
   exit (1);
@@ -590,7 +590,7 @@ launch_job (job *j, int foreground)
   process *p;
   pid_t pid;
   int mypipe[2], infile, outfile;
-  
+
   infile = j->stdin;
   for (p = j->first_process; p; p = p->next)
     @{
@@ -638,7 +638,7 @@ launch_job (job *j, int foreground)
         close (outfile);
       infile = mypipe[0];
     @}
-  
+
   format_job_info (j, "launched");
 
   if (!shell_is_interactive)
@@ -704,13 +704,13 @@ put_job_in_foreground (job *j, int cont)
         perror ("kill (SIGCONT)");
     @}
 @end group
-  
+
   /* @r{Wait for it to report.}  */
   wait_for_job (j);
-    
+
   /* @r{Put the shell back in the foreground.}  */
   tcsetpgrp (shell_terminal, shell_pgid);
-    
+
 @group
   /* @r{Restore the shell's terminal modes.}  */
   tcgetattr (shell_terminal, &j->tmodes);
@@ -722,7 +722,7 @@ put_job_in_foreground (job *j, int cont)
 @cindex background job, launching
 If the process group is launched as a background job, the shell should
 remain in the foreground itself and continue to read commands from
-the terminal.  
+the terminal.
 
 In the sample shell, there is not much that needs to be done to put
 a job into the background.  Here is the function it uses:
@@ -833,7 +833,7 @@ update_status (void)
 @{
   int status;
   pid_t pid;
-  
+
   do
     pid = waitpid (WAIT_ANY, &status, WUNTRACED|WNOHANG);
   while (!mark_process_status (pid, status));
@@ -849,11 +849,11 @@ wait_for_job (job *j)
 @{
   int status;
   pid_t pid;
-  
+
   do
     pid = waitpid (WAIT_ANY, &status, WUNTRACED);
-  while (!mark_process_status (pid, status) 
-         && !job_is_stopped (j) 
+  while (!mark_process_status (pid, status)
+         && !job_is_stopped (j)
          && !job_is_completed (j));
 @}
 @end group
@@ -880,7 +880,7 @@ do_job_notification (void)
 
   /* @r{Update status information for child processes.}  */
   update_status ();
-  
+
   jlast = NULL;
   for (j = first_job; j; j = jnext)
     @{
@@ -976,7 +976,7 @@ allocated and initialized.
 Most real shells provide a complex user interface that has support for
 a command language; variables; abbreviations, substitutions, and pattern
 matching on file names; and the like.  All of this is far too complicated
-to explain here!  Instead, we have concentrated on showing how to 
+to explain here!  Instead, we have concentrated on showing how to
 implement the core process creation and job control functions that can
 be called from such a shell.
 
@@ -1058,7 +1058,7 @@ represents the size of a string large enough to hold the file name
 returned by @code{ctermid}.
 @end deftypevr
 
-See also the @code{isatty} and @code{ttyname} functions, in 
+See also the @code{isatty} and @code{ttyname} functions, in
 @ref{Is It a Terminal}.
 
 
index fa3f3e443d368110b781d9f22acdfcc20cb8ad42..f2b688400e5077b304f6d47b246195c8b3baa697 100644 (file)
@@ -616,7 +616,7 @@ Pseudo-Random Numbers
 Low-Level Arithmetic Functions
 
 * Normalization Functions::     Hacks for radix-2 representations.
-* Rounding and Remainders::     Determinining the integer and
+* Rounding and Remainders::     Determining the integer and
                                  fractional parts of a float.
 * Integer Division::            Functions for performing integer division.
 * Parsing of Numbers::          Functions for ``reading'' numbers from strings.
index cfe6b7e94b6920223dd3928149ff5fdf8800bcf6..1866c66fb75aff2c38b3e9e290ecbcaf193eb094 100644 (file)
@@ -505,7 +505,7 @@ precede the amount.
 
 We can only guess which of these (if either) matches the usual
 conventions for printing international currency symbols.  Our guess is
-that they should always preceed the amount.  If we find out a reliable
+that they should always precede the amount.  If we find out a reliable
 answer, we will put it here.
 
 @item char p_sep_by_space
index 870edd54bfb2b0151c8ae95765b354b79cbae2d1..61455ef8a8446c28d6ffaa7a745a663d30ce67ea 100644 (file)
@@ -165,7 +165,7 @@ either positive or negative @code{HUGE_VAL}.
 
 @node Inverse Trig Functions
 @section Inverse Trigonometric Functions
-@cindex inverse trigonmetric functions
+@cindex inverse trigonometric functions
 
 These are the usual arc sine, arc cosine and arc tangent functions,
 which are the inverses of the sine, cosine and tangent functions,
index e6c8649ddc60fc5a649a67753982d6c829158e7e..f24d7dd34c1dd4eeb383b25501ee8298bcd74b6d 100644 (file)
@@ -5,7 +5,7 @@
 
 @cindex Name Service Switch
 @cindex NSS
-@cindex databses
+@cindex databases
 Various functions in the C Library need to be configured to work
 correctly in the local environment.  Traditionally, this was done by
 using files (e.g., @file{/etc/passwd}), but other nameservices (line the
@@ -128,7 +128,7 @@ the reaction on lookup result line @code{[NOTFOUND=return]}.
 
 @menu
 * Services in the NSS configuration::  Service names in the NSS configuration.
-* Actions in the NSS configuration::  React approprite on the lookup result.
+* Actions in the NSS configuration::  React appropriately to the lookup result.
 * Notes on NSS Configuration File::  Things to take care about while
                                      configuring NSS.
 @end menu
@@ -181,7 +181,7 @@ service.  They mean
 
 @ftable @samp
 @item success
-No error occured an the wanted entry is returned.  The default action
+No error occurred and the wanted entry is returned.  The default action
 for this is @code{return}.
 
 @item notfound
index 903aa48073447dd665b5d047e2575784503e753c..b1e7206b58797def02cd3538ca818d78a771a2ac 100644 (file)
@@ -178,7 +178,7 @@ To return this vector, @code{glob} stores both its address and its
 length (number of elements, not counting the terminating null pointer)
 into @code{*@var{vector-ptr}}.
 
-Normally, @code{glob} sorts the file names alphabetically before 
+Normally, @code{glob} sorts the file names alphabetically before
 returning them.  You can turn this off with the flag @code{GLOB_NOSORT}
 if you want to get the information as fast as possible.  Usually it's
 a good idea to let @code{glob} sort them---if you process the files in
@@ -224,7 +224,7 @@ In the event of an error, @code{glob} stores information in
 @node Flags for Globbing
 @subsection Flags for Globbing
 
-This section describes the flags that you can specify in the 
+This section describes the flags that you can specify in the
 @var{flags} argument to @code{glob}.  Choose the flags you want,
 and combine them with the C bitwise OR operator @code{|}.
 
@@ -483,7 +483,7 @@ One of the endpoints in a range expression was invalid.
 
 These are the bit flags that you can use in the @var{cflags} operand when
 compiling a regular expression with @code{regcomp}.
+
 @table @code
 @comment regex.h
 @comment POSIX.2
@@ -530,7 +530,7 @@ This function tries to match the compiled regular expression
 @code{regexec} returns @code{0} if the regular expression matches;
 otherwise, it returns a nonzero value.  See the table below for
 what nonzero values mean.  You can use @code{regerror} to produce an
-error message string describing the reason for a nonzero value; 
+error message string describing the reason for a nonzero value;
 see @ref{Regexp Cleanup}.
 
 The argument @var{eflags} is a word of bit flags that enable various
@@ -538,7 +538,7 @@ options.
 
 If you want to get information about what part of @var{string} actually
 matched the regular expression or its subexpressions, use the arguments
-@var{matchptr} and @var{nmatch}.  Otherwise, pass @code{0} for 
+@var{matchptr} and @var{nmatch}.  Otherwise, pass @code{0} for
 @var{nmatch}, and @code{NULL} for @var{matchptr}.  @xref{Regexp
 Subexpressions}.
 @end deftypefun
@@ -549,7 +549,7 @@ locales that were in effect when you compiled the regular expression.
 The function @code{regexec} accepts the following flags in the
 @var{eflags} argument:
 
-@table @code 
+@table @code
 @comment regex.h
 @comment POSIX.2
 @item REG_NOTBOL
@@ -594,7 +594,7 @@ subexpression.
 @comment POSIX.2
 @deftp {Data Type} regmatch_t
 This is the data type of the @var{matcharray} array that you pass to
-@code{regexec}.  It containes two structure fields, as follows:
+@code{regexec}.  It contains two structure fields, as follows:
 
 @table @code
 @item rm_so
@@ -661,7 +661,7 @@ appears within another, then the results reported for the inner
 subexpression reflect whatever happened on the last match of the outer
 subexpression.  For an example, consider @samp{\(ba\(na\)*s \)*} matching
 the string @samp{bananas bas }.  The last time the inner expression
-actually matches is near the end of the first word.  But it is 
+actually matches is near the end of the first word.  But it is
 @emph{considered} again in the second word, and fails to match there.
 @code{regexec} reports nonuse of the ``na'' subexpression.
 
@@ -738,7 +738,7 @@ char *get_regerror (int errcode, regex_t *compiled)
 @cindex word expansion
 @cindex expansion of shell words
 
-@dfn{Word expansion} means the process of splitting a string into 
+@dfn{Word expansion} means the process of splitting a string into
 @dfn{words} and substituting for variables, commands, and wildcards
 just as the shell does.
 
@@ -936,7 +936,7 @@ data it points to.
 @node Flags for Wordexp
 @subsection Flags for Word Expansion
 
-This section describes the flags that you can specify in the 
+This section describes the flags that you can specify in the
 @var{flags} argument to @code{wordexp}.  Choose the flags you want,
 and combine them with the C operator @code{|}.
 
@@ -1139,7 +1139,7 @@ characters in the value of @var{variable}.  @samp{$@{#foo@}} stands for
 @end table
 
 These variants of variable substitution let you remove part of the
-variable's value before substituting it.  The @var{prefix} and 
+variable's value before substituting it.  The @var{prefix} and
 @var{suffix} are not mere strings; they are wildcard patterns, just
 like the patterns that you use to match multiple file names.  But
 in this context, they match against parts of the variable value
index 088c35d02fc5994ccc2a83c299b1af174dc2b20d..1a4f8668763f132f328e3fcd4603a5680982a35b 100644 (file)
@@ -135,7 +135,7 @@ process that receives them.  These signals arrive at unpredictable times
 during execution.  External events generate signals asynchronously, and
 so do explicit requests that apply to some other process.
 
-A given type of signal is either typically synchrous or typically
+A given type of signal is either typically synchronous or typically
 asynchronous.  For example, signals for errors are typically synchronous
 because errors generate signals synchronously.  But any type of signal
 can be generated synchronously or asynchronously with an explicit
@@ -608,7 +608,7 @@ code profiling facilities, hence the name of this signal.
 
 The signals listed in this section are used in conjunction with
 asynchronous I/O facilities.  You have to take explicit action by
-calling @code{fcntl} to enable a particular file descriptior to generate
+calling @code{fcntl} to enable a particular file descriptor to generate
 these signals (@pxref{Interrupt Input}).  The default action for these
 signals is to ignore them.
 
@@ -2310,7 +2310,7 @@ signals to any random process.  These are intended to prevent antisocial
 behavior such as arbitrarily killing off processes belonging to another
 user.  In typical use, @code{kill} is used to pass signals between
 parent, child, and sibling processes, and in these situations you
-normally do have permission to send signals.  The only common execption
+normally do have permission to send signals.  The only common exception
 is when you run a setuid program in a child process; if the program
 changes its real UID as well as its effective UID, you may not have
 permission to send a signal.  The @code{su} program does this.
@@ -2692,7 +2692,7 @@ install_handler (void)
 @end smallexample
 
 This is more reliable than blocking the other signals explicitly in the
-code for the handler.  If you block signals explicity in the handler,
+code for the handler.  If you block signals explicitly in the handler,
 you can't avoid at least a short interval at the beginning of the
 handler where they are not yet blocked.
 
@@ -2837,7 +2837,7 @@ these things in the other order, like this,
 
 @noindent
 then a signal arriving in between the @code{if} statement and the decrement
-would be effetively ``lost'' for an indefinite amount of time.  The
+would be effectively ``lost'' for an indefinite amount of time.  The
 handler would merely set @code{defer_signal}, but the program having
 already tested this variable, it would not test the variable again.
 
@@ -3081,7 +3081,7 @@ For most cases, just using @code{SIGSTKSZ} for @code{ss_size} is
 sufficient.  But if you know how much stack space your program's signal
 handlers will need, you may want to use a different size.  In this case,
 you should allocate @code{MINSIGSTKSZ} additional bytes for the signal
-stack and increase @code{ss_size} accordinly.
+stack and increase @code{ss_size} accordingly.
 @end vtable
 
 @item int ss_flags
index b931365fcb5dfb193eb803efb497a005f24aa72b..426f9496b5476ff3f3271856ef4bb56a7e1763d8 100644 (file)
@@ -236,7 +236,7 @@ must compare the external variable @code{optind} against the @var{argc}
 parameter to check this.
 
 If the option has an argument, @code{getopt} returns the argument by
-storing it in the varables @var{optarg}.  You don't ordinarily need to
+storing it in the variable @var{optarg}.  You don't ordinarily need to
 copy the @code{optarg} string, since it is a pointer into the original
 @var{argv} array, not into a static area that might be overwritten.
 
index b721af91b0980b54b39a07a259cfb9ad4e66612a..02236e3273721e96f15c189d36d8736a2788ec7b 100644 (file)
@@ -62,7 +62,7 @@ input/output library functions.  Don't try to create your own objects of
 type @code{FILE}; let the library do it.  Your programs should
 deal only with pointers to these objects (that is, @code{FILE *} values)
 rather than the objects themselves.
-@c !!! should say that FILE's have "No user-servicable parts inside."
+@c !!! should say that FILE's have "No user-serviceable parts inside."
 
 @node Standard Streams
 @section Standard Streams
@@ -1800,7 +1800,7 @@ a base type of @code{PA_DOUBLE} to indicate a type of @code{long double}.
 @end table
 
 @ifinfo
-For an example of using these facilitles, see @ref{Example of Parsing}.
+For an example of using these facilities, see @ref{Example of Parsing}.
 @end ifinfo
 
 @node Example of Parsing
index a9593ccfc5b2cc4aeaf7fa266c11d9b1dda84f3f..fcd30a11aafa23b3eaf75b2d3a7b84d95c6a9734 100644 (file)
@@ -18,9 +18,9 @@ descriptor is and how to open a file descriptor for a terminal device.
 * Canonical or Not::            Two basic styles of input processing.
 * Terminal Modes::              How to examine and modify flags controlling
                                 details of terminal I/O: echoing,
-                                 signals, editing. 
+                                 signals, editing.
 * Line Control::                Sending break sequences, clearing
-                                 terminal buffers @dots{} 
+                                 terminal buffers @dots{}
 * Noncanon Example::            How to read single characters without echo.
 @end menu
 
@@ -149,9 +149,9 @@ constants are all declared in the header file @file{termios.h}.
 
 @menu
 * Mode Data Types::             The data type @code{struct termios} and
-                                 related types. 
+                                 related types.
 * Mode Functions::              Functions to read and set the terminal
-                                 attributes. 
+                                 attributes.
 * Setting Modes::               The right way to set terminal attributes
                                  reliably.
 * Input Modes::                 Flags controlling low-level input handling.
@@ -486,7 +486,7 @@ signal for the foreground process group associated with the terminal.
 
 If neither @code{BRKINT} nor @code{IGNBRK} are set, a break condition is
 passed to the application as a single @code{'\0'} character if
-@code{PARMRK} is not set, or otherwise as a three-character sequence 
+@code{PARMRK} is not set, or otherwise as a three-character sequence
 @code{'\377'}, @code{'\0'}, @code{'\0'}.
 @end deftypevr
 
@@ -906,7 +906,7 @@ attempt to write to the terminal.  @xref{Access to the Terminal}.
 
 The following bits are BSD extensions; they exist only in BSD systems
 and the GNU system.
-     
+
 @comment termios.h
 @comment BSD
 @deftypevr Macro tcflag_t ALTWERASE
@@ -1431,7 +1431,7 @@ itself.
 The LNEXT character is recognized only when @code{IEXTEN} is set, but in
 both canonical and noncanonical mode.  It disables any special
 significance of the next character the user types.  Even if the
-character would normally perform some editting function or generate a
+character would normally perform some editing function or generate a
 signal, it is read as a plain character.  This is the analogue of the
 @kbd{C-q} command in Emacs.  ``LNEXT'' stands for ``literal next.''
 
@@ -1532,7 +1532,7 @@ TIME elapses with no further input.
 TIME elapses first.  @code{read} can return more than MIN characters if
 more than MIN happen to be in the queue.
 
-@item 
+@item
 Both MIN and TIME are zero.
 
 In this case, @code{read} always returns immediately with as many
index 9e397d3d4dc0a675098186633589bba515b86922..a622dd5fd476d8fae3dd7105d3b2851855b75244 100644 (file)
@@ -877,7 +877,7 @@ password database file.
 
 If the function returns null @var{result} points to the structure with
 the wanted data (normally this is in @var{result_buf}).  If errors
-occured the return value is non-null and @var{result} contains a null
+occurred the return value is non-null and @var{result} contains a null
 pointer.
 @end deftypefun
 
@@ -916,7 +916,7 @@ buffer or length @var{buflen} starting at @var{buffer}.
 
 If the function returns zero @var{result} points to the structure with
 the wanted data (normally this is in @var{result_buf}).  If errors
-occured the return value is non-zero and @var{result} contains a null
+occurred the return value is non-zero and @var{result} contains a null
 pointer.
 @end deftypefun
 
@@ -1100,7 +1100,7 @@ group database file.
 
 If the function returns zero @var{result} points to the structure with
 the wanted data (normally this is in @var{result_buf}).  If errors
-occured the return value is non-zero and @var{result} contains a null
+occurred the return value is non-zero and @var{result} contains a null
 pointer.
 @end deftypefun
 
@@ -1137,7 +1137,7 @@ buffer or length @var{buflen} starting at @var{buffer}.
 
 If the function returns zero @var{result} points to the structure with
 the wanted data (normally this is in @var{result_buf}).  If errors
-occured the return value is non-zero and @var{result} contains a null
+occurred the return value is non-zero and @var{result} contains a null
 pointer.
 @end deftypefun
 
@@ -1173,7 +1173,7 @@ them individual names.  More concrete: a netgroup is a list of triples
 consisting of a host name, a user name, and a domain name, where any of
 the entries can be a wildcard entry, matching all inputs.  A last
 possibility is that names of other netgroups can also be given in the
-list specifying a netgroup.  So one can construct arbitrary hierachies
+list specifying a netgroup.  So one can construct arbitrary hierarchies
 without loops.
 
 Sun's implementation allows netgroups only for the @code{nis} or
@@ -1208,7 +1208,7 @@ in the netgroup with name @var{netgroup}.
 
 When the call is successful (i.e., when a netgroup with this name exist)
 the return value is @code{1}.  When the return value is @code{0} no
-netgroup of this name is known or some other error occured.
+netgroup of this name is known or some other error occurred.
 @end deftypefun
 
 It is important to remember that there is only one single state for
@@ -1235,7 +1235,7 @@ The returned string pointers are only valid unless no of the netgroup
 related functions are called.
 
 The return value is @code{1} if the next entry was successfully read.  A
-value of @code{0} means no further entry exist or internal errors occured.
+value of @code{0} means no further entries exist or internal errors occurred.
 @end deftypefun
 
 @comment netdb.h
@@ -1249,7 +1249,7 @@ even after other netgroup related functions are called.
 The return value is @code{1} if the next entry was successfully read and
 the buffer contains enough room to place the strings in it.  @code{0} is
 returned in case no more entries are found, the buffer is too small, or
-internal errors occured.
+internal errors occurred.
 
 This function is a GNU extension.  The original implementation in the
 SunOS libc does not provide this function.
@@ -1292,7 +1292,7 @@ otherwise.
 The return value is @code{1} if an entry matching the given triple is
 found in the netgroup.  The return value is @code{0} if the netgroup
 itself is not found, the netgroup does not contain the triple or
-internal errors occured.
+internal errors occurred.
 @end deftypefun
 
 @node Database Example,  , Netgroup Database, Users and Groups
index 49d5c00aa325df0d46dd3535d4b61bdde4e751be..b713163f7695099e58d032312fd9d6b20d3d92ab 100644 (file)
@@ -28,9 +28,6 @@
 
 __BEGIN_DECLS
 
-#define        __need_Emath
-#include <errno.h>
-
 /* Get machine-dependent HUGE_VAL value (returned on overflow).
    On all IEEE754 machines, this is +Infinity.  */
 #include <huge_val.h>
index 3a969122ae9a1e4a5949125fc42b07d082889c0c..1f958c0d8909c0c92071ddd73bb59eab0e4b16ff 100644 (file)
@@ -84,7 +84,7 @@ __MATHCALL (atanh,, (_Mdouble_ __x));
 
 /* Exponential and logarithmic functions.  */
 
-/* Exponentional function of X.  */
+/* Exponential function of X.  */
 __MATHCALL (exp,, (_Mdouble_ __x));
 
 /* Break VALUE into a normalized fraction and an integral power of 2.  */
index 16f4a3a3658831a73f36f0c9003c6c8abe1351f8..81c0f689ded19e7eec9f325d80d17f0ba6f6c08e 100644 (file)
@@ -1,26 +1,26 @@
-/* Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1992,1993,1994,1995,1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <stdio.h>
 #include <termios.h>
 #include <unistd.h>
 
-/* It is desireable to use this bit on systems that have it.
+/* It is desirable to use this bit on systems that have it.
    The only bit of terminal state we want to twiddle is echoing, which is
    done in software; there is no need to change the state of the terminal
    hardware.  */
index bf7cadc53656fcf25474855d3327575046d94a0f..980b7c8d7226d82ecd7c23fedfcbb15b2ffd8fea 100644 (file)
@@ -118,7 +118,7 @@ hdestroy_r (htab)
 }
 
 
-/* This is the search function. It uses double hashing with open adressing.
+/* This is the search function. It uses double hashing with open addressing.
    The argument item.key has to be a pointer to an zero terminated, most
    probably strings of chars. The function for generating a number of the
    strings is simple but fast. It can be replaced by a more complex function
index 221546d2ba6b68cc5115cd2f129f97973ae6918f..d0097429e9f5fb6c62c01f18273725e35de829ff 100644 (file)
@@ -93,7 +93,7 @@ extern void hdestroy_r __P ((struct hsearch_data *htab));
 
 
 /* The tsearch routines are very interesting. They make many
-   assumptions about the compiler.  It assumpts that the first field
+   assumptions about the compiler.  It assumes that the first field
    in node must be the "key" field, which points to the datum.
    Everything depends on that.  */
 /* For tsearch */
index 4c5b6f4bbcd6ac7ea3800ced195ed450ed0bd4f1..6e9cdef547d000a872c87def0a57225bd81aabec 100644 (file)
@@ -177,7 +177,7 @@ vsyslog(pri, fmt, ap)
        }
 
        /* Prepare for multiple users.  We have to take care: open and
-          write are cancelation points.  */
+          write are cancellation points.  */
        __libc_cleanup_region_start ((void (*) (void *)) cancel_handler,
                                     &oldaction_ptr);
        __libc_lock_lock (syslog_lock);
index 689b2e110420556891ea0a2dcd1827a1895dff1b..6af6536a72e77c741d98bc8d2847c9a28d384d49 100644 (file)
@@ -1,20 +1,20 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* Tree search generalized from Knuth (6.2.2) Algorithm T just like
    the AT&T man page says.
@@ -30,8 +30,8 @@ Boston, MA 02111-1307, USA.  */
 #include <search.h>
 
 /* This routine is not very bad.  It makes many assumptions about
-   the compiler. It assumpts that the first field in node must be
-   the "key" field, which points to the datum. It is a very trick
+   the compiler. It assumes that the first field in the node must be
+   the "key" field, which points to the datum. It is very tricky
    stuff. H.J.  */
 
 typedef struct node_t
index 67a3be100970f7b8feaa372a3033e2125cf2eb6d..cfb89a2702461c766e23b48a834e80a36c407c52 100644 (file)
@@ -23,7 +23,7 @@
 |* Here we assume one symbol to be defined:                       *|
 |*                                                                *|
 |* DATABASE_NAME - name of the database the function accesses     *|
-|*                (e.g., hosts, servicess, ...)                   *|
+|*                (e.g., hosts, services, ...)                    *|
 |*                                                                *|
 |* One additional symbol may optionally be defined:               *|
 |*                                                                *|
index 83e1382d42c1fdf9cc80d8d28f2d1ca9ce27ec51..7fd6b3f7cba87a61d58bdcf3e27f28f89ec2e9bd 100644 (file)
@@ -248,7 +248,7 @@ _nss_netgroup_parseline (char **cursor, struct __netgrent *result,
 
       status = NSS_STATUS_SUCCESS;
 
-      /* Rememember where we stopped reading.  */
+      /* Remember where we stopped reading.  */
       *cursor = cp;
 
       result->first = 0;
index a484ef7e0569e9aa784f7dc3158c3f033d260ead..092ff6e070244703f35eec5512de42415d9618e5 100644 (file)
@@ -107,7 +107,7 @@ int __nss_database_lookup (const char *database, const char *alternative_name,
 
 /* Put first function with name FCT_NAME for SERVICE in FCTP.  The
    position is remembered in NI.  The function returns a value < 0 if
-   an error occured or no such function exists.  */
+   an error occurred or no such function exists.  */
 int __nss_lookup (service_user **ni, const char *fct_name, void **fctp);
 
 /* Determine the next step in the lookup process according to the
@@ -115,8 +115,8 @@ int __nss_lookup (service_user **ni, const char *fct_name, void **fctp);
    `__nss_lookup' or `__nss_next'.  NI specifies the last function
    examined.  The function return a value > 0 if the process should
    stop with the last result of the last function call to be the
-   result of the entire lookup.  The returned valie is 0 if there is
-   another function to use and < 0 if an error occured.
+   result of the entire lookup.  The returned value is 0 if there is
+   another function to use and < 0 if an error occurred.
 
    If ALL_VALUES is nonzero, the return value will not be > 0 as long as
    there is a possibility the lookup process can ever use following
index 553a968eed8ef29ef131510656ed6634a172bd4b..edbfb6ae9ae7d36b19b118a0a642887fc642f2e5 100644 (file)
@@ -64,7 +64,7 @@ fnmatch (pattern, string, flags)
   register const char *p = pattern, *n = string;
   register char c;
 
-/* Note that this evalutes C many times.  */
+/* Note that this evaluates C many times.  */
 # define FOLD(c) ((flags & FNM_CASEFOLD) && ISUPPER (c) ? tolower (c) : (c))
 
   while ((c = *p++) != '\0')
index 64ae3e7808b4224fd972d8324625813637362d96..a23d224332b04bd0c42343c600caa4c12b8fb821 100644 (file)
@@ -74,7 +74,7 @@
 /* Maximum number of connections that can be queued on a socket.  */
 #define        _POSIX_QLIMIT           1
 
-/* Maximem number of bytes that can be buffered on a socket for send
+/* Maximum number of bytes that can be buffered on a socket for send
    or receive.  */
 #define        _POSIX_HIWAT            _POSIX_PIPE_BUF
 
index 58002ba40adece4ddf01757fe90af91dc8dc705a..e9891609bc8553ba270ca788acb4abae85625388 100644 (file)
@@ -51,7 +51,11 @@ struct utsname
 
 #if _UTSNAME_DOMAIN_LENGTH - 0
     /* Name of the domain of this node on the network.  */
+#ifdef __USE_GNU
     char domainname[_UTSNAME_DOMAIN_LENGTH];
+#else
+    char __domainname[_UTSNAME_DOMAIN_LENGTH];
+#endif
 #endif
   };
 
index a9a89a73d3fee386613aa2404e7f8174b59e8724..5cf41df7234f93b54b7e126e648c59ff2053a9fb 100644 (file)
@@ -55,7 +55,7 @@ __BEGIN_DECLS
    creation of locales with the localedef utility.  */
 #define _POSIX2_LOCALEDEF       1
 
-/* Library is conformant to X/Open version 4.  */
+/* Library conforms to X/Open version 4.  */
 #define _XOPEN_VERSION 4
 
 /* Commands and utilities from XPG4 are available.  */
@@ -213,7 +213,7 @@ extern ssize_t write __P ((int __fd, __const __ptr_t __buf, size_t __n));
 
 
 /* Create a one-way communication channel (pipe).
-   If successul, two file descriptors are stored in PIPEDES;
+   If successful, two file descriptors are stored in PIPEDES;
    bytes written on PIPEDES[1] can be read from PIPEDES[0].
    Returns 0 if successful, -1 if not.  */
 extern int __pipe __P ((int __pipedes[2]));
@@ -246,8 +246,8 @@ extern unsigned int ualarm __P ((unsigned int __value,
                                 unsigned int __interval));
 
 /* Sleep USECONDS microseconds, or until a signal arrives that is not blocked
-   or ignored.  Return value is not necessarily useful.  */
-extern unsigned int usleep __P ((unsigned int __useconds));
+   or ignored.  */
+extern void usleep __P ((unsigned int __useconds));
 #endif
 
 
@@ -333,7 +333,6 @@ extern int dup2 __P ((int __fd, int __fd2));
 
 /* NULL-terminated array of "NAME=VALUE" environment variables.  */
 extern char **__environ;
-extern char **environ;
 
 
 /* Replace the current process, executing PATH with arguments ARGV and
@@ -605,7 +604,7 @@ extern int tcsetpgrp __P ((int __fd, __pid_t __pgrp_id));
 extern char *getlogin __P ((void));
 #ifdef __USE_REENTRANT
 /* Return at most NAME_LEN characters of the login name of the user in NAME.
-   If it cannot be determined or some other error occured, return the error
+   If it cannot be determined or some other error occurred, return the error
    code.  Otherwise return 0.  */
 extern int getlogin_r __P ((char *__name, size_t __name_len));
 #endif
@@ -830,11 +829,11 @@ extern int __libc_enable_secure;
 
 #endif
 
-#ifdef __USE_POSIX
+#ifdef __USE_POSIX199309
 /* Synchronize at least the data part of a file with the underlying
    media.  */
 extern int fdatasync __P ((int __fildes));
-#endif /* Use POSIX */
+#endif /* Use POSIX199309 */
 
 
 /* XPG4.2 specifies that prototypes for the encryption functions must
index 0cf0de3f6fb6f0d1e1c45d0e993e2b0e254aa5f3..d11ab500fb89b1e928a00c68209b518e5a379e32 100644 (file)
@@ -1 +1 @@
-BIND-4.9.5-REL
+BIND-4.9.5-P1
index 66b3530d9117609002a3a2a67dda82027d5e6700..4db67d06027e70d0f13741aabb461375ba029dbb 100644 (file)
@@ -308,7 +308,7 @@ typedef struct {
                        /* fields in third byte */
        unsigned        qr: 1;          /* response flag */
        unsigned        opcode: 4;      /* purpose of message */
-       unsigned        aa: 1;          /* authoritive answer */
+       unsigned        aa: 1;          /* authoritative answer */
        unsigned        tc: 1;          /* truncated message */
        unsigned        rd: 1;          /* recursion desired */
                        /* fields in fourth byte */
@@ -322,7 +322,7 @@ typedef struct {
                        /* fields in third byte */
        unsigned        rd :1;          /* recursion desired */
        unsigned        tc :1;          /* truncated message */
-       unsigned        aa :1;          /* authoritive answer */
+       unsigned        aa :1;          /* authoritative answer */
        unsigned        opcode :4;      /* purpose of message */
        unsigned        qr :1;          /* response flag */
                        /* fields in fourth byte */
index bf6fe02ed8e153b2602d76bba33d2d3888d1521a..0c2693136dd0fbb9733da5fff6187f297e44d35d 100644 (file)
@@ -166,7 +166,7 @@ inet_net_pton_ipv4(src, dst, size)
                        goto emsgsize;
        }
 
-       /* Firey death and destruction unless we prefetched EOS. */
+       /* Fiery death and destruction unless we prefetched EOS. */
        if (ch != '\0')
                goto enoent;
 
index f906edac0b89af50f87d612541129b76b51f1dbd..73192b5e98398a45d15032e52d8ea1d7d8ca306a 100644 (file)
@@ -73,7 +73,7 @@ __set_h_errno (int __err)
 #define        NETDB_INTERNAL  -1      /* See errno.  */
 #define        NETDB_SUCCESS   0       /* No problem.  */
 #define        HOST_NOT_FOUND  1       /* Authoritative Answer Host not found.  */
-#define        TRY_AGAIN       2       /* Non-Authoritive Host not found,
+#define        TRY_AGAIN       2       /* Non-Authoritative Host not found,
                                   or SERVERFAIL.  */
 #define        NO_RECOVERY     3       /* Non recoverable errors, FORMERR, REFUSED,
                                   NOTIMP.  */
@@ -98,7 +98,7 @@ struct hostent
   int h_addrtype;              /* Host address type.  */
   int h_length;                        /* Length of address.  */
   char **h_addr_list;          /* List of addresses from name server.  */
-#define        h_addr  h_addr_list[0]  /* Address, for backward compatiblity.  */
+#define        h_addr  h_addr_list[0]  /* Address, for backward compatibility.  */
 };
 
 /* Open host data base files and mark them as staying open even after
index 94fa1c13c4b4d25b2d9a27d37a8222499cd2e2ce..37aa29fb219dbdd2920053ed875ece02eb6e60b8 100644 (file)
@@ -96,7 +96,7 @@ typedef union querybuf
 } querybuf;
 
 
-/* Protortypes for local functions.  */
+/* Prototypes for local functions.  */
 static enum nss_status getanswer_r (const querybuf *answer, int anslen,
                                    struct netent *result, char *buffer,
                                    int buflen, lookup_method net_i);
index d96fe6e43267000db37a6dc05bef001d40ebe436..a9ca69e55feb7c0ca9735f79eff6599b7fa38967 100644 (file)
@@ -160,7 +160,7 @@ dn_expand(msg, eomorig, comp_dn, exp_dn, length)
  * 'length' is the size of the array pointed to by 'comp_dn'.
  * 'dnptrs' is a list of pointers to previous compressed names. dnptrs[0]
  * is a pointer to the beginning of the message. The list ends with NULL.
- * 'lastdnptr' is a pointer to the end of the arrary pointed to
+ * 'lastdnptr' is a pointer to the end of the array pointed to
  * by 'dnptrs'. Side effect is to update the list of pointers for
  * labels inserted into the message as we compress the name.
  * If 'dnptr' is NULL, we don't try to compress names. If 'lastdnptr'
@@ -504,56 +504,3 @@ __putlong(l, msgp)
 {
        PUTLONG(l, msgp);
 }
-
-#ifdef ultrix
-/* ultrix 4.0 had some icky packaging in its libc.a.  alias for it here.
- * there is more gunk of this kind over in res_debug.c.
- */
-#undef putshort
-void
-#if defined(__STDC__) || defined(__cplusplus)
-putshort(register u_short s, register u_char *msgp)
-#else
-putshort(s, msgp)
-       register u_short s;
-       register u_char *msgp;
-#endif
-{
-       __putshort(s, msgp);
-}
-#undef putlong
-void
-putlong(l, msgp)
-       register u_int32_t l;
-       register u_char *msgp;
-{
-       __putlong(l, msgp);
-}
-
-#undef dn_comp
-int
-dn_comp(exp_dn, comp_dn, length, dnptrs, lastdnptr)
-       const char *exp_dn;
-       u_char *comp_dn, **dnptrs, **lastdnptr;
-       int length;
-{
-       return (__dn_comp(exp_dn, comp_dn, length, dnptrs, lastdnptr));
-}
-
-#undef dn_expand
-int
-dn_expand(msg, eomorig, comp_dn, exp_dn, length)
-       const u_char *msg, *eomorig, *comp_dn;
-       char *exp_dn;
-       int length;
-{
-       return (__dn_expand(msg, eomorig, comp_dn, exp_dn, length));
-}
-
-#undef dn_skipname
-dn_skipname(comp_dn, eom)
-       const u_char *comp_dn, *eom;
-{
-       return (__dn_skipname(comp_dn, eom));
-}
-#endif /* Ultrix 4.0 hackery */
index 8fb4bcf33ff6d8bd5b1060698f0cc878844665bc..23f27acb33ccfd5353e95cbafe274ddfa32be8db 100644 (file)
@@ -287,7 +287,7 @@ __fp_nquery(msg, len, file)
        if ((_res.options & RES_INIT) == 0 && res_init() == -1)
                return;
 
-#define TruncTest(x) if (x >= endMark) goto trunc
+#define TruncTest(x) if (x > endMark) goto trunc
 #define        ErrorTest(x) if (x == NULL) goto error
 
        /*
index 459948660d5cbaaf081c151816f9fcca2b9ecdb6..91f9f400948c4bfc3de4bb1f844dc85f9394b53b 100644 (file)
@@ -95,7 +95,7 @@ static char rcsid[] = "$Id$";
  *   "search" property.
  * - The sortlist comprised of IP address netmask pairs are stored as
  *   values of the "sortlist" property. The IP address and optional netmask
- *   should be seperated by a slash (/) or ampersand (&) character.
+ *   should be separated by a slash (/) or ampersand (&) character.
  * - Internal resolver variables can be set from the value of the "options"
  *   property.
  */
index a5b4fba44bde588f457660bf2da36a1a2348e824..60d8ef2fb9bbcf95185ccea298c3567039059737 100644 (file)
@@ -96,7 +96,7 @@ static char rcsid[] = "$Id$";
 
 static int s = -1;     /* socket used for communications */
 static int connected = 0;      /* is the socket connected */
-static int vc = 0;     /* is the socket a virtual ciruit? */
+static int vc = 0;     /* is the socket a virtual circuit? */
 
 #ifndef FD_SET
 /* XXX - should be in portability.h */
index fe90ab5a75f2f9b02d90e73dec32f6c47520d630..b14cda06341c53c68bc36bff0f99d0bc9a9182d7 100644 (file)
@@ -83,7 +83,7 @@
 /*
  * Resolver configuration file.
  * Normally not present, but may contain the address of the
- * inital name server(s) to query and the domain search list.
+ * initial name server(s) to query and the domain search list.
  */
 
 #ifndef _PATH_RESCONF
 #define        RES_MAXNDOTS            15      /* should reflect bit field size */
 
 struct __res_state {
-       int     retrans;                /* retransmition time interval */
+       int     retrans;                /* retransmission time interval */
        int     retry;                  /* number of times to retransmit */
        u_long  options;                /* option flags - see below. */
        int     nscount;                /* number of name servers */
@@ -224,18 +224,22 @@ extern const struct res_sym __p_type_syms[];
 #define        p_secstodate    __p_secstodate
 #define        dn_count_labels __dn_count_labels
 #define        dn_comp         __dn_comp
-#define        dn_expand       __dn_expand
-#define        res_init        __res_init
 #define        res_randomid    __res_randomid
-#define        res_query       __res_query
-#define        res_search      __res_search
-#define        res_querydomain __res_querydomain
-#define        res_mkquery     __res_mkquery
 #define        res_send        __res_send
 #define        res_isourserver __res_isourserver
 #define        res_nameinquery __res_nameinquery
 #define        res_queriesmatch __res_queriesmatch
 #define        res_close       __res_close
+
+#ifdef BIND_RES_POSIX3
+#define        dn_expand       __dn_expand
+#define        res_init        __res_init
+#define        res_query       __res_query
+#define        res_search      __res_search
+#define        res_querydomain __res_querydomain
+#define        res_mkquery     __res_mkquery
+#endif
+
 __BEGIN_DECLS
 int            res_hnok __P((const char *));
 int            res_ownok __P((const char *));
index 26212cba5a95073b959a863c8948b3f03e520f39..7b3c26094c15cc6d2a4785605971363afe773c7a 100644 (file)
@@ -29,9 +29,6 @@
 
 __BEGIN_DECLS
 
-#define         __need_size_t
-#include <stddef.h>
-
 #include <gnu/types.h>
 #include <sigset.h>            /* __sigset_t, __sig_atomic_t.  */
 
@@ -90,16 +87,31 @@ extern int __sigblock __P ((int __mask));
 /* Set the mask of blocked signals to MASK, returning the old mask.  */
 extern int __sigsetmask __P ((int __mask));
 
+
+/* The `sigpause' function has two different interfaces.  The original
+   BSD definition defines the argument as a mask of the signal, while
+   the more modern interface in X/Open defines it as the signal
+   number.  We go with the more modern version unless the user
+   explitcly selects the BSD version.  */
+extern int __sigpause __P ((int __sig_or_mask, int __is_sig));
+
+#if defined(__USE_BSD) && !defined(__USE_XOPEN)
 /* Set the mask of blocked signals to MASK,
    wait for a signal to arrive, and then restore the mask.  */
-extern int __sigpause __P ((int __mask));
+#define sigpause(mask) __sigpause ((mask), 0)
+#else
+#ifdef __USE_XOPEN
+/* Remove a signal from the signal mask and suspend the process.  */
+#define sigpause(sig) __sigpause ((sig), 1)
+#endif
+#endif
+
 
 #ifdef __USE_BSD
 #define        sigmask(sig)    __sigmask(sig)
 
 extern int sigblock __P ((int __mask));
 extern int sigsetmask __P ((int __mask));
-extern int sigpause __P ((int __mask));
 
 /* This function is here only for compatibility.
    Use `sigprocmask' instead.  */
@@ -147,7 +159,7 @@ extern int sigaddset __P ((sigset_t *__set, int __signo));
 extern int sigdelset __P ((sigset_t *__set, int __signo));
 
 /* Return 1 if SIGNO is in SET, 0 if not.  */
-extern int sigismember __P ((__const sigset_t *__set, int signo));
+extern int sigismember __P ((__const sigset_t *__set, int __signo));
 
 /* Get the system-specific definitions of `struct sigaction'
    and the `SA_*' and `SIG_*'. constants.  */
@@ -184,7 +196,7 @@ extern int sigwait __P ((__const sigset_t *__set, int *__sig));
 
 #if    defined(_SIGNAL_H) && defined(__USE_BSD)
 
-/* Names of the signals.  This variable exists only for compatiblity.
+/* Names of the signals.  This variable exists only for compatibility.
    Use `strsignal' instead (see <string.h>).  */
 extern __const char *__const _sys_siglist[NSIG];
 extern __const char *__const sys_siglist[NSIG];
@@ -228,6 +240,9 @@ extern int sigreturn __P ((struct sigcontext *__scp));
 
 #if defined(_SIGNAL_H) && (defined(__USE_BSD) || defined(__USE_XOPEN_EXTENDED))
 
+#define         __need_size_t
+#include <stddef.h>
+
 /* If INTERRUPT is nonzero, make signal SIG interrupt system calls
    (causing them to fail with EINTR); if INTERRUPT is zero, make system
    calls be restarted after signal SIG.  */
index 9d77b39005eb1b248b0d6c5f48ae5e0920aa1234..cf0b0f1235654096fc571f0d09b50347d572e017 100644 (file)
@@ -1,23 +1,23 @@
 /* Internal function for converting integers to ASCII.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Torbjorn Granlund <tege@matematik.su.se>
-and Ulrich Drepper <drepper@gnu.ai.mit.edu>.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Torbjorn Granlund <tege@matematik.su.se>
+   and Ulrich Drepper <drepper@gnu.ai.mit.edu>.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <gmp-mparam.h>
 #include "../stdlib/gmp.h"
@@ -67,7 +67,7 @@ struct base_table_t
 };
 
 /* To reduce the memory needed we include some fields of the tables
-   only confitionally.  */
+   only conditionally.  */
 #if BITS_PER_MP_LIMB == 32
 # if UDIV_TIME > 2 * UMUL_TIME
 #  define SEL1(X) X,
index e532400f09870b26a07d4dc25148412f58fdc380..dede144b8d7d45c7ef8a40ffd3854e1205ec21bb 100644 (file)
@@ -157,7 +157,7 @@ __printf_fp (FILE *fp,
   /* We need to shift the contents of fp_input by this amount of bits. */
   int to_shift = 0;
 
-  /* The significant of the floting-point value in question  */
+  /* The fraction of the floting-point value in question  */
   MPN_VAR(frac);
   /* and the exponent. */
   int exponent;
@@ -256,7 +256,7 @@ __printf_fp (FILE *fp,
        grouping = NULL;
       else
        {
-         /* Figure out the thousands seperator character.  */
+         /* Figure out the thousands separator character.  */
          if (info->extra == 0)
            {
              if (mbtowc (&thousands_sep, _NL_CURRENT (LC_NUMERIC,
@@ -622,7 +622,7 @@ __printf_fp (FILE *fp,
                        {
                          /* We cannot save any memory.  Just roll the
                             number so that the leading digit is in a
-                            seperate limb.  */
+                            separate limb.  */
 
                          cy = __mpn_lshift (frac, tmp, tmpsize, cnt_h + 1);
                          fracsize = tmpsize + 1;
@@ -844,7 +844,7 @@ __printf_fp (FILE *fp,
              /* Round up.  */
              (*tp)++;
            else
-             /* It is more citical.  All digits were 9's.  */
+             /* It is more critical.  All digits were 9's.  */
              {
                if (type != 'f')
                  {
index fa18033ea388786d2c0ebef6f378b4c637456c7e..e2763e4c7d5003b15edbd500fdf4fb3d7275cfb2 100644 (file)
@@ -1092,7 +1092,7 @@ vfprintf (FILE *s, const CHAR_T *format, va_list ap)
 do_positional:
   {
     /* Array with information about the needed arguments.  This has to
-       be dynamically extendable.  */
+       be dynamically extensible.  */
     size_t nspecs = 0;
     size_t nspecs_max = 32;    /* A more or less arbitrary start value.  */
     struct printf_spec *specs
@@ -1327,7 +1327,7 @@ do_positional:
              /* Call the function.  */
              function_done = (*function) (s, &specs[nspecs_done].info, ptr);
 
-             /* If an error occured we don't have information about #
+             /* If an error occurred we don't have information about #
                 of chars.  */
              if (function_done < 0)
                {
index 71945bbf2e60ed0875fa544eb0abe4fc9f9c7354..7a3440c99aa94cb07a54836fc0c81bef96cd2cbd 100644 (file)
@@ -347,7 +347,7 @@ __vfscanf (FILE *s, const char *format, va_list argptr)
            }
        }
 
-      /* Check for the assignment-suppressant and the number grouping flag.  */
+      /* Check for the assignment-suppressing and the number grouping flag.  */
       while (*f == '*' || *f == '\'')
        switch (*f++)
          {
index 8ec731fa62cc9dd07d1eff6af30978bff10c80f4..68aee34ae635e0ecfcb7747a9ee270fa49edb719 100644 (file)
@@ -680,7 +680,7 @@ __invalidate (stream)
   /* Save its link.  */
   register FILE *next = stream->__next;
 
-  /* Pulverize the fucker.  */
+  /* Pulverize the deceased.  */
   memset((void *) stream, 0, sizeof(FILE));
 
   /* Restore the deceased's link.  */
index 705fd832d01b747cadcfdd1000a8220396df0b32..8e913ccbd95842e89d3fceaa6811b1da8b124a59 100644 (file)
@@ -270,7 +270,7 @@ extern int __stdio_check_offset __P ((FILE *__stream));
                or tempnam (the two are separate).
    L_ctermid   How long an array to pass to `ctermid'.
    L_cuserid   How long an array to pass to `cuserid'.
-   FOPEN_MAX   Mininum number of files that can be open at once.
+   FOPEN_MAX   Minimum number of files that can be open at once.
    FILENAME_MAX        Maximum length of a filename.  */
 #include <stdio_lim.h>
 
@@ -671,6 +671,10 @@ extern int pclose __P ((FILE *__stream));
 #ifdef __USE_POSIX
 /* Return the name of the controlling terminal.  */
 extern char *ctermid __P ((char *__s));
+#endif
+
+
+#ifdef __USE_XOPEN
 /* Return the name of the current user.  */
 extern char *cuserid __P ((char *__s));
 #endif
index 3aa4aaf2976d6b7f7d9baa43e868dbdbd38ea783..8b097b68c5f45395334f42384f44cb686f47dc3a 100644 (file)
@@ -111,7 +111,7 @@ correctly_grouped_prefix (const STRING_TYPE *begin, const STRING_TYPE *end,
 
          /* The trailing portion of the string starting at NEW_END
             contains a grouping error.  So we will look for a correctly
-            gouped number in the preceding portion instead.  */
+            grouped number in the preceding portion instead.  */
          end = new_end;
        }
       else
@@ -123,7 +123,7 @@ correctly_grouped_prefix (const STRING_TYPE *begin, const STRING_TYPE *end,
            /* This number does not fill the first group, but is correct.  */
            return end;
          else
-           /* CP points to a thousands seperator character.  */
+           /* CP points to a thousands separator character.  */
            end = cp;
        }
     }
index c2a1bc8d5e51a8aff869b52dcca2568f84f62879..c8f3f4dcb78a2b5b48eb2b8fffeaaade98dfd533 100644 (file)
@@ -1,21 +1,21 @@
 /* Header file for monetary value formatting functions.
-Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifndef        _MONETARY_H
 
@@ -27,7 +27,7 @@ Boston, MA 02111-1307, USA.  */
 
 __BEGIN_DECLS
 
-/* Formating a monetary value according to the current locale.  */
+/* Formatting a monetary value according to the current locale.  */
 extern ssize_t strfmon __P ((char *__s, size_t __maxsize,
                             __const char *__format, ...));
 
index bc8d171b793b58b563c459d1bb42560008e490f5..0c83c48569306b88ac7b1caff7501956c09b23d9 100644 (file)
@@ -1,21 +1,21 @@
-/* Copyright (C) 1991, 1992 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Written by Douglas C. Schmidt (schmidt@ics.uci.edu).
+/* Copyright (C) 1991, 1992, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Written by Douglas C. Schmidt (schmidt@ics.uci.edu).
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <ansidecl.h>
 #include <stdlib.h>
@@ -40,7 +40,7 @@ Cambridge, MA 02139, USA.  */
 #define MAX_THRESH 4
 
 /* Stack node declarations used to store unfulfilled partition obligations. */
-typedef struct 
+typedef struct
   {
     char *lo;
     char *hi;
@@ -50,26 +50,26 @@ typedef struct
 #define STACK_SIZE     (8 * sizeof(unsigned long int))
 #define PUSH(low, high)        ((void) ((top->lo = (low)), (top->hi = (high)), ++top))
 #define        POP(low, high)  ((void) (--top, (low = top->lo), (high = top->hi)))
-#define        STACK_NOT_EMPTY (stack < top)                
+#define        STACK_NOT_EMPTY (stack < top)
 
 
 /* Order size using quicksort.  This implementation incorporates
    four optimizations discussed in Sedgewick:
 
-   1. Non-recursive, using an explicit stack of pointer that store the 
-      next array partition to sort.  To save time, this maximum amount 
-      of space required to store an array of MAX_INT is allocated on the 
-      stack.  Assuming a 32-bit integer, this needs only 32 * 
+   1. Non-recursive, using an explicit stack of pointer that store the
+      next array partition to sort.  To save time, this maximum amount
+      of space required to store an array of MAX_INT is allocated on the
+      stack.  Assuming a 32-bit integer, this needs only 32 *
       sizeof(stack_node) == 136 bits.  Pretty cheap, actually.
 
    2. Chose the pivot element using a median-of-three decision tree.
-      This reduces the probability of selecting a bad pivot value and 
+      This reduces the probability of selecting a bad pivot value and
       eliminates certain extraneous comparisons.
 
    3. Only quicksorts TOTAL_ELEMS / MAX_THRESH partitions, leaving
-      insertion sort to order the MAX_THRESH items within each partition.  
+      insertion sort to order the MAX_THRESH items within each partition.
       This is a big win, since insertion sort is faster for small, mostly
-      sorted array segements.
+      sorted array segments.
 
    4. The larger of the two sub-partitions is always pushed onto the
       stack first, with the algorithm then concentrating on the
@@ -108,8 +108,8 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
          char *pivot = pivot_buffer;
 
          /* Select median value from among LO, MID, and HI. Rearrange
-            LO and HI so the three values are sorted. This lowers the 
-            probability of picking a pathological pivot value and 
+            LO and HI so the three values are sorted. This lowers the
+            probability of picking a pathological pivot value and
             skips a comparison for both the LEFT_PTR and RIGHT_PTR. */
 
          char *mid = lo + size * ((hi - lo) / size >> 1);
@@ -118,7 +118,7 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
            SWAP(mid, lo, size);
          if ((*cmp)((PTR) hi, (PTR) mid) < 0)
            SWAP(mid, hi, size);
-         else 
+         else
            goto jump_over;
          if ((*cmp)((PTR) mid, (PTR) lo) < 0)
            SWAP(mid, lo, size);
@@ -127,12 +127,12 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
          pivot = pivot_buffer;
 
          left_ptr  = lo + size;
-         right_ptr = hi - size; 
+         right_ptr = hi - size;
 
-         /* Here's the famous ``collapse the walls'' section of quicksort.  
-            Gotta like those tight inner loops!  They are the main reason 
+         /* Here's the famous ``collapse the walls'' section of quicksort.
+            Gotta like those tight inner loops!  They are the main reason
             that this algorithm runs much faster than others. */
-         do 
+         do
            {
              while ((*cmp)((PTR) left_ptr, (PTR) pivot) < 0)
                left_ptr += size;
@@ -140,23 +140,23 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
              while ((*cmp)((PTR) pivot, (PTR) right_ptr) < 0)
                right_ptr -= size;
 
-             if (left_ptr < right_ptr) 
+             if (left_ptr < right_ptr)
                {
                  SWAP(left_ptr, right_ptr, size);
                  left_ptr += size;
                  right_ptr -= size;
                }
-             else if (left_ptr == right_ptr) 
+             else if (left_ptr == right_ptr)
                {
                  left_ptr += size;
                  right_ptr -= size;
                  break;
                }
-           } 
+           }
          while (left_ptr <= right_ptr);
 
           /* Set up pointers for next iteration.  First determine whether
-             left and right partitions are below the threshold size.  If so, 
+             left and right partitions are below the threshold size.  If so,
              ignore one or both.  Otherwise, push the larger partition's
              bounds on the stack and continue sorting the smaller one. */
 
@@ -164,22 +164,22 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
             {
               if ((size_t) (hi - left_ptr) <= max_thresh)
                /* Ignore both small partitions. */
-                POP(lo, hi); 
+                POP(lo, hi);
               else
-               /* Ignore small left partition. */  
+               /* Ignore small left partition. */
                 lo = left_ptr;
             }
           else if ((size_t) (hi - left_ptr) <= max_thresh)
            /* Ignore small right partition. */
             hi = right_ptr;
           else if ((right_ptr - lo) > (hi - left_ptr))
-            {                   
+            {
              /* Push larger left partition indices. */
               PUSH(lo, right_ptr);
               lo = left_ptr;
             }
           else
-            {                   
+            {
              /* Push larger right partition indices. */
               PUSH(left_ptr, hi);
               hi = right_ptr;
@@ -188,8 +188,8 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
     }
 
   /* Once the BASE_PTR array is partially sorted by quicksort the rest
-     is completely sorted using insertion sort, since this is efficient 
-     for partitions below MAX_THRESH size. BASE_PTR points to the beginning 
+     is completely sorted using insertion sort, since this is efficient
+     for partitions below MAX_THRESH size. BASE_PTR points to the beginning
      of the array to sort, and END_PTR points at the very last element in
      the array (*not* one beyond it!). */
 
@@ -240,4 +240,3 @@ DEFUN(_quicksort, (pbase, total_elems, size, cmp),
       }
   }
 }
-
index ffa658d6507945050197730ce434a6dde0fbd04f..370a6105d5d1e8480d0ad35a99ebdd033c7d1bad 100644 (file)
    then initialized to contain information for random number generation with
    that much state information.  Good sizes for the amount of state
    information are 32, 64, 128, and 256 bytes.  The state can be switched by
-   calling the setstate() function with the same array as was initiallized
+   calling the setstate() function with the same array as was initialized
    with initstate().  By default, the package runs with 128 bytes of state
    information and generates far better random numbers than a linear
    congruential generator.  If the amount of state information is less than
    32 bytes, a simple linear congruential R.N.G. is used.  Internally, the
-   state information is treated as an array of longs; the zeroeth element of
+   state information is treated as an array of longs; the zeroth element of
    the array is the type of R.N.G. being used (small integer); the remainder
    of the array is the state information for the R.N.G.  Thus, 32 bytes of
    state information will give 7 longs worth of state information, which will
-   allow a degree seven polynomial.  (Note: The zeroeth word of state
+   allow a degree seven polynomial.  (Note: The zeroth word of state
    information also has some other information stored in it; see setstate
    for details).  The random number generation technique is a linear feedback
    shift register approach, employing trinomials (since there are fewer terms
@@ -64,7 +64,7 @@
 
 
 /* For each of the currently supported random number generators, we have a
-   break value on the amount of state information (you need at least thi
+   break value on the amount of state information (you need at least this many
    bytes of state info to support this random number generator), a degree for
    the polynomial (actually a trinomial) that the R.N.G. is based on, and
    separation between the two lower order coefficients of the trinomial.  */
        initstate(1, randtbl, 128);
    Note that this initialization takes advantage of the fact that srandom
    advances the front and rear pointers 10*rand_deg times, and hence the
-   rear pointer which starts at 0 will also end up at zero; thus the zeroeth
+   rear pointer which starts at 0 will also end up at zero; thus the zeroth
    element of the state information, which contains info about the current
    position of the rear pointer is just
        (MAX_TYPES * (rptr - state)) + TYPE_3 == TYPE_3.  */
@@ -148,7 +148,7 @@ static struct random_data unsafe_state =
    the type of the current generator, the degree of the current polynomial
    being used, and the separation between the two pointers.
    Note that for efficiency of random, we remember the first location of
-   the state information, not the zeroeth.  Hence it is valid to access
+   the state information, not the zeroth.  Hence it is valid to access
    state[-1], which is used to store the type of the R.N.G.
    Also, we remember the last location, since this is more efficient than
    indexing every time to find the address of the last element to see if
@@ -224,7 +224,7 @@ weak_alias (__initstate, initstate)
    Note: It is important that we also remember the locations of the pointers
    in the current state information, and restore the locations of the pointers
    from the old state information.  This is done by multiplexing the pointer
-   location into the zeroeth word of the state information. Note that due
+   location into the zeroth word of the state information. Note that due
    to the order in which things are done, it is OK to call setstate with the
    same state as the current state
    Returns a pointer to the old state information.  */
@@ -250,7 +250,7 @@ weak_alias (__setstate, setstate)
 \f
 /* If we are using the trivial TYPE_0 R.N.G., just do the old linear
    congruential bit.  Otherwise, we do our fancy trinomial stuff, which is the
-   same in all ther other cases due to all the global variables that have been
+   same in all the other cases due to all the global variables that have been
    set up.  The basic operation is to add the number at the rear pointer into
    the one at the front pointer.  Then both pointers are advanced to the next
    location cyclically in the table.  The value returned is the sum generated,
index 823075bfc3965ba7d7ff41f1251692fa5759c60b..d19fd1755b441a281e351ca28ecf629fcf591027 100644 (file)
    then initialized to contain information for random number generation with
    that much state information.  Good sizes for the amount of state
    information are 32, 64, 128, and 256 bytes.  The state can be switched by
-   calling the setstate() function with the same array as was initiallized
+   calling the setstate() function with the same array as was initialized
    with initstate().  By default, the package runs with 128 bytes of state
    information and generates far better random numbers than a linear
    congruential generator.  If the amount of state information is less than
    32 bytes, a simple linear congruential R.N.G. is used.  Internally, the
-   state information is treated as an array of longs; the zeroeth element of
+   state information is treated as an array of longs; the zeroth element of
    the array is the type of R.N.G. being used (small integer); the remainder
    of the array is the state information for the R.N.G.  Thus, 32 bytes of
    state information will give 7 longs worth of state information, which will
-   allow a degree seven polynomial.  (Note: The zeroeth word of state
+   allow a degree seven polynomial.  (Note: The zeroth word of state
    information also has some other information stored in it; see setstate
    for details).  The random number generation technique is a linear feedback
    shift register approach, employing trinomials (since there are fewer terms
@@ -64,7 +64,7 @@
 
 
 /* For each of the currently supported random number generators, we have a
-   break value on the amount of state information (you need at least thi
+   break value on the amount of state information (you need at least this many
    bytes of state info to support this random number generator), a degree for
    the polynomial (actually a trinomial) that the R.N.G. is based on, and
    separation between the two lower order coefficients of the trinomial.  */
@@ -236,7 +236,7 @@ weak_alias (__initstate_r, initstate_r)
    Note: It is important that we also remember the locations of the pointers
    in the current state information, and restore the locations of the pointers
    from the old state information.  This is done by multiplexing the pointer
-   location into the zeroeth word of the state information. Note that due
+   location into the zeroth word of the state information. Note that due
    to the order in which things are done, it is OK to call setstate with the
    same state as the current state
    Returns a pointer to the old state information.  */
@@ -290,7 +290,7 @@ weak_alias (__setstate_r, setstate_r)
 \f
 /* If we are using the trivial TYPE_0 R.N.G., just do the old linear
    congruential bit.  Otherwise, we do our fancy trinomial stuff, which is the
-   same in all ther other cases due to all the global variables that have been
+   same in all the other cases due to all the global variables that have been
    set up.  The basic operation is to add the number at the rear pointer into
    the one at the front pointer.  Then both pointers are advanced to the next
    location cyclically in the table.  The value returned is the sum generated,
index 99fcf2e7c7a290e73cb11d04c42e226ddca89181..235b2f0b59bcef91f9401327eb25d1e9f26dedd5 100644 (file)
@@ -31,9 +31,6 @@
 #define        __need_NULL
 #include <stddef.h>
 
-#define        __need_Emath
-#include <errno.h>
-
 __BEGIN_DECLS
 
 /* Returned by `div'.  */
index 85f8898136f7f46d924437efcd5fdaa228cefa03..469908c1df813f373aaebe5078e397b8e9420be0 100644 (file)
@@ -1,23 +1,23 @@
-/* strfmon -- formating a monetary value according to the current locale
-Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@cygnus.com>
-and Jochen Hein <Jochen.Hein@informatik.TU-Clausthal.de>, 1996.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+/* Formatting a monetary value according to the current locale.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>
+   and Jochen Hein <Jochen.Hein@informatik.TU-Clausthal.de>, 1996.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <ctype.h>
 #include <errno.h>
@@ -355,7 +355,7 @@ strfmon (char *s, size_t maxsize, const char *format, ...)
 #define left_paren '('
 #define right_paren ')'
 
-      startp = dest;           /* Remember start so we can compute lenght.  */
+      startp = dest;           /* Remember start so we can compute length.  */
 
       if (sign_posn == 0)
        out_char (left_paren);
index 60a3de52280c7639757d1b28b587172a79b6ea55..8c305ca1782a75f3fd1960f17888c4fa2b755fd2 100644 (file)
@@ -333,7 +333,7 @@ __mpn_lshift_1 (mp_limb_t *ptr, mp_size_t size, unsigned int count,
    Set *ENDPTR to the character after the last used one.  If the number is
    smaller than the smallest representable number, set `errno' to ERANGE and
    return 0.0.  If the number is too big to be represented, set `errno' to
-   ERANGE and return HUGE_VAL with the approriate sign.  */
+   ERANGE and return HUGE_VAL with the appropriate sign.  */
 FLOAT
 INTERNAL (STRTOF) (nptr, endptr, group)
      const STRING_TYPE *nptr;
index 03af3d49ad734099830f8d0865fb5a5de0e66eca..f00fe24d3185a485d3af129be2869213ea73df7c 100644 (file)
@@ -123,7 +123,7 @@ envz_add (char **envz, size_t *envz_len, const char *name, const char *value)
 }
 \f
 /* Adds each entry in ENVZ2 to ENVZ & ENVZ_LEN, as if with envz_add().  If
-   OVERRIDE is true, then values in ENVZ2 will supercede those with the same
+   OVERRIDE is true, then values in ENVZ2 will supersede those with the same
    name in ENV, otherwise not.  */
 error_t
 envz_merge (char **envz, size_t *envz_len, const char *envz2,
index b7a34b3b6c951009a38c09d543aa0ffb17740a23..23aaed61197f9d3ab6344f337189d3f9e0a32dd3 100644 (file)
@@ -49,7 +49,7 @@ extern error_t envz_add __P ((char **__envz, size_t *__envz_len,
                              __const char *__name, __const char *__value));
 
 /* Adds each entry in ENVZ2 to ENVZ & ENVZ_LEN, as if with envz_add().  If
-   OVERRIDE is true, then values in ENVZ2 will supercede those with the same
+   OVERRIDE is true, then values in ENVZ2 will supersede those with the same
    name in ENV, otherwise not.  */
 extern error_t envz_merge __P ((char **__envz, size_t *__envz_len,
                                __const char *__envz2, size_t __envz2_len,
index a994e569be456191bc9b70d07a73b9beffcfd0de..ebe565968e129110b2369daeceafe8c3bacef302 100644 (file)
@@ -47,7 +47,7 @@ main (int argc, char *argv[])
         puts ("No test, mmap not available.");
       else
         {
-          printf ("mmaping failed: %m");
+          printf ("mmap failed: %m");
           result = 1;
         }
     }
index 62a08a016f4032b4137b7245b8ed70f22a9943ac..7052ef64d6a3e4b842e2892794ce72c500b835aa 100644 (file)
@@ -1,27 +1,27 @@
-/* Copyright (C) 1991, 1993, 1994, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1991, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <stdio.h>
 #include <string.h>
 
 extern char *_strerror_internal __P ((int, char *, size_t));
 
-/* Return a string descibing the errno code in ERRNUM.
+/* Return a string describing the errno code in ERRNUM.
    The storage is good only until the next call to strerror.
    Writing to the storage causes undefined behavior.  */
 char *
index e03e50c635a557ab39fff78371529e8f0b542064..6a43a556a995932b4cd5a5c9332799242739080b 100644 (file)
@@ -21,7 +21,7 @@
 
 extern char *_strerror_internal __P ((int, char *, size_t));
 
-/* Return a string descibing the errno code in ERRNUM.  At most BUFLEN
+/* Return a string describing the errno code in ERRNUM.  At most BUFLEN
    characters of the result will be placed in STRERRBUF.  */
 char *
 __strerror_r (int errnum, char *buf, size_t buflen)
index 79a7aaa58da938cd46516bb1810d8b3076a1e17d..c51fb956ea6f37d439d3e2471635a6c070e9674d 100644 (file)
@@ -93,7 +93,9 @@ extern char *strdup __P ((__const char *__s));
    resultant string is terminated even if no null terminator
    appears before STRING[N].  */
 extern char *__strndup __P ((__const char *__string, size_t __n));
+#if defined(__USE_GNU)
 extern char *strndup __P ((__const char *__string, size_t __n));
+#endif
 
 #if defined (__USE_GNU) && defined (__GNUC__)
 /* Duplicate S, returning an identical alloca'd string.  */
@@ -129,9 +131,9 @@ extern size_t strcspn __P ((__const char *__s, __const char *__reject));
 /* Return the length of the initial segment of S which
    consists entirely of characters in ACCEPT.  */
 extern size_t strspn __P ((__const char *__s, __const char *__accept));
-/* Find the first occurence in S of any character in ACCEPT.  */
+/* Find the first occurrence in S of any character in ACCEPT.  */
 extern char *strpbrk __P ((__const char *__s, __const char *__accept));
-/* Find the first occurence of NEEDLE in HAYSTACK.  */
+/* Find the first occurrence of NEEDLE in HAYSTACK.  */
 extern char *strstr __P ((__const char *__haystack, __const char *__needle));
 /* Divide S into tokens separated by characters in DELIM.  */
 extern char *strtok __P ((char *__s, __const char *__delim));
@@ -142,7 +144,7 @@ extern char *strtok __P ((char *__s, __const char *__delim));
 extern char *strtok_r __P ((char *__s, __const char *__delim,
                            char **__save_ptr));
 
-/* Find the first occurence of NEEDLE in HAYSTACK.
+/* Find the first occurrence of NEEDLE in HAYSTACK.
    NEEDLE is NEEDLELEN bytes long;
    HAYSTACK is HAYSTACKLEN bytes long.  */
 extern __ptr_t memmem __P ((__const __ptr_t __haystack, size_t __haystacklen,
index 6d0a7061b7a67ff57492bd0ad44d3ca40f66f229..820ad9394707b1367e4e2884920d34f228d54058 100644 (file)
@@ -1,21 +1,21 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
+   This file is part of the GNU C Library.
+   Written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <stddef.h>
 #include <stdlib.h>
@@ -178,7 +178,7 @@ STRXFRM (STRING_TYPE *dest, const STRING_TYPE *src, size_t n)
          u_int32_t w;
 
          /* Here we have to check for IGNORE entries.  If these are
-            found we count them and go on witht he next value.  */
+            found we count them and go on with he next value.  */
          while ((w = run->data[pass].value[idx]) == (u_int32_t) IGNORE_CHAR)
            {
              ++ignore;
index 7e9e6e9e29f61a390d843cdb1d55b8d055849a04..fe2aecfa5aa1d2a663a4b5fcc8f9952f871c7acb 100644 (file)
@@ -38,8 +38,8 @@ static char sccsid[] = "@(#)clnt_raw.c 1.22 87/08/11 Copyr 1984 Sun Micro";
  *
  * Memory based rpc for simple testing and timing.
  * Interface to create an rpc client and server in the same process.
- * This lets us similate rpc and get round trip overhead, without
- * any interference from the kernal.
+ * This lets us simulate rpc and get round trip overhead, without
+ * any interference from the kernel.
  */
 
 #include <rpc/rpc.h>
@@ -95,7 +95,7 @@ clntraw_create(prog, vers)
                clntraw_private = clp;
        }
        /*
-        * pre-serialize the staic part of the call msg and stash it away
+        * pre-serialize the static part of the call msg and stash it away
         */
        call_msg.rm_direction = CALL;
        call_msg.rm_call.cb_rpcvers = RPC_MSG_VERSION;
index be365f1b2a1b95e175f6b47fcd7fb86cd3f1c497..bd40cdddf6579c0b22abf1f3ba8a11eeaae3d1f1 100644 (file)
@@ -189,7 +189,7 @@ clnttcp_create(raddr, prog, vers, sockp, sendsz, recvsz)
        call_msg.rm_call.cb_vers = vers;
 
        /*
-        * pre-serialize the staic part of the call msg and stash it away
+        * pre-serialize the static part of the call msg and stash it away
         */
        xdrmem_create(&(ct->ct_xdrs), ct->ct_mcall, MCALL_MSG_SIZE,
            XDR_ENCODE);
index 2074095d998062857e8092eb155ea9927df3cb8f..6b12306a55c32dfa85c86095eed037b8f699eab0 100644 (file)
@@ -97,7 +97,7 @@ struct cu_data {
  *     Caller may wish to set this something more useful.
  *
  * wait is the amount of time used between retransmitting a call if
- * no response has been heard;  retransmition occurs until the actual
+ * no response has been heard; retransmission occurs until the actual
  * rpc call times out.
  *
  * sendsz and recvsz are the maximum allowable packet sizes that can be
index 3fbc47224d38ea82371f8ca9869d3ceda2d8d712..40a35f19904e9dcdd76a15df1587cb2499dea34a 100644 (file)
@@ -166,7 +166,7 @@ static int
 getbroadcastnets(addrs, sock, buf)
        struct in_addr *addrs;
        int sock;  /* any valid socket will do */
-       char *buf;  /* why allocxate more when we can use existing... */
+       char *buf;  /* why allocate more when we can use existing... */
 {
        struct ifconf ifc;
         struct ifreq ifreq, *ifr;
index a40bddd4c38b3fa240c0a232aec7830d6afa7d40..39aa0f7bcbe4907bd148e4960ff8e4d9ee273e2d 100644 (file)
@@ -97,7 +97,7 @@ typedef struct {
        struct auth_ops {
                void    (*ah_nextverf)();
                int     (*ah_marshal)();        /* nextverf & serialize */
-               int     (*ah_validate)();       /* validate varifier */
+               int     (*ah_validate)();       /* validate verifier */
                int     (*ah_refresh)();        /* refresh credentials */
                void    (*ah_destroy)();        /* destroy this structure */
        } *ah_ops;
index 24afaee1258cb544f45e76d1bbf307a0a550e87a..097eb6877104a91c88e862c8420f3f49eaabc285 100644 (file)
@@ -21,8 +21,8 @@
 #define _RPC_AUTH_DES_H        1
 #include <sys/cdefs.h>
 
-/* This is no complete version of this header.  More defintions with
-   the real authentification stuff will come in 1997.  For now we only
+/* This is no complete version of this header.  More definitions with
+   the real authentication stuff will come in 1997.  For now we only
    need to define the function for handling public keys.  */
 
 
index 2e1ff26314ac497d3cfb4838b3a4ff0c0b2ae6cc..305e26d2414dfcbb861225e5a6cd79a8fd83550a 100644 (file)
@@ -71,7 +71,7 @@ enum clnt_stat {
         * callrpc & clnt_create errors
         */
        RPC_UNKNOWNHOST=13,             /* unknown host name */
-       RPC_UNKNOWNPROTO=17,            /* unkown protocol */
+       RPC_UNKNOWNPROTO=17,            /* unknown protocol */
 
        /*
         * _ create errors
@@ -91,7 +91,7 @@ enum clnt_stat {
 struct rpc_err {
        enum clnt_stat re_status;
        union {
-               int RE_errno;           /* realated system error */
+               int RE_errno;           /* related system error */
                enum auth_stat RE_why;  /* why the auth error occurred */
                struct {
                        u_long low;     /* lowest verion supported */
@@ -210,7 +210,7 @@ typedef struct {
 
 
 /*
- * RPCTEST is a test program which is accessable on every rpc
+ * RPCTEST is a test program which is accessible on every rpc
  * transport/port.  It is used for testing, performance evaluation,
  * and network administration.
  */
index 081f9bc3276110cf50674431c69227d5934d836f..3fee9ee394a9022f49ec3fe3989ab3cd26975fc1 100644 (file)
@@ -74,7 +74,7 @@ typedef struct {
        int             xp_sock;
        u_short         xp_port;         /* associated port number */
        struct xp_ops {
-           bool_t      (*xp_recv)();    /* receive incomming requests */
+           bool_t      (*xp_recv)();    /* receive incoming requests */
            enum xprt_stat (*xp_stat)(); /* get transport status */
            bool_t      (*xp_getargs)(); /* get arguments */
            bool_t      (*xp_reply)();   /* send reply */
@@ -236,7 +236,7 @@ extern void svcerr_systemerr __P ((SVCXPRT *__xprt));
  * Somebody has to wait for incoming requests and then call the correct
  * service routine.  The routine svc_run does infinite waiting; i.e.,
  * svc_run never returns.
- * Since another (co-existant) package may wish to selectively wait for
+ * Since another (coexistant) package may wish to selectively wait for
  * incoming calls or other events outside of the rpc architecture, the
  * routine svc_getreq is provided.  It must be passed readfds, the
  * "in-place" results of a select system call (see select, section 2).
index 1cc9af937525560adf07118e2343fdde6cd265c6..e54df5a1fd53ccba41ba0762c5fba9b0331004c9 100644 (file)
@@ -96,8 +96,8 @@ enum xdr_op {
 /*
  * The XDR handle.
  * Contains operation which is being applied to the stream,
- * an operations vector for the paticular implementation (e.g. see xdr_mem.c),
- * and two private fields for the use of the particular impelementation.
+ * an operations vector for the particular implementation (e.g. see xdr_mem.c),
+ * and two private fields for the use of the particular implementation.
  */
 typedef struct {
        enum xdr_op     x_op;           /* operation; fast additional param */
@@ -196,7 +196,7 @@ struct xdr_discrim {
 };
 
 /*
- * In-line routines for fast encode/decode of primitve data types.
+ * Inline routines for fast encode/decode of primitive data types.
  * Caveat emptor: these use single memory cycles to get the
  * data from the underlying buffer, and will fail to operate
  * properly if the data is not aligned.  The standard way to use these
index 7bfe491d9eb7908820211b485f3966d5aa8d033e..fbb876110062b740c4cc6b065da0ccb7257e79b6 100644 (file)
@@ -36,7 +36,7 @@ char clntout_rcsid[] =
 
 /*
  * rpc_clntout.c, Client-stub outputter for the RPC protocol compiler
- * Copyright (C) 1987, Sun Microsytsems, Inc.
+ * Copyright (C) 1987, Sun Microsystems, Inc.
  */
 #include <stdio.h>
 #include <string.h>
@@ -60,7 +60,7 @@ write_stubs(void)
        list *l;
        definition *def;
 
-       f_print(fout, 
+       f_print(fout,
                "\n/* Default timeout can be changed using clnt_control() */\n");
        f_print(fout, "static struct timeval TIMEOUT = { %d, 0 };\n",
                DEFAULT_TIMEOUT);
@@ -99,7 +99,7 @@ write_program(definition *def)
 
 /* sample addargname = "clnt"; sample addargtype = "CLIENT * " */
 
-void printarglist(proc_list *proc, 
+void printarglist(proc_list *proc,
                  const char *addargname, const char *addargtype)
 {
 
@@ -110,16 +110,16 @@ void printarglist(proc_list *proc,
       f_print(fout, "(");
       ptype(proc->args.decls->decl.prefix, proc->args.decls->decl.type, 1);
       f_print(fout, "*argp, %s%s)\n", addargtype, addargname );
-    } 
+    }
     else {
       f_print(fout, "(argp, %s)\n", addargname);
       f_print(fout, "\t");
       ptype(proc->args.decls->decl.prefix, proc->args.decls->decl.type, 1);
       f_print(fout, "*argp;\n");
     }
-  } else if (streq( proc->args.decls->decl.type, "void")) { 
+  } else if (streq( proc->args.decls->decl.type, "void")) {
     /* newstyle, 0 argument */
-    if( Cflag ) 
+    if( Cflag )
       f_print(fout, "(%s%s)\n", addargtype, addargname );
     else
       f_print(fout, "(%s)\n", addargname);
@@ -127,7 +127,7 @@ void printarglist(proc_list *proc,
     /* new style, 1 or multiple arguments */
     if( !Cflag ) {
       f_print(fout, "(");
-      for (l = proc->args.decls;  l != NULL; l = l->next) 
+      for (l = proc->args.decls;  l != NULL; l = l->next)
        f_print(fout, "%s, ", l->decl.name);
       f_print(fout, "%s)\n", addargname );
       for (l = proc->args.decls; l != NULL; l = l->next) {
@@ -142,13 +142,13 @@ void printarglist(proc_list *proc,
     }
   }
 
-  if( !Cflag ) 
+  if( !Cflag )
     f_print(fout, "\t%s%s;\n", addargtype, addargname );
 }
 
 
 
-static 
+static
 const char *
 ampr(const char *type)
 {
@@ -170,7 +170,7 @@ printbody(proc_list *proc)
      to stuff the arguments. */
        if ( newstyle && args2) {
                f_print(fout, "\t%s", proc->args.argname);
-               f_print(fout, " arg;\n");       
+               f_print(fout, " arg;\n");
        }
        f_print(fout, "\tstatic ");
        if (streq(proc->res_type, "void")) {
@@ -186,7 +186,7 @@ printbody(proc_list *proc)
          /* newstyle, 0 arguments */
          f_print(fout,
                    "\tif (clnt_call(clnt, %s, xdr_void", proc->proc_name);
-         f_print(fout, 
+         f_print(fout,
                  ", NULL, xdr_%s, %s,%s, TIMEOUT) != RPC_SUCCESS) {\n",
                  stringfix(proc->res_type), ampr(proc->res_type), RESULT);
 
@@ -199,14 +199,14 @@ printbody(proc_list *proc)
          f_print(fout,
                  "\tif (clnt_call(clnt, %s, xdr_%s", proc->proc_name,
                  proc->args.argname);
-         f_print(fout, 
+         f_print(fout,
                      ", &arg, xdr_%s, %s%s, TIMEOUT) != RPC_SUCCESS) {\n",
                  stringfix(proc->res_type), ampr(proc->res_type), RESULT);
        } else {  /* single argument, new or old style */
              f_print(fout,
                      "\tif (clnt_call(clnt, %s, xdr_%s, %s%s, xdr_%s, %s%s, TIMEOUT) != RPC_SUCCESS) {\n",
-                     proc->proc_name, 
-                     stringfix(proc->args.decls->decl.type), 
+                     proc->proc_name,
+                     stringfix(proc->args.decls->decl.type),
                      (newstyle ? "&" : ""),
                      (newstyle ? proc->args.decls->decl.name : "argp"),
                      stringfix(proc->res_type), ampr(proc->res_type),RESULT);
@@ -214,10 +214,9 @@ printbody(proc_list *proc)
        f_print(fout, "\t\treturn (NULL);\n");
        f_print(fout, "\t}\n");
        if (streq(proc->res_type, "void")) {
-               f_print(fout, "\treturn ((void *)%s%s);\n", 
+               f_print(fout, "\treturn ((void *)%s%s);\n",
                        ampr(proc->res_type),RESULT);
        } else {
                f_print(fout, "\treturn (%s%s);\n", ampr(proc->res_type),RESULT);
        }
 }
-
index 378a686fa7d4b11fc8139d831170f0216fff1413..77319d9b15a29cc7acf9902366dbcfbfd9c784f9 100644 (file)
@@ -81,7 +81,7 @@ emit(definition *def)
          {
          /* now we need to handle declarations like
    struct typedef foo foo;
-   since we dont want this to be expanded into 2 calls to xdr_foo */
+   since we don't want this to be expanded into 2 calls to xdr_foo */
 
        if(strcmp(def->def.ty.old_type,def->def_name)==0)
          return;
index 7e0d7f3ad6d9d3aa2cf0797985c6525b612a0343..310b4ca5428b48e08009c72120df16b9ad327b15 100644 (file)
@@ -8,23 +8,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -45,10 +45,10 @@ const FHSIZE = 32;          /* size in bytes of a file handle */
  * or a directory. The file handle can contain whatever information the
  * server needs to distinguish an individual file.
  */
-typedef opaque fhandle[FHSIZE];        
+typedef opaque fhandle[FHSIZE];
 
 /*
- * If a status of zero is returned, the call completed successfully, and 
+ * If a status of zero is returned, the call completed successfully, and
  * a file handle for the directory follows. A non-zero status indicates
  * some sort of error. The status corresponds with UNIX error numbers.
  */
@@ -101,18 +101,18 @@ struct exportnode {
 program MOUNTPROG {
        /*
         * Version one of the mount protocol communicates with version two
-        * of the NFS protocol. The only connecting point is the fhandle 
+        * of the NFS protocol. The only connecting point is the fhandle
         * structure, which is the same for both protocols.
         */
        version MOUNTVERS {
                /*
                 * Does no work. It is made available in all RPC services
-                * to allow server reponse testing and timing
+                * to allow server response testing and timing
                 */
                void
                MOUNTPROC_NULL(void) = 0;
 
-               /*      
+               /*
                 * If fhs_status is 0, then fhs_fhandle contains the
                 * file handle for the directory. This file handle may
                 * be used in the NFS protocol. This procedure also adds
@@ -120,12 +120,12 @@ program MOUNTPROG {
                 * the directory.
                 * Unix authentication required.
                 */
-               fhstatus 
+               fhstatus
                MOUNTPROC_MNT(dirpath) = 1;
 
                /*
-                * Returns the list of remotely mounted filesystems. The 
-                * mountlist contains one entry for each hostname and 
+                * Returns the list of remotely mounted filesystems. The
+                * mountlist contains one entry for each hostname and
                 * directory pair.
                 */
                mountlist
index 7633e5add47db0a21d1dd438b47eff6c62311239..630dab24d1578ee606648314788b19c3865b7fe0 100644 (file)
@@ -7,23 +7,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -99,7 +99,7 @@ struct nfs_fh {
        opaque data[NFS_FHSIZE];
 };
 
-/* 
+/*
  * Timeval
  */
 struct nfstime {
@@ -118,7 +118,7 @@ struct fattr {
        unsigned uid;           /* owner user id */
        unsigned gid;           /* owner group id */
        unsigned size;          /* file size in bytes */
-       unsigned blocksize;     /* prefered block size */
+       unsigned blocksize;     /* preferred block size */
        unsigned rdev;          /* special device # */
        unsigned blocks;        /* Kb of disk used by file */
        unsigned fsid;          /* device # */
@@ -141,7 +141,7 @@ struct sattr {
 };
 
 
-typedef string filename<NFS_MAXNAMLEN>; 
+typedef string filename<NFS_MAXNAMLEN>;
 typedef string nfspath<NFS_MAXPATHLEN>;
 
 /*
@@ -215,7 +215,7 @@ default:
 };
 
 /*
- * Arguments to remote write 
+ * Arguments to remote write
  */
 struct writeargs {
        nfs_fh  file;           /* handle for file */
@@ -297,28 +297,28 @@ default:
  */
 program NFS_PROGRAM {
        version NFS_VERSION {
-               void 
+               void
                NFSPROC_NULL(void) = 0;
 
-               attrstat 
+               attrstat
                NFSPROC_GETATTR(nfs_fh) =       1;
 
-               attrstat 
+               attrstat
                NFSPROC_SETATTR(sattrargs) = 2;
 
-               void 
+               void
                NFSPROC_ROOT(void) = 3;
 
-               diropres 
+               diropres
                NFSPROC_LOOKUP(diropargs) = 4;
 
-               readlinkres 
+               readlinkres
                NFSPROC_READLINK(nfs_fh) = 5;
 
-               readres 
+               readres
                NFSPROC_READ(readargs) = 6;
 
-               void 
+               void
                NFSPROC_WRITECACHE(void) = 7;
 
                attrstat
@@ -352,4 +352,3 @@ program NFS_PROGRAM {
                NFSPROC_STATFS(nfs_fh) = 17;
        } = 2;
 } = 100003;
-
index 6063fdd28a570069f8b0492c5df301ab670054ba..949d9f074740c139be2b71c5a758049a98d7045a 100644 (file)
@@ -8,23 +8,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -43,7 +43,7 @@ typedef string rexstring<1024>;
 const SIGINT = 2;      /* interrupt */
 
 /*
- * Values for rst_flags, below 
+ * Values for rst_flags, below
  */
 const REX_INTERACTIVE = 1;     /* interactive mode */
 
@@ -148,7 +148,7 @@ struct tchars {
        /* chars[2] == start output char */
        /* chars[3] == stop output char */
        /* chars[4] == end-of-file char */
-       /* chars[5] == input delimeter (like nl) */
+       /* chars[5] == input delimiter (like nl) */
 };
 
 struct ltchars {
@@ -199,7 +199,7 @@ program REXPROG {
                /*
                 * Start remote execution
                 */
-               rex_result 
+               rex_result
                REXPROC_START(rex_start) = 1;
 
                /*
index 86fca74f8769e0dafa2e9610a4c4c3a58ec59569..fdd1890e200905f0afbf4d3c7a083add678f4e53 100644 (file)
@@ -5,23 +5,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -96,7 +96,7 @@ program RUSERSPROG {
 %
 %/*
 % * This is the structure used in version 2 of the rusersd RPC service.
-% * It corresponds to the utmp structure for BSD sytems.
+% * It corresponds to the utmp structure for BSD systems.
 % */
 %struct ru_utmp {
 %      char    ut_line[8];             /* tty name */
@@ -164,7 +164,7 @@ program RUSERSPROG {
 %      XDR *xdrs;
 %      struct ru_utmp **objpp;
 %{
-%      if (!xdr_reference(xdrs, (char **) objpp, sizeof (struct ru_utmp), 
+%      if (!xdr_reference(xdrs, (char **) objpp, sizeof (struct ru_utmp),
 %                         xdr_utmp)) {
 %              return (FALSE);
 %      }
@@ -202,7 +202,7 @@ program RUSERSPROG {
 %      XDR *xdrs;
 %      struct utmpidle **objpp;
 %{
-%      if (!xdr_reference(xdrs, (char **) objpp, sizeof (struct utmpidle), 
+%      if (!xdr_reference(xdrs, (char **) objpp, sizeof (struct utmpidle),
 %                         xdr_utmpidle)) {
 %              return (FALSE);
 %      }
index 2817ebfda3b47761e9387b0f033e34e45b43454d..06c8f06e30beabacde7c8bdf0eee7c84b64697f9 100644 (file)
@@ -8,23 +8,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -37,7 +37,7 @@
  */
 
 
-program SM_PROG { 
+program SM_PROG {
        version SM_VERS  {
                /* res_stat = stat_succ if status monitor agrees to monitor */
                /* res_stat = stat_fail if status monitor cannot monitor */
@@ -67,7 +67,7 @@ struct sm_name {
 };
 
 struct my_id {
-       string   my_name<SM_MAXSTRLEN>;         /* name of the site iniates the monitoring request*/
+       string   my_name<SM_MAXSTRLEN>;         /* name of the site iniating the monitoring request*/
        int     my_prog;                        /* rpc program # of the requesting process */
        int     my_vers;                        /* rpc version # of the requesting process */
        int     my_proc;                        /* rpc procedure # of the requesting process */
@@ -86,7 +86,7 @@ struct mon{
 
 
 /*
- * state # of status monitor monitonically increases each time
+ * state # of status monitor monotonically increases each time
  * status of the site changes:
  * an even number (>= 0) indicates the site is down and
  * an odd number (> 0) indicates the site is up;
@@ -105,7 +105,7 @@ struct sm_stat_res {
        int state;
 };
 
-/* 
+/*
  * structure of the status message sent back by the status monitor
  * when monitor site status changes
  */
index 5995c25bfd13d7ca067462e8c200ae22fd087f0b..fcd7b36db448447d7a3617ebe542e434b30cac7c 100644 (file)
@@ -64,7 +64,7 @@ static SVCXPRT *xports[NOFILE];
  * The services list
  * Each entry represents a set of procedures (an rpc program).
  * The dispatch routine takes request structs and runs the
- * apropriate procedure.
+ * appropriate procedure.
  */
 static struct svc_callout {
        struct svc_callout *sc_next;
index ab7ab694219fe24be35060d9372b1c9bd54fd653..b650de9beaa408911c10f7fe9f3ff0f344d71610 100644 (file)
@@ -8,11 +8,11 @@ static char sccsid[] = "@(#)svc_auth.c        2.1 88/08/07 4.0 RPCSRC; from 1.19 87/08/
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
@@ -40,16 +40,16 @@ static char sccsid[] = "@(#)svc_auth.c      2.1 88/08/07 4.0 RPCSRC; from 1.19 87/08/
 #include <rpc/rpc.h>
 
 /*
- * svcauthsw is the bdevsw of server side authentication. 
- * 
+ * svcauthsw is the bdevsw of server side authentication.
+ *
  * Server side authenticators are called from authenticate by
  * using the client auth struct flavor field to index into svcauthsw.
- * The server auth flavors must implement a routine that looks  
- * like: 
- * 
+ * The server auth flavors must implement a routine that looks
+ * like:
+ *
  *     enum auth_stat
  *     flavorx_auth(rqst, msg)
- *             register struct svc_req *rqst; 
+ *             register struct svc_req *rqst;
  *             register struct rpc_msg *msg;
  *
  */
@@ -76,7 +76,7 @@ static struct {
  * set rqst->rq_xprt->verf to the appropriate response verifier;
  * sets rqst->rq_client_cred to the "cooked" form of the credentials.
  *
- * NB: rqst->rq_cxprt->verf must be pre-alloctaed;
+ * NB: rqst->rq_cxprt->verf must be pre-allocated;
  * its length is set appropriately.
  *
  * The caller still owns and is responsible for msg->u.cmb.cred and
index 1170ecec83f2dc828dd1b7e93e1587da5821665c..1b6cb3bf8a055f658f47977f0b17f5c81e86a8b4 100644 (file)
@@ -6,23 +6,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -34,8 +34,8 @@ static char sccsid[] = "@(#)svc_raw.c 1.15 87/08/11 Copyr 1984 Sun Micro";
 /*
  * svc_raw.c,   This a toy for simple testing and timing.
  * Interface to create an rpc client and server in the same UNIX process.
- * This lets us similate rpc and get rpc (round trip) overhead, without
- * any interference from the kernal.
+ * This lets us simulate rpc and get rpc (round trip) overhead, without
+ * any interference from the kernel.
  *
  * Copyright (C) 1984, Sun Microsystems, Inc.
  */
@@ -149,7 +149,7 @@ svcraw_freeargs(xprt, xdr_args, args_ptr)
        SVCXPRT *xprt;
        xdrproc_t xdr_args;
        caddr_t args_ptr;
-{ 
+{
        register struct svcraw_private *srp = svcraw_private;
        register XDR *xdrs;
 
@@ -158,7 +158,7 @@ svcraw_freeargs(xprt, xdr_args, args_ptr)
        xdrs = &srp->xdr_stream;
        xdrs->x_op = XDR_FREE;
        return ((*xdr_args)(xdrs, args_ptr));
-} 
+}
 
 static void
 svcraw_destroy()
index 6846f38409a72feea9564d7bb160410fadcba248..2555e32be552d7aa05f4b81bf16f9f4ba5554f70 100644 (file)
@@ -37,7 +37,7 @@ static char sccsid[] = "@(#)svc_tcp.c 1.21 87/08/11 Copyr 1984 Sun Micro";
  * Copyright (C) 1984, Sun Microsystems, Inc.
  *
  * Actually implements two flavors of transporter -
- * a tcp rendezvouser (a listner and connection establisher)
+ * a tcp rendezvouser (a listener and connection establisher)
  * and a record/tcp stream.
  */
 
@@ -215,7 +215,7 @@ makefd_xprt(fd, sendsize, recvsize)
        xprt->xp_p1 = (caddr_t)cd;
        xprt->xp_verf.oa_base = cd->verf_body;
        xprt->xp_addrlen = 0;
-       xprt->xp_ops = &svctcp_op;  /* truely deals with calls */
+       xprt->xp_ops = &svctcp_op;  /* truly deals with calls */
        xprt->xp_port = 0;  /* this is a connection, not a rendezvouser */
        xprt->xp_sock = fd;
        xprt_register(xprt);
@@ -283,7 +283,7 @@ svctcp_destroy(xprt)
 static struct timeval wait_per_try = { 35, 0 };
 
 /*
- * reads data from the tcp conection.
+ * reads data from the tcp connection.
  * any error is fatal and the connection is closed.
  * (And a read of zero bytes is a half closed stream => error.)
  */
index 99a47bf42c928062dd6ebf8cc81aae4b354849b7..c36afd983ca8bc7b16f2bf1c7da5e7c907fdf94d 100644 (file)
@@ -496,7 +496,7 @@ xdr_netobj(xdrs, np)
 }
 
 /*
- * XDR a descriminated union
+ * XDR a discriminated union
  * Support routine for discriminated unions.
  * You create an array of xdrdiscrim structures, terminated with
  * an entry with a null procedure pointer.  The routine gets
index 7c2831ccd2291d7edddd2a1cc7ad3e1e4d5d1441..6b2adb2331133716bc13d09bcf02716938e52e06 100644 (file)
@@ -6,23 +6,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -32,7 +32,7 @@ static char sccsid[] = "@(#)xdr_array.c 1.10 87/08/11 Copyr 1984 Sun Micro";
 #endif
 
 /*
- * xdr_array.c, Generic XDR routines impelmentation.
+ * xdr_array.c, Generic XDR routines implementation.
  *
  * Copyright (C) 1984, Sun Microsystems, Inc.
  *
@@ -91,7 +91,7 @@ xdr_array(xdrs, addrp, sizep, maxsize, elsize, elproc)
                                return (TRUE);
                        *addrp = target = mem_alloc(nodesize);
                        if (target == NULL) {
-                               (void) fprintf(stderr, 
+                               (void) fprintf(stderr,
                                        "xdr_array: out of memory\n");
                                return (FALSE);
                        }
@@ -101,7 +101,7 @@ xdr_array(xdrs, addrp, sizep, maxsize, elsize, elproc)
                case XDR_FREE:
                        return (TRUE);
        }
-       
+
        /*
         * now we xdr each element of array
         */
@@ -136,7 +136,7 @@ xdr_vector(xdrs, basep, nelem, elemsize, xdr_elem)
        register char *basep;
        register u_int nelem;
        register u_int elemsize;
-       register xdrproc_t xdr_elem;    
+       register xdrproc_t xdr_elem;
 {
        register u_int i;
        register char *elptr;
@@ -148,6 +148,5 @@ xdr_vector(xdrs, basep, nelem, elemsize, xdr_elem)
                }
                elptr += elemsize;
        }
-       return(TRUE);   
+       return(TRUE);
 }
-
index 4e322eccf1939e8c6b0d56dad26b6bea18d5a6b9..be5a07d028061a44747691b23b406270bf339415 100644 (file)
@@ -32,7 +32,7 @@ static char sccsid[] = "@(#)xdr_float.c 1.12 87/08/11 Copyr 1984 Sun Micro";
 #endif
 
 /*
- * xdr_float.c, Generic XDR routines impelmentation.
+ * xdr_float.c, Generic XDR routines implementation.
  *
  * Copyright (C) 1984, Sun Microsystems, Inc.
  *
index 974e8295dd0da09449bf71b2dc3e6d335e6e25f9..6b33208d76a9df29d8e58acc8da23c271ee7d3d3 100644 (file)
@@ -6,23 +6,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -44,7 +44,7 @@ static char sccsid[] = "@(#)xdr_rec.c 1.21 87/08/11 Copyr 1984 Sun Micro";
  * by n bytes of data, where n is contained in the header.  The header
  * is represented as a htonl(u_long).  The high order bit encodes
  * whether or not the fragment is the last fragment of the record
- * (1 => fragment is last, 0 => more fragments to follow. 
+ * (1 => fragment is last, 0 => more fragments to follow.
  * The other 31 bits encode the byte length of the fragment.
  */
 
@@ -96,7 +96,7 @@ typedef struct rec_strm {
        caddr_t tcp_handle;
        caddr_t the_buffer;
        /*
-        * out-goung bits
+        * out-going bits
         */
        int (*writeit)();
        caddr_t out_base;       /* output buffer (points to frag header) */
@@ -142,8 +142,8 @@ xdrrec_create(xdrs, sendsize, recvsize, tcp_handle, readit, writeit)
 
        if (rstrm == NULL) {
                (void)fprintf(stderr, "xdrrec_create: out of memory\n");
-               /* 
-                *  This is bad.  Should rework xdrrec_create to 
+               /*
+                *  This is bad.  Should rework xdrrec_create to
                 *  return a handle, and in this case return NULL
                 */
                return;
@@ -184,7 +184,7 @@ xdrrec_create(xdrs, sendsize, recvsize, tcp_handle, readit, writeit)
 
 
 /*
- * The reoutines defined below are the xdr ops which will go into the
+ * The routines defined below are the xdr ops which will go into the
  * xdr handle filled in by xdrrec_create.
  */
 
@@ -258,7 +258,7 @@ xdrrec_getbytes(xdrs, addr, len)
                current = (len < current) ? len : current;
                if (! get_input_bytes(rstrm, addr, current))
                        return FALSE;
-               addr += current; 
+               addr += current;
                rstrm->fbtbc -= current;
                len -= current;
        }
@@ -420,8 +420,8 @@ xdrrec_skiprecord(xdrs)
 }
 
 /*
- * Look ahead fuction.
- * Returns TRUE iff there is no more input in the buffer 
+ * Lookahead function.
+ * Returns TRUE iff there is no more input in the buffer
  * after consuming the rest of the current record.
  */
 bool_t
@@ -444,9 +444,9 @@ xdrrec_eof(xdrs)
 
 /*
  * The client must tell the package when an end-of-record has occurred.
- * The second paraemters tells whether the record should be flushed to the
- * (output) tcp stream.  (This let's the package support batched or
- * pipelined procedure calls.)  TRUE => immmediate flush to tcp connection.
+ * The second parameter tells whether the record should be flushed to the
+ * (output) tcp stream.  (This lets the package support batched or
+ * pipelined procedure calls.)  TRUE => immediate flush to tcp connection.
  */
 bool_t
 xdrrec_endofrecord(xdrs, sendnow)
index 32d91d9999e479d8b685c874900685014d18c3db..f4ad74df3e73c66609d4429277370f2b2c52d17e 100644 (file)
@@ -6,23 +6,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -32,7 +32,7 @@ static char sccsid[] = "@(#)xdr_reference.c 1.11 87/08/11 SMI";
 #endif
 
 /*
- * xdr_reference.c, Generic XDR routines impelmentation.
+ * xdr_reference.c, Generic XDR routines implementation.
  *
  * Copyright (C) 1987, Sun Microsystems, Inc.
  *
@@ -52,7 +52,7 @@ static char sccsid[] = "@(#)xdr_reference.c 1.11 87/08/11 SMI";
  * referenced by a pointer inside the structure that is currently being
  * translated.  pp references a pointer to storage. If *pp is null
  * the  necessary storage is allocated.
- * size is the sizeof the referneced structure.
+ * size is the size of the referneced structure.
  * proc is the routine to handle the referenced structure.
  */
 bool_t
@@ -95,7 +95,7 @@ xdr_reference(xdrs, pp, size, proc)
  * xdr_pointer():
  *
  * XDR a pointer to a possibly recursive data structure. This
- * differs with xdr_reference in that it can serialize/deserialiaze
+ * differs with xdr_reference in that it can serialize/deserialize
  * trees correctly.
  *
  *  What's sent is actually a union:
index 151e5e48e4f032857d582f3e644eca367ddb51f4..351b8f94b4e109d4345f34e71b75992a0f8998be 100644 (file)
@@ -6,23 +6,23 @@
  * may copy or modify Sun RPC without charge, but are not authorized
  * to license or distribute it to anyone else except as part of a product or
  * program developed by the user.
- * 
+ *
  * SUN RPC IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING THE
  * WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
  * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- * 
+ *
  * Sun RPC is provided with no support and without any obligation on the
  * part of Sun Microsystems, Inc. to assist in its use, correction,
  * modification or enhancement.
- * 
+ *
  * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
  * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY SUN RPC
  * OR ANY PART THEREOF.
- * 
+ *
  * In no event will Sun Microsystems, Inc. be liable for any lost revenue
  * or profits or other special, indirect and consequential damages, even if
  * Sun has been advised of the possibility of such damages.
- * 
+ *
  * Sun Microsystems, Inc.
  * 2550 Garcia Avenue
  * Mountain View, California  94043
@@ -58,8 +58,8 @@ static void   xdrstdio_destroy();
  * Ops vector for stdio type XDR
  */
 static struct xdr_ops  xdrstdio_ops = {
-       xdrstdio_getlong,       /* deseraialize a long int */
-       xdrstdio_putlong,       /* seraialize a long int */
+       xdrstdio_getlong,       /* deserialize a long int */
+       xdrstdio_putlong,       /* serialize a long int */
        xdrstdio_getbytes,      /* deserialize counted bytes */
        xdrstdio_putbytes,      /* serialize counted bytes */
        xdrstdio_getpos,        /* get offset in the stream */
@@ -158,10 +158,10 @@ xdrstdio_getpos(xdrs)
 }
 
 static bool_t
-xdrstdio_setpos(xdrs, pos) 
+xdrstdio_setpos(xdrs, pos)
        XDR *xdrs;
        u_int pos;
-{ 
+{
 
        return ((fseek((FILE *)xdrs->x_private, (long)pos, 0) < 0) ?
                FALSE : TRUE);
index 1c71ec8ab21e91db1e70191a3331d0281131f10e..78c5071b4ef52e939d0f60e4f9b99097329bd7d6 100644 (file)
@@ -211,7 +211,7 @@ _dl_start_user:
        stq     $2, 0($sp)
        /* Load _dl_default_scope[2] into s1 to pass to _dl_init_next.  */
 0:     ldq     $10, _dl_default_scope+16
-       /* Call _dl_init_next to return the address of an initalizer
+       /* Call _dl_init_next to return the address of an initializer
           function to run.  */
 1:     mov     $10, $16
        jsr     $26, _dl_init_next
index f75673e35f509a63906a72265d9eb1738b0c112d..e6147c2ec386be20add223a7879d0f12cff719b3 100644 (file)
@@ -55,7 +55,7 @@ __DTOR_LIST__:
        jsr     $26,__do_global_dtors_aux
 
        /* Must match the alignment we got from crti.o else we get
-         zero-filled holes in our _fini function and thense SIGILL.  */
+         zero-filled holes in our _fini function and then SIGILL.  */
        .align 3
 
 /*
index 02f37f50be4fe2a7856eb8a7a9fc33fbf69ea535..d3099cc5993482e3cd87fc12b191072a8dca1662 100644 (file)
@@ -17,7 +17,7 @@ License along with the GNU C Library; see the file COPYING.LIB.  If
 not, write to the Free Software Foundation, Inc., 675 Mass Ave,
 Cambridge, MA 02139, USA.  */
 
-/* Return the address of the last occurrance of a given character
+/* Return the address of the last occurrence of a given character
    within a null-terminated string, or null if it is not found.
 
    This is generally scheduled for the EV5 (got to look out for my own
index ab1c6faaab5f36ebc7148a4b62b36c7a13d62244..4a11b25752b754be3f54eff103c61dafc2a61639 100644 (file)
@@ -1,22 +1,22 @@
-/* crypt - wrapper aroung MD5 sum replacement for crypt function.
-Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
+/* Wrapper around MD5 sum replacement for crypt function.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <crypt.h>
 #include <errno.h>
@@ -25,7 +25,7 @@ Boston, MA 02111-1307, USA.  */
 
 /* Define our magic string to mark salt for MD5 encryption
    replacement.  This is meant to be the same as for other MD5 based
-   encryption implenentations.  */
+   encryption implementations.  */
 static const char md5_salt_prefix[] = "$1$";
 
 
index 6fdd40d4ac91c94a67a5b9db7a141e560cdc2000..53224596ea6520d062e60609fbcc43043b7dac44 100644 (file)
@@ -36,7 +36,7 @@ struct crypt_data
   char sb1[32768 / sizeof (char)];
   char sb2[32768 / sizeof (char)];
   char sb3[32768 / sizeof (char)];
-  /* end-of-aligment-critical-data */
+  /* end-of-alignment-critical-data */
   char crypt_3_buf[14];
   char current_salt[2];
   long current_saltbits;
index 01b4edcf2aa96d35951e68d151a77a1a3794252b..60276e9942f159fdc2bb4dd008e04e234c62939f 100644 (file)
@@ -1,24 +1,24 @@
-/* Copyright (C) 1991, 1993 Free Software Foundation, Inc.
-   Based on strlen implemention by Torbjorn Granlund (tege@sics.se),
+/* Copyright (C) 1991, 1993, 1996 Free Software Foundation, Inc.
+   Based on strlen implementation by Torbjorn Granlund (tege@sics.se),
    with help from Dan Sahlin (dan@sics.se) and
    commentary by Jim Blandy (jimb@ai.mit.edu);
    adaptation to memchr suggested by Dick Karpinski (dick@cca.ucsf.edu),
    and implemented by Roland McGrath (roland@ai.mit.edu).
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifdef HAVE_CONFIG_H
 #include <config.h>
index 8ef6f04cbe6b7b78ff1e04a428b433a85620c27a..fa9cb2a1a470039eb996264dd34316423827f12c 100644 (file)
@@ -1,22 +1,22 @@
 /* memmove -- copy memory to memory until the specified number of bytes
    has been copied.  Overlap is handled correctly.
-   Copyright (C) 1991, 1995 Free Software Foundation, Inc.
+   Copyright (C) 1991, 1995, 1996 Free Software Foundation, Inc.
    Contributed by Torbjorn Granlund (tege@sics.se).
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <ansidecl.h>
 #include <string.h>
@@ -63,7 +63,7 @@ DEFUN(memmove, (a1, a2, len),
 
          /* Copy from SRCP to DSTP taking advantage of the known
             alignment of DSTP.  Number of bytes remaining is put
-            in the third argumnet, i.e. in LEN.  This number may
+            in the third argument, i.e. in LEN.  This number may
             vary from machine to machine.  */
 
          WORD_COPY_FWD (dstp, srcp, len, len);
@@ -89,7 +89,7 @@ DEFUN(memmove, (a1, a2, len),
 
          /* Copy from SRCP to DSTP taking advantage of the known
             alignment of DSTP.  Number of bytes remaining is put
-            in the third argumnet, i.e. in LEN.  This number may
+            in the third argument, i.e. in LEN.  This number may
             vary from machine to machine.  */
 
          WORD_COPY_BWD (dstp, srcp, len, len);
index 82e1a90334d8a4aef58339bcf7c41c78253299e3..7fe63d3340ac12685128c493957b8ef1bedf032c 100644 (file)
@@ -1,26 +1,26 @@
-/* Copyright (C) 1991, 1992, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1991, 1992, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <string.h>
 #include <ctype.h>
 
 /* Compare S1 and S2, ignoring case, returning less than, equal to or
-   greater than zero if S1 is lexiographically less than,
+   greater than zero if S1 is lexicographically less than,
    equal to or greater than S2.  */
 int
 __strcasecmp (const char *s1, const char *s2)
index b9c8393f8ec14f4af14e97560801145dd12688db..11c7bdff640ecab9d84b41324c70cbfa0f429290 100644 (file)
@@ -1,30 +1,30 @@
-/* Copyright (C) 1991, 1993, 1994, 1995 Free Software Foundation, Inc.
-   Based on strlen implemention by Torbjorn Granlund (tege@sics.se),
+/* Copyright (C) 1991, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+   Based on strlen implementation by Torbjorn Granlund (tege@sics.se),
    with help from Dan Sahlin (dan@sics.se) and
    bug fix and commentary by Jim Blandy (jimb@ai.mit.edu);
    adaptation to strchr suggested by Dick Karpinski (dick@cca.ucsf.edu),
    and implemented by Roland McGrath (roland@ai.mit.edu).
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <ansidecl.h>
 #include <string.h>
 
 
-/* Find the first ocurrence of C in S.  */
+/* Find the first occurrence of C in S.  */
 
 char *
 DEFUN(strchr, (s, c), CONST char *s AND int c)
@@ -53,9 +53,9 @@ DEFUN(strchr, (s, c), CONST char *s AND int c)
   /* Bits 31, 24, 16, and 8 of this number are zero.  Call these bits
      the "holes."  Note that there is a hole just to the left of
      each byte, with an extra at the end:
-     
+
      bits:  01111110 11111110 11111110 11111111
-     bytes: AAAAAAAA BBBBBBBB CCCCCCCC DDDDDDDD 
+     bytes: AAAAAAAA BBBBBBBB CCCCCCCC DDDDDDDD
 
      The 1-bits make sure that carries propagate to the next 0-bit.
      The 0-bits provide holes for carries to fall into.  */
@@ -118,10 +118,10 @@ DEFUN(strchr, (s, c), CONST char *s AND int c)
 
       /* Add MAGIC_BITS to LONGWORD.  */
       if ((((longword + magic_bits)
-       
+
            /* Set those bits that were unchanged by the addition.  */
            ^ ~longword)
-              
+
           /* Look at only the hole bits.  If any of the hole bits
              are unchanged, most likely one of the bytes was a
              zero.  */
index ec0c1e6b0063c7ae0da705023c45c44815ae89a9..a8d9db1bc9d2c96088c9107a0fabff07dbdf1647 100644 (file)
@@ -1,33 +1,34 @@
-/* Copyright (C) 1991 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1991, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
-#include <ansidecl.h>
 #include <string.h>
 #include <memcopy.h>
 
 /* Compare S1 and S2, returning less than, equal to or
-   greater than zero if S1 is lexiographically less than,
+   greater than zero if S1 is lexicographically less than,
    equal to or greater than S2.  */
 int
-DEFUN(strcmp, (p1, p2), CONST char *p1 AND CONST char *p2)
+strcmp (p1, p2)
+     const char *p1;
+     const char *p2;
 {
-  register CONST unsigned char *s1 = (CONST unsigned char *) p1;
-  register CONST unsigned char *s2 = (CONST unsigned char *) p2;
+  register const unsigned char *s1 = (const unsigned char *) p1;
+  register const unsigned char *s2 = (const unsigned char *) p2;
   unsigned reg_char c1, c2;
 
   do
index 915faa77c046a28d2ca5b853787ce779528caec4..0cacfffd31431b2a11293d479b14044237f67d85 100644 (file)
@@ -1,25 +1,24 @@
-/* Copyright (C) 1991, 1994 Free Software Foundation, Inc.
+/* Copyright (C) 1991, 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-This file is part of the GNU C Library.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <string.h>
 
-/* Return the length of the maximum inital segment of S
+/* Return the length of the maximum initial segment of S
    which contains no characters from REJECT.  */
 size_t
 strcspn (s, reject)
index 623d9c5714a657461b04130b7539acecffb96dd2..eea64389f8547eee119977b47d87e78333fb199e 100644 (file)
@@ -1,32 +1,33 @@
-/* Copyright (C) 1991 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1991, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
-#include <ansidecl.h>
 #include <string.h>
 #include <memcopy.h>
 
 /* Compare no more than N characters of S1 and S2,
    returning less than, equal to or greater than zero
-   if S1 is lexiographically less than, equal to or
+   if S1 is lexicographically less than, equal to or
    greater than S2.  */
 int
-DEFUN(strncmp, (s1, s2, n),
-      CONST char *s1 AND CONST char *s2 AND size_t n)
+strncmp (s1, s2, n)
+     const char *s1;
+     const char *s2;
+     size_t n;
 {
   unsigned reg_char c1 = '\0';
   unsigned reg_char c2 = '\0';
index 73339ba76295fa1cb3b7b19ed486c52c3ebb5a71..75b2ed1440c7e1be7ba4ae8f5f22474cd9973dea 100644 (file)
@@ -1,29 +1,29 @@
-/* Copyright (C) 1991, 1994 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1991, 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
-#include <ansidecl.h>
 #include <string.h>
 
 
-/* Find the first ocurrence in S of any character in ACCEPT.  */
+/* Find the first occurrence in S of any character in ACCEPT.  */
 char *
-DEFUN(strpbrk, (s, accept),
-      register CONST char *s AND register CONST char *accept)
+strpbrk (s, accept)
+     const char *s;
+     const char *accept;
 {
   while (*s != '\0')
     {
index 663b6aa753bfc9ffdeba0bd3e63f6ef01ba378ac..db5549b922996b315b33aeb1fa3074b4d6d199af 100644 (file)
@@ -1,24 +1,24 @@
-/* Copyright (C) 1991, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1991, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <string.h>
 
-/* Find the last ocurrence of C in S.  */
+/* Find the last occurrence of C in S.  */
 char *
 strrchr (const char *s, int c)
 {
index 9c0e8183b563e042d3edabe08cdcd8b88c35313a..d8d0b84813b6cd70e1ecc16606982f15d93f104b 100644 (file)
@@ -1,20 +1,20 @@
-/* Copyright (C) 1994 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /*
  * My personal strstr() implementation that beats most other algorithms.
@@ -60,7 +60,7 @@ strstr (phaystack, pneedle)
       goto jin;
 
       for (;;)
-        { 
+        {
           register chartype a;
          register const unsigned char *rhaystack, *rneedle;
 
@@ -104,7 +104,7 @@ jin:          a = *++haystack;
              }
            while (*rhaystack == a);
 
-         needle = rneedle;                /* took the register-poor aproach */
+         needle = rneedle;             /* took the register-poor approach */
 
          if (a == '\0')
            break;
index 4f96864abc8a9ee2faf2754f7253c63d0f5be0ae..700b69f58fe300e4b51103686ae04c602bbb4331 100644 (file)
@@ -25,7 +25,7 @@ TRANS No process matches the specified process ID. */
 #endif
 #ifdef EINTR
 /*
-TRANS Interrupted function call; an asynchronous signal occured and prevented
+TRANS Interrupted function call; an asynchronous signal occurred and prevented
 TRANS completion of the call.  When this happens, you should try the call
 TRANS again.
 TRANS 
index f705f420c4d875d91892c68b57acbee1099a8bf1..9bac145ad44a328d0e302b743b322c05f03baf4f 100644 (file)
@@ -1,24 +1,24 @@
 /* strcat(dest, src) -- Append SRC on the end of DEST.
-For Intel 80x86, x>=4.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@ipd.info.uni-karlsruhe.de>.
-Optimised a little by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=4.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@ipd.info.uni-karlsruhe.de>.
+   Optimised a little by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -82,7 +82,7 @@ L1:   movl (%edx), %eax       /* get word (= 4 bytes) in question */
           following XOR would destroy the carry flag and it would (in a
           representation with more than 32 bits) not alter then last
           overflow, we can now test this condition.  If no carry is signaled
-          no overflow must have occured in the last byte => it was 0.  */
+          no overflow must have occurred in the last byte => it was 0. */
        jnc L3
 
        /* We are only interested in carry bits that change due to the
index b298983563188b5b41cba4fc9bae7cd879a2cf8d..bf9b223a0b67e97311e55e600ef4261d8a553623 100644 (file)
@@ -1,23 +1,21 @@
-/* Pentium optimized __mpn_lshift -- 
+/* Pentium optimized __mpn_lshift --
+   Copyright (C) 1992, 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-Copyright (C) 1992, 1994, 1995 Free Software Foundation, Inc.
+   The GNU C Library is free software; you can redistribute it and/or modify
+   it under the terms of the GNU Library General Public License as published by
+   the Free Software Foundation; either version 2 of the License, or (at your
+   option) any later version.
 
-This file is part of the GNU MP Library.
+   The GNU C Library is distributed in the hope that it will be useful, but
+   WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
+   License for more details.
 
-The GNU MP Library is free software; you can redistribute it and/or modify
-it under the terms of the GNU Library General Public License as published by
-the Free Software Foundation; either version 2 of the License, or (at your
-option) any later version.
-
-The GNU MP Library is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
-License for more details.
-
-You should have received a copy of the GNU Library General Public License
-along with the GNU MP Library; see the file COPYING.LIB.  If not, write to
-the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
-MA 02111-1307, USA. */
+   You should have received a copy of the GNU Library General Public License
+   along with the GNU MP Library; see the file COPYING.LIB.  If not, write to
+   the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
+   MA 02111-1307, USA. */
 
 /*
   INPUT PARAMETERS
@@ -132,7 +130,7 @@ Lend2:      shll    %cl,%edx                /* compute least significant limb */
        ret
 
 /* We loop from least significant end of the arrays, which is only
-   permissable if the source and destination don't overlap, since the
+   permissible if the source and destination don't overlap, since the
    function is documented to work for overlapping source and destination.
 */
 
index 38398edb13bf572913f3bf4efc965ae4c9ce882a..1860daf4d3af97f93abd13ba15da94cb8959a144 100644 (file)
@@ -1,6 +1,6 @@
-/* Pentium optimized __mpn_rshift -- 
+/* Pentium optimized __mpn_rshift --
 
-Copyright (C) 1992, 1994, 1995 Free Software Foundation, Inc.
+Copyright (C) 1992, 1994, 1995, 1996 Free Software Foundation, Inc.
 
 This file is part of the GNU MP Library.
 
@@ -129,7 +129,7 @@ Lend2:      shrl    %cl,%edx                /* compute most significant limb */
        ret
 
 /* We loop from least significant end of the arrays, which is only
-   permissable if the source and destination don't overlap, since the
+   permissible if the source and destination don't overlap, since the
    function is documented to work for overlapping source and destination.
 */
 
index 1477350480cd97539b3f886b271fca51b5a335d0..fda053216fed9981465216b093305896eeb4348d 100644 (file)
@@ -1,30 +1,30 @@
 /* strchr -- find character CH in a NUL terminated string.
-Highly optimized version for ix85, x>=5.
-Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   Highly optimized version for ix85, x>=5.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 
 /* This version is especially optimized for the i586 (and following?)
    processors.  This is mainly done by using the two pipelines.  The
    version optimized for i486 is weak in this aspect because to get
-   as much parallelism we have to executs some *more* instructions.
+   as much parallelism we have to execute some *more* instructions.
 
    The code below is structured to reflect the pairing of the instructions
    as *I think* it is.  I have no processor data book to verify this.
index ba24981f3d84a8cc409fd87bb331c1c22f83e55b..e8fb916812631979305d55d2a3929fc05383d0b6 100644 (file)
@@ -1,30 +1,30 @@
 /* strlen -- Compute length og NUL terminated string.
-Highly optimized version for ix86, x>=5.
-Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   Highly optimized version for ix86, x>=5.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 
 /* This version is especially optimized for the i586 (and following?)
    processors.  This is mainly done by using the two pipelines.  The
    version optimized for i486 is weak in this aspect because to get
-   as much parallelism we have to executs some *more* instructions.
+   as much parallelism we have to execute some *more* instructions.
 
    The code below is structured to reflect the pairing of the instructions
    as *I think* it is.  I have no processor data book to verify this.
index fcf873ebb881f3317901c2c9f818296fa360c769..f0fb3abe453f645beb5149116311732d74cb7ece 100644 (file)
@@ -1,34 +1,34 @@
 /* memchr (str, ch, n) -- Return pointer to first occurrence of CH in STR less
    than N.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-Optimised a little by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-This file is part of the GNU C Library.
-
-This version is developed using the same algorithm as the fast C
-version which carries the following introduction:
-
-Based on strlen implemention by Torbjorn Granlund (tege@sics.se),
-with help from Dan Sahlin (dan@sics.se) and
-commentary by Jim Blandy (jimb@ai.mit.edu);
-adaptation to memchr suggested by Dick Karpinski (dick@cca.ucsf.edu),
-and implemented by Roland McGrath (roland@ai.mit.edu).
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
+   Optimised a little by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+
+   This version is developed using the same algorithm as the fast C
+   version which carries the following introduction:
+
+   Based on strlen implementation by Torbjorn Granlund (tege@sics.se),
+   with help from Dan Sahlin (dan@sics.se) and
+   commentary by Jim Blandy (jimb@ai.mit.edu);
+   adaptation to memchr suggested by Dick Karpinski (dick@cca.ucsf.edu),
+   and implemented by Roland McGrath (roland@ai.mit.edu).
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -140,7 +140,7 @@ L1: movl (%eax), %ecx       /* get word (= 4 bytes) in question */
           following XOR would destroy the carry flag and it would (in a
           representation with more than 32 bits) not alter then last
           overflow, we can now test this condition.  If no carry is signaled
-          no overflow must have occured in the last byte => it was 0.  */
+          no overflow must have occurred in the last byte => it was 0. */
        jnc L8
 
        /* We are only interested in carry bits that change due to the
@@ -307,7 +307,7 @@ L8: testb %cl, %cl          /* test first byte in dword */
        jz L9                   /* if zero => return pointer */
        incl %eax               /* increment source pointer */
 
-       /* No further test needed we we known it is one of the four byytes.  */
+       /* No further test needed we we know it is one of the four bytes.  */
 
 L9:    popl %edi               /* pop saved registers */
        popl %esi
index 9df0e33d41191c954054bdf16f07bf5847966d76..73292ab0fbee8f2d5721225da22160fc2e583077 100644 (file)
@@ -1,24 +1,24 @@
 /* stpcpy -- copy SRC to DEST returning the address of the terminating '\0'
             in DEST.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper (drepper@gnu.ai.mit.edu).
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper (drepper@gnu.ai.mit.edu).
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* This function is defined neither in ANSI nor POSIX standards but is
    also not invented here.  */
@@ -53,7 +53,7 @@ ENTRY (__stpcpy)
        .long 0x00000004
 
        /* Four times unfolded loop with only one loop counter.  This
-          is achieved by the use of index+base adressing mode.  As the
+          is achieved by the use of index+base addressing mode.  As the
           loop counter we use the destination address because this is
           also the result.  */
 L1:    addl $4, %eax           /* increment loop counter */
index b76f6170e5984d955045444a7d479cf6c70d96a9..96878fb79adec228b6c7dbcf6f5333e9711f5b36 100644 (file)
@@ -1,28 +1,28 @@
 /* stpncpy -- copy no more then N bytes from SRC to DEST, returning the
              address of the terminating '\0' in DEST.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-Some bug fixes by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-  - original wrote n+1 chars in some cases.
-  - stpncpy() ought to behave like strncpy() ie. not null-terminate
-    if limited by n.  glibc-1.09 stpncpy() does this.
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
+   Some bug fixes by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+     - original wrote n+1 chars in some cases.
+     - stpncpy() ought to behave like strncpy() ie. not null-terminate
+       if limited by n.  glibc-1.09 stpncpy() does this.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -51,7 +51,7 @@ ENTRY (__stpncpy)
 
        /* Four times unfolded loop with two loop counters.  We get the
           the third value (the source address) by using the index+base
-          adressing mode.  */
+          addressing mode.  */
 L2:    movb (%eax,%esi), %dl   /* load current char */
        movb %dl, (%eax)        /* and store it */
        testb %dl, %dl          /* was it NUL? */
@@ -128,7 +128,7 @@ L7:
        jz L9                   /* counter is also 0 => exit */
 
        /* We now have to fill the rest of the buffer with NUL.  This
-          is done in a tricky way.  Please note that the adressing mode
+          is done in a tricky way.  Please note that the addressing mode
           used below is not the same we used above.  Here we use the
           %ecx register.  */
 L8:
index 1c91c40090e6af714bb3db379335c323f5e52091..e4e5c555720bb681fe83fbbdfeffc2849bf752e0 100644 (file)
@@ -1,24 +1,24 @@
 /* strchr (str, ch) -- Return pointer to first occurrence of CH in STR.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-Some optimisations by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
+   Some optimisations by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+  Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -53,7 +53,7 @@ ENTRY (strchr)
              we don't know the end of the string.  But accessing at
              4-byte alignment guarantees that we never access illegal
              memory if this would not also be done by the trivial
-             implementation (this is because all processor inherant
+             implementation (this is because all processor inherent
              boundaries are multiples of 4.  */
 
        testb $3, %eax          /* correctly aligned ? */
@@ -131,7 +131,7 @@ L11:        movl (%eax), %ecx       /* get word (= 4 bytes) in question */
           following XOR would destroy the carry flag and it would (in a
           representation with more than 32 bits) not alter then last
           overflow, we can now test this condition.  If no carry is signaled
-          no overflow must have occured in the last byte => it was 0.  */
+          no overflow must have occurred in the last byte => it was 0. */
        jnc L7
 
        /* We are only interested in carry bits that change due to the
index 387d4aea95840f03470f0cbc98b63f3b96e6d5a6..47b157a2eb24b822943acd603b4214eda04fbf8a 100644 (file)
@@ -1,25 +1,25 @@
-/* strcspn (str, ss) -- Return the length of the initial segement of STR
+/* strcspn (str, ss) -- Return the length of the initial segment of STR
                        which contains no characters from SS.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-Bug fixes by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
+   Bug fixes by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -142,7 +142,7 @@ L1: leal -4(%edx), %eax     /* prepare loop */
           1. a character in the stopset was found
           and
           2. the end of the string was found
-          But as a sign that the chracter is in the stopset we store its
+          But as a sign that the character is in the stopset we store its
           value in the table.  But the value of NUL is NUL so the loop
           terminates for NUL in every case.  */
 
index f47bf9473066a7b5f05229361aa6e08812adf32b..3786d3f6902e0aed4993fd335c29f3d3d591e60c 100644 (file)
@@ -1,24 +1,24 @@
 /* strrchr (str, ch) -- Return pointer to last occurrence of CH in STR.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-Some optimisations by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
+   Some optimisations by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -55,7 +55,7 @@ ENTRY (strrchr)
              we don't know the end of the string.  But accessing at
              4-byte alignment guarantees that we never access illegal
              memory if this would not also be done by the trivial
-             implementation (this is because all processor inherant
+             implementation (this is because all processor inherent
              boundaries are multiples of 4.  */
 
        testl $3, %esi          /* correctly aligned ? */
@@ -178,7 +178,7 @@ L19:        movl (%esi), %edx       /* get word (= 4 bytes) in question */
           following XOR would destroy the carry flag and it would (in a
           representation with more than 32 bits) not alter then last
           overflow, we can now test this condition.  If no carry is signaled
-          no overflow must have occured in the last byte => it was 0.  */
+          no overflow must have occurred in the last byte => it was 0. */
 
        jnc L20                 /* found NUL => check last word */
 
index 508aa7fd840ededb0bce504c680d58fa8aa97a8f..72e0e7d41ad7f2971cbb2f165bbdca7be7f64671 100644 (file)
@@ -1,25 +1,25 @@
-/* strcspn (str, ss) -- Return the length of the initial segement of STR
+/* strcspn (str, ss) -- Return the length of the initial segment of STR
                        which contains only characters from SS.
-For Intel 80x86, x>=3.
-Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-Bug fixes by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
-This file is part of the GNU C Library.
-
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   For Intel 80x86, x>=3.
+   Copyright (C) 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>
+   Bug fixes by Alan Modra <Alan@SPRI.Levels.UniSA.Edu.Au>
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <sysdep.h>
 #include "asm-syntax.h"
@@ -142,7 +142,7 @@ L1: leal -4(%edx), %eax     /* prepare loop */
           1. a character in the stopset was found
           and
           2. the end of the string was found
-          But as a sign that the chracter is in the stopset we store its
+          But as a sign that the character is in the stopset we store its
           value in the table.  But the value of NUL is NUL so the loop
           terminates for NUL in every case.  */
 
index 3255ee6b1c30cb82b2824b0525875fbe1c66da34..9e6efe49738c4ba5e144305b954e288333e680a0 100644 (file)
@@ -1,20 +1,20 @@
 /* Copyright (C) 1992, 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <endian.h>
 
@@ -88,11 +88,11 @@ union ieee754_double
        unsigned int negative:1;
        unsigned int exponent:11;
        unsigned int quiet_nan:1;
-       /* Together these conprise the mantissa.  */
+       /* Together these comprise the mantissa.  */
        unsigned int mantissa0:19;
        unsigned int mantissa1:32;
 #else
-       /* Together these conprise the mantissa.  */
+       /* Together these comprise the mantissa.  */
        unsigned int mantissa1:32;
        unsigned int mantissa0:19;
        unsigned int quiet_nan:1;
index dad201fb3fdbeb297c69b2fcaaac6f5cf3cff9ab..01c254ab51861ab4b3184f37bb43e20b5bffac73 100644 (file)
@@ -30,6 +30,7 @@ ENTRY(__ieee754_exp)
        fld1
        faddp                           /* 2^(fract(x * log2(e))) */
        fscale                          /* e^x */
+       fstp    %st(1)
        ret
 
 .LisInf:
index 2884efa6ce116e2b8abbd007276f97bced79e702..fc4a1832cad2d00ff73cf58fd7953eece5451585 100644 (file)
@@ -32,6 +32,7 @@ ENTRY(__ieee754_expl)
        fld1
        faddp                           /* 2^(fract(x * log2(e))) */
        fscale                          /* e^x */
+       fstp    %st(1)
        ret
 
 .LisInf:
index a500b07d31b14f7d145d6be58c1028e83b57fd1d..5135c90e40a0e2da378d16e4d4a0b7515a33701d 100644 (file)
@@ -21,7 +21,7 @@ ENTRY(__ceil)
        orl     $0x0800,%edx            /* round towards +oo */
        andl    $0xfbff,%edx
        movl    %edx,-8(%ebp)
-       fldcw   -8(%ebp)                /* load modfied control word */
+       fldcw   -8(%ebp)                /* load modified control word */
 
        fldl    8(%ebp);                /* round */
        frndint
index 4789b014d8a311ad53414d4c130a38baa9bfc666..93cf40bd43cb4ebb41b45a07eee1dd939ac44ad7 100644 (file)
@@ -21,7 +21,7 @@ ENTRY(__ceilf)
        orl     $0x0800,%edx            /* round towards +oo */
        andl    $0xfbff,%edx
        movl    %edx,-8(%ebp)
-       fldcw   -8(%ebp)                /* load modfied control word */
+       fldcw   -8(%ebp)                /* load modified control word */
 
        flds    8(%ebp);                /* round */
        frndint
index a02a54768d1679dc11e2622e527e13cc2f2eb0da..a77e550d7be40c1f3c04304501dbea498b8394ef 100644 (file)
@@ -22,7 +22,7 @@ ENTRY(__ceill)
        orl     $0x0800,%edx            /* round towards +oo */
        andl    $0xfbff,%edx
        movl    %edx,-8(%ebp)
-       fldcw   -8(%ebp)                /* load modfied control word */
+       fldcw   -8(%ebp)                /* load modified control word */
 
        fldt    8(%ebp);                /* round */
        frndint
index 7599303f3d7f6ea1a29724383ca14c2a0493202e..ca8914ee1424d4e6cef5067502a2c32e2e78d539 100644 (file)
@@ -17,7 +17,7 @@ ENTRY(__floor)
        orw     $0x0400,%dx             /* round towards -oo */
        andw    $0xf7ff,%dx
        movw    %dx,-8(%ebp)
-       fldcw   -8(%ebp)                /* load modfied control word */
+       fldcw   -8(%ebp)                /* load modified control word */
 
        fldl    8(%ebp);                /* round */
        frndint
index c45d82e3022dd1c55a012844755ffb5d6f47bf4d..796db4fdadfc63c05f8c5b4dc562d7c527441814 100644 (file)
@@ -17,7 +17,7 @@ ENTRY(__floorf)
        orw     $0x0400,%dx             /* round towards -oo */
        andw    $0xf7ff,%dx
        movw    %dx,-8(%ebp)
-       fldcw   -8(%ebp)                /* load modfied control word */
+       fldcw   -8(%ebp)                /* load modified control word */
 
        flds    8(%ebp);                /* round */
        frndint
index ae4ba2ea4da703dc5f62357e0f8d499d5358845e..396d854edc6ba3874c9bb829d86d24d222d2a026 100644 (file)
@@ -18,7 +18,7 @@ ENTRY(__floorl)
        orw     $0x0400,%dx             /* round towards -oo */
        andw    $0xf7ff,%dx
        movw    %dx,-8(%ebp)
-       fldcw   -8(%ebp)                /* load modfied control word */
+       fldcw   -8(%ebp)                /* load modified control word */
 
        fldt    8(%ebp)                 /* round */
        frndint
index c27e0a9d6435698455cc71ab10306d2029a235d2..f5846946863c3cea7c91f4b2fb2794c1fbebdaab 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Developed at SunPro, a Sun Microsystems, Inc. business.
  * Permission to use, copy, modify, and distribute this
- * software is freely granted, provided that this notice 
+ * software is freely granted, provided that this notice
  * is preserved.
  * ====================================================
  */
@@ -15,19 +15,19 @@ static char rcsid[] = "$NetBSD: e_log.c,v 1.8 1995/05/10 20:45:49 jtc Exp $";
 #endif
 
 /* __ieee754_log(x)
- * Return the logrithm of x
+ * Return the logarithm of x
  *
- * Method :                  
- *   1. Argument Reduction: find k and f such that 
- *                     x = 2^k * (1+f), 
+ * Method :
+ *   1. Argument Reduction: find k and f such that
+ *                     x = 2^k * (1+f),
  *        where  sqrt(2)/2 < 1+f < sqrt(2) .
  *
  *   2. Approximation of log(1+f).
  *     Let s = f/(2+f) ; based on log(1+f) = log(1+s) - log(1-s)
  *              = 2s + 2/3 s**3 + 2/5 s**5 + .....,
  *              = 2s + s*R
- *      We use a special Reme algorithm on [0,0.1716] to generate 
- *     a polynomial of degree 14 to approximate R The maximum error 
+ *      We use a special Reme algorithm on [0,0.1716] to generate
+ *     a polynomial of degree 14 to approximate R The maximum error
  *     of this polynomial approximation is bounded by 2**-58.45. In
  *     other words,
  *                     2      4      6      8      10      12      14
@@ -35,22 +35,22 @@ static char rcsid[] = "$NetBSD: e_log.c,v 1.8 1995/05/10 20:45:49 jtc Exp $";
  *     (the values of Lg1 to Lg7 are listed in the program)
  *     and
  *         |      2          14          |     -58.45
- *         | Lg1*s +...+Lg7*s    -  R(z) | <= 2 
+ *         | Lg1*s +...+Lg7*s    -  R(z) | <= 2
  *         |                             |
  *     Note that 2s = f - s*f = f - hfsq + s*hfsq, where hfsq = f*f/2.
  *     In order to guarantee error in log below 1ulp, we compute log
  *     by
  *             log(1+f) = f - s*(f - R)        (if f is not too large)
  *             log(1+f) = f - (hfsq - s*(hfsq+R)).     (better accuracy)
- *     
- *     3. Finally,  log(x) = k*ln2 + log(1+f).  
+ *
+ *     3. Finally,  log(x) = k*ln2 + log(1+f).
  *                         = k*ln2_hi+(f-(hfsq-(s*(hfsq+R)+k*ln2_lo)))
- *        Here ln2 is split into two floating point number: 
+ *        Here ln2 is split into two floating point number:
  *                     ln2_hi + ln2_lo,
  *        where n*ln2_hi is always exact for |n| < 2000.
  *
  * Special cases:
- *     log(x) is NaN with signal if x < 0 (including -INF) ; 
+ *     log(x) is NaN with signal if x < 0 (including -INF) ;
  *     log(+INF) is +INF; log(0) is -INF with signal;
  *     log(NaN) is that NaN with no signal.
  *
@@ -59,9 +59,9 @@ static char rcsid[] = "$NetBSD: e_log.c,v 1.8 1995/05/10 20:45:49 jtc Exp $";
  *     1 ulp (unit in the last place).
  *
  * Constants:
- * The hexadecimal values are the intended ones for the following 
- * constants. The decimal values may be used, provided that the 
- * compiler will convert from decimal to binary accurately enough 
+ * The hexadecimal values are the intended ones for the following
+ * constants. The decimal values may be used, provided that the
+ * compiler will convert from decimal to binary accurately enough
  * to produce the hexadecimal values shown.
  */
 
@@ -105,12 +105,12 @@ static double zero   =  0.0;
 
        k=0;
        if (hx < 0x00100000) {                  /* x < 2**-1022  */
-           if (((hx&0x7fffffff)|lx)==0) 
+           if (((hx&0x7fffffff)|lx)==0)
                return -two54/zero;             /* log(+-0)=-inf */
            if (hx<0) return (x-x)/zero;        /* log(-#) = NaN */
            k -= 54; x *= two54; /* subnormal number, scale up x */
            GET_HIGH_WORD(hx,x);
-       } 
+       }
        if (hx >= 0x7ff00000) return x+x;
        k += (hx>>20)-1023;
        hx &= 0x000fffff;
@@ -125,14 +125,14 @@ static double zero   =  0.0;
            if(k==0) return f-R; else {dk=(double)k;
                     return dk*ln2_hi-((R-dk*ln2_lo)-f);}
        }
-       s = f/(2.0+f); 
+       s = f/(2.0+f);
        dk = (double)k;
        z = s*s;
        i = hx-0x6147a;
        w = z*z;
        j = 0x6b851-hx;
-       t1= w*(Lg2+w*(Lg4+w*Lg6)); 
-       t2= z*(Lg1+w*(Lg3+w*(Lg5+w*Lg7))); 
+       t1= w*(Lg2+w*(Lg4+w*Lg6));
+       t2= z*(Lg1+w*(Lg3+w*(Lg5+w*Lg7)));
        i |= j;
        R = t2+t1;
        if(i>0) {
index 15fba001d3849c3a1aa083d1b47f3e059c3ee02a..67da5455f93266dd20d547468a64c4374174bfef 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Developed at SunPro, a Sun Microsystems, Inc. business.
  * Permission to use, copy, modify, and distribute this
- * software is freely granted, provided that this notice 
+ * software is freely granted, provided that this notice
  * is preserved.
  * ====================================================
  */
@@ -19,10 +19,10 @@ static char rcsid[] = "$NetBSD: e_sqrt.c,v 1.8 1995/05/10 20:46:17 jtc Exp $";
  *           ------------------------------------------
  *          |  Use the hardware sqrt if you have one |
  *           ------------------------------------------
- * Method: 
- *   Bit by bit method using integer arithmetic. (Slow, but portable) 
+ * Method:
+ *   Bit by bit method using integer arithmetic. (Slow, but portable)
  *   1. Normalization
- *     Scale x to y in [1,4) with even powers of 2: 
+ *     Scale x to y in [1,4) with even powers of 2:
  *     find an integer k such that  1 <= (y=x*2^(2k)) < 4, then
  *             sqrt(x) = 2^k * sqrt(y)
  *   2. Bit by bit computation
@@ -31,9 +31,9 @@ static char rcsid[] = "$NetBSD: e_sqrt.c,v 1.8 1995/05/10 20:46:17 jtc Exp $";
  *                                     i+1         2
  *         s  = 2*q , and      y  =  2   * ( y - q  ).         (1)
  *          i      i            i                 i
- *                                                        
- *     To compute q    from q , one checks whether 
- *                 i+1       i                       
+ *
+ *     To compute q    from q , one checks whether
+ *                 i+1       i
  *
  *                           -(i+1) 2
  *                     (q + 2      ) <= y.                     (2)
@@ -42,13 +42,13 @@ static char rcsid[] = "$NetBSD: e_sqrt.c,v 1.8 1995/05/10 20:46:17 jtc Exp $";
  *     If (2) is false, then q   = q ; otherwise q   = q  + 2      .
  *                            i+1   i             i+1   i
  *
- *     With some algebric manipulation, it is not difficult to see
- *     that (2) is equivalent to 
+ *     With some algebraic manipulation, it is not difficult to see
+ *     that (2) is equivalent to
  *                             -(i+1)
  *                     s  +  2       <= y                      (3)
  *                      i                i
  *
- *     The advantage of (3) is that s  and y  can be computed by 
+ *     The advantage of (3) is that s  and y  can be computed by
  *                                   i      i
  *     the following recurrence formula:
  *         if (3) is false
@@ -60,10 +60,10 @@ static char rcsid[] = "$NetBSD: e_sqrt.c,v 1.8 1995/05/10 20:46:17 jtc Exp $";
  *                         -i                     -(i+1)
  *         s     =  s  + 2  ,  y    = y  -  s  - 2             (5)
  *           i+1      i          i+1    i     i
- *                             
- *     One may easily use induction to prove (4) and (5). 
+ *
+ *     One may easily use induction to prove (4) and (5).
  *     Note. Since the left hand side of (3) contain only i+2 bits,
- *           it does not necessary to do a full (53-bit) comparison 
+ *           it does not necessary to do a full (53-bit) comparison
  *           in (3).
  *   3. Final rounding
  *     After generating the 53 bits result, we compute one more bit.
@@ -73,7 +73,7 @@ static char rcsid[] = "$NetBSD: e_sqrt.c,v 1.8 1995/05/10 20:46:17 jtc Exp $";
  *     The rounding mode can be detected by checking whether
  *     huge + tiny is equal to huge, and whether huge - tiny is
  *     equal to huge for some floating point number "huge" and "tiny".
- *             
+ *
  * Special cases:
  *     sqrt(+-0) = +-0         ... exact
  *     sqrt(inf) = inf
@@ -101,17 +101,17 @@ static    double  one     = 1.0, tiny=1.0e-300;
 #endif
 {
        double z;
-       int32_t sign = (int)0x80000000; 
+       int32_t sign = (int)0x80000000;
        int32_t ix0,s0,q,m,t,i;
        u_int32_t r,t1,s1,ix1,q1;
 
        EXTRACT_WORDS(ix0,ix1,x);
 
     /* take care of Inf and NaN */
-       if((ix0&0x7ff00000)==0x7ff00000) {                      
+       if((ix0&0x7ff00000)==0x7ff00000) {
            return x*x+x;               /* sqrt(NaN)=NaN, sqrt(+inf)=+inf
                                           sqrt(-inf)=sNaN */
-       } 
+       }
     /* take care of zero */
        if(ix0<=0) {
            if(((ix0&(~sign))|ix1)==0) return x;/* sqrt(+-0) = +-0 */
@@ -145,12 +145,12 @@ static    double  one     = 1.0, tiny=1.0e-300;
        r = 0x00200000;         /* r = moving bit from right to left */
 
        while(r!=0) {
-           t = s0+r; 
-           if(t<=ix0) { 
-               s0   = t+r; 
-               ix0 -= t; 
-               q   += r; 
-           } 
+           t = s0+r;
+           if(t<=ix0) {
+               s0   = t+r;
+               ix0 -= t;
+               q   += r;
+           }
            ix0 += ix0 + ((ix1&sign)>>31);
            ix1 += ix1;
            r>>=1;
@@ -158,9 +158,9 @@ static      double  one     = 1.0, tiny=1.0e-300;
 
        r = sign;
        while(r!=0) {
-           t1 = s1+r; 
+           t1 = s1+r;
            t  = s0;
-           if((t<ix0)||((t==ix0)&&(t1<=ix1))) { 
+           if((t<ix0)||((t==ix0)&&(t1<=ix1))) {
                s1  = t1+r;
                if(((t1&sign)==sign)&&(s1&sign)==0) s0 += 1;
                ix0 -= t;
@@ -181,7 +181,7 @@ static      double  one     = 1.0, tiny=1.0e-300;
                if (q1==(u_int32_t)0xffffffff) { q1=0; q += 1;}
                else if (z>one) {
                    if (q1==(u_int32_t)0xfffffffe) q+=1;
-                   q1+=2; 
+                   q1+=2;
                } else
                    q1 += (q1&1);
            }
@@ -197,18 +197,18 @@ static    double  one     = 1.0, tiny=1.0e-300;
 /*
 Other methods  (use floating-point arithmetic)
 -------------
-(This is a copy of a drafted paper by Prof W. Kahan 
+(This is a copy of a drafted paper by Prof W. Kahan
 and K.C. Ng, written in May, 1986)
 
-       Two algorithms are given here to implement sqrt(x) 
+       Two algorithms are given here to implement sqrt(x)
        (IEEE double precision arithmetic) in software.
        Both supply sqrt(x) correctly rounded. The first algorithm (in
        Section A) uses newton iterations and involves four divisions.
        The second one uses reciproot iterations to avoid division, but
        requires more multiplications. Both algorithms need the ability
-       to chop results of arithmetic operations instead of round them, 
+       to chop results of arithmetic operations instead of round them,
        and the INEXACT flag to indicate when an arithmetic operation
-       is executed exactly with no roundoff error, all part of the 
+       is executed exactly with no roundoff error, all part of the
        standard (IEEE 754-1985). The ability to perform shift, add,
        subtract and logical AND operations upon 32-bit words is needed
        too, though not part of the standard.
@@ -218,7 +218,7 @@ A.  sqrt(x) by Newton Iteration
    (1) Initial approximation
 
        Let x0 and x1 be the leading and the trailing 32-bit words of
-       a floating point number x (in IEEE double format) respectively 
+       a floating point number x (in IEEE double format) respectively
 
            1    11                  52                           ...widths
           ------------------------------------------------------
@@ -226,7 +226,7 @@ A.  sqrt(x) by Newton Iteration
           ------------------------------------------------------
              msb    lsb  msb                                 lsb ...order
 
+
             ------------------------        ------------------------
        x0:  |s|   e    |    f1     |    x1: |          f2           |
             ------------------------        ------------------------
@@ -251,7 +251,7 @@ A.  sqrt(x) by Newton Iteration
 
     (2)        Iterative refinement
 
-       Apply Heron's rule three times to y, we have y approximates 
+       Apply Heron's rule three times to y, we have y approximates
        sqrt(x) to within 1 ulp (Unit in the Last Place):
 
                y := (y+x/y)/2          ... almost 17 sig. bits
@@ -276,12 +276,12 @@ A.  sqrt(x) by Newton Iteration
        it requires more multiplications and additions. Also x must be
        scaled in advance to avoid spurious overflow in evaluating the
        expression 3y*y+x. Hence it is not recommended uless division
-       is slow. If division is very slow, then one should use the 
+       is slow. If division is very slow, then one should use the
        reciproot algorithm given in section B.
 
     (3) Final adjustment
 
-       By twiddling y's last bit it is possible to force y to be 
+       By twiddling y's last bit it is possible to force y to be
        correctly rounded according to the prevailing rounding mode
        as follows. Let r and i be copies of the rounding mode and
        inexact flag before entering the square root program. Also we
@@ -312,7 +312,7 @@ A.  sqrt(x) by Newton Iteration
                I := i;                 ... restore inexact flag
                R := r;                 ... restore rounded mode
                return sqrt(x):=y.
-                   
+
     (4)        Special cases
 
        Square root of +inf, +-0, or NaN is itself;
@@ -331,7 +331,7 @@ B.  sqrt(x) by Reciproot Iteration
            k := 0x5fe80000 - (x0>>1);
            y0:= k - T2[63&(k>>14)].    ... y ~ 1/sqrt(x) to 7.8 bits
 
-       Here k is a 32-bit integer and T2[] is an integer array 
+       Here k is a 32-bit integer and T2[] is an integer array
        containing correction terms. Now magically the floating
        value of y (y's leading 32-bit word is y0, the value of
        its trailing word y1 is set to zero) approximates 1/sqrt(x)
@@ -352,9 +352,9 @@ B.  sqrt(x) by Reciproot Iteration
 
        Apply Reciproot iteration three times to y and multiply the
        result by x to get an approximation z that matches sqrt(x)
-       to about 1 ulp. To be exact, we will have 
+       to about 1 ulp. To be exact, we will have
                -1ulp < sqrt(x)-z<1.0625ulp.
-       
+
        ... set rounding mode to Round-to-nearest
           y := y*(1.5-0.5*x*y*y)       ... almost 15 sig. bits to 1/sqrt(x)
           y := y*((1.5-2^-30)+0.5*x*y*y)... about 29 sig. bits to 1/sqrt(x)
@@ -363,14 +363,14 @@ B.  sqrt(x) by Reciproot Iteration
           z := z + 0.5*z*(1-z*y)       ... about 1 ulp to sqrt(x)
 
        Remark 2. The constant 1.5-2^-30 is chosen to bias the error so that
-       (a) the term z*y in the final iteration is always less than 1; 
+       (a) the term z*y in the final iteration is always less than 1;
        (b) the error in the final result is biased upward so that
                -1 ulp < sqrt(x) - z < 1.0625 ulp
            instead of |sqrt(x)-z|<1.03125ulp.
 
     (3)        Final adjustment
 
-       By twiddling y's last bit it is possible to force y to be 
+       By twiddling y's last bit it is possible to force y to be
        correctly rounded according to the prevailing rounding mode
        as follows. Let r and i be copies of the rounding mode and
        inexact flag before entering the square root program. Also we
@@ -410,27 +410,27 @@ B.  sqrt(x) by Reciproot Iteration
            I := 1;             ... Raise Inexact flag: z is not exact
        else {
            j := 1 - [(x0>>20)&1]       ... j = logb(x) mod 2
-           k := z1 >> 26;              ... get z's 25-th and 26-th 
+           k := z1 >> 26;              ... get z's 25-th and 26-th
                                            fraction bits
            I := i or (k&j) or ((k&(j+j+1))!=(x1&3));
        }
        R:= r           ... restore rounded mode
        return sqrt(x):=z.
 
-       If multiplication is cheaper then the foregoing red tape, the 
+       If multiplication is cheaper then the foregoing red tape, the
        Inexact flag can be evaluated by
 
            I := i;
            I := (z*z!=x) or I.
 
-       Note that z*z can overwrite I; this value must be sensed if it is 
+       Note that z*z can overwrite I; this value must be sensed if it is
        True.
 
        Remark 4. If z*z = x exactly, then bit 25 to bit 0 of z1 must be
        zero.
 
                    --------------------
-               z1: |        f2        | 
+               z1: |        f2        |
                    --------------------
                bit 31             bit 0
 
@@ -447,7 +447,6 @@ B.  sqrt(x) by Reciproot Iteration
        11                      01              even
        -------------------------------------------------
 
-    (4)        Special cases (see (4) of Section A).   
+    (4)        Special cases (see (4) of Section A).
+
  */
index 5e29b05312caf54b0a60a9b9b187f9a16c9ecf78..ccf1633bd4151c0cad41868fe2841affa2fde7a3 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Developed at SunPro, a Sun Microsystems, Inc. business.
  * Permission to use, copy, modify, and distribute this
- * software is freely granted, provided that this notice 
+ * software is freely granted, provided that this notice
  * is preserved.
  * ====================================================
  */
@@ -17,12 +17,12 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
 /*
  * __kernel_rem_pio2(x,y,e0,nx,prec,ipio2)
  * double x[],y[]; int e0,nx,prec; int ipio2[];
- * 
- * __kernel_rem_pio2 return the last three digits of N with 
+ *
+ * __kernel_rem_pio2 return the last three digits of N with
  *             y = x - N*pi/2
  * so that |y| < pi/2.
  *
- * The method is to compute the integer (mod 8) and fraction parts of 
+ * The method is to compute the integer (mod 8) and fraction parts of
  * (2/pi)*x without doing the full multiplication. In general we
  * skip the part of the product that are known to be a huge integer (
  * more accurately, = 0 mod 8 ). Thus the number of operations are
@@ -31,10 +31,10 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
  * (2/pi) is represented by an array of 24-bit integers in ipio2[].
  *
  * Input parameters:
- *     x[]     The input value (must be positive) is broken into nx 
+ *     x[]     The input value (must be positive) is broken into nx
  *             pieces of 24-bit integers in double precision format.
- *             x[i] will be the i-th 24 bit of x. The scaled exponent 
- *             of x[0] is given in input parameter e0 (i.e., x[0]*2^e0 
+ *             x[i] will be the i-th 24 bit of x. The scaled exponent
+ *             of x[0] is given in input parameter e0 (i.e., x[0]*2^e0
  *             match x's up to 24 bits.
  *
  *             Example of breaking a double positive z into x[0]+x[1]+x[2]:
@@ -52,7 +52,7 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
  *                     64-bit  precision       2
  *                     113-bit precision       3
  *             The actual value is the sum of them. Thus for 113-bit
- *             precison, one may have to do something like:
+ *             precision, one may have to do something like:
  *
  *             long double t,w,r_head, r_tail;
  *             t = (long double)y[2] + (long double)y[1];
@@ -71,8 +71,8 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
  *                     3       113 bits (quad)
  *
  *     ipio2[]
- *             integer array, contains the (24*i)-th to (24*i+23)-th 
- *             bit of 2/pi after binary point. The corresponding 
+ *             integer array, contains the (24*i)-th to (24*i+23)-th
+ *             bit of 2/pi after binary point. The corresponding
  *             floating value is
  *
  *                     ipio2[i] * 2^(-24(i+1)).
@@ -87,8 +87,8 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
  *             in the computation. The recommended value is 2,3,4,
  *             6 for single, double, extended,and quad.
  *
- *     jz      local integer variable indicating the number of 
- *             terms of ipio2[] used. 
+ *     jz      local integer variable indicating the number of
+ *             terms of ipio2[] used.
  *
  *     jx      nx - 1
  *
@@ -108,9 +108,9 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
  *             exponent for q[i] would be q0-24*i.
  *
  *     PIo2[]  double precision array, obtained by cutting pi/2
- *             into 24 bits chunks. 
+ *             into 24 bits chunks.
  *
- *     f[]     ipio2[] in floating point 
+ *     f[]     ipio2[] in floating point
  *
  *     iq[]    integer array by breaking up q[] in 24-bits chunk.
  *
@@ -124,9 +124,9 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
 
 /*
  * Constants:
- * The hexadecimal values are the intended ones for the following 
- * constants. The decimal values may be used, provided that the 
- * compiler will convert from decimal to binary accurately enough 
+ * The hexadecimal values are the intended ones for the following
+ * constants. The decimal values may be used, provided that the
+ * compiler will convert from decimal to binary accurately enough
  * to produce the hexadecimal values shown.
  */
 
@@ -136,7 +136,7 @@ static char rcsid[] = "$NetBSD: k_rem_pio2.c,v 1.7 1995/05/10 20:46:25 jtc Exp $
 #ifdef __STDC__
 static const int init_jk[] = {2,3,4,6}; /* initial value for jk */
 #else
-static int init_jk[] = {2,3,4,6}; 
+static int init_jk[] = {2,3,4,6};
 #endif
 
 #ifdef __STDC__
@@ -155,9 +155,9 @@ static double PIo2[] = {
 };
 
 #ifdef __STDC__
-static const double                    
+static const double
 #else
-static double                  
+static double
 #endif
 zero   = 0.0,
 one    = 1.0,
@@ -165,9 +165,9 @@ two24   =  1.67772160000000000000e+07, /* 0x41700000, 0x00000000 */
 twon24  =  5.96046447753906250000e-08; /* 0x3E700000, 0x00000000 */
 
 #ifdef __STDC__
-       int __kernel_rem_pio2(double *x, double *y, int e0, int nx, int prec, const int32_t *ipio2) 
+       int __kernel_rem_pio2(double *x, double *y, int e0, int nx, int prec, const int32_t *ipio2)
 #else
-       int __kernel_rem_pio2(x,y,e0,nx,prec,ipio2)     
+       int __kernel_rem_pio2(x,y,e0,nx,prec,ipio2)
        double x[], y[]; int e0,nx,prec; int32_t ipio2[];
 #endif
 {
@@ -211,7 +211,7 @@ recompute:
            i  = (iq[jz-1]>>(24-q0)); n += i;
            iq[jz-1] -= i<<(24-q0);
            ih = iq[jz-1]>>(23-q0);
-       } 
+       }
        else if(q0==0) ih = iq[jz-1]>>23;
        else if(z>=0.5) ih=2;
 
@@ -262,7 +262,7 @@ recompute:
            while(iq[jz]==0) { jz--; q0-=24;}
        } else { /* break z into 24-bit if necessary */
            z = __scalbn(z,-q0);
-           if(z>=two24) { 
+           if(z>=two24) {
                fw = (double)((int32_t)(twon24*z));
                iq[jz] = (int32_t)(z-two24*fw);
                jz += 1; q0 += 24;
@@ -287,29 +287,29 @@ recompute:
            case 0:
                fw = 0.0;
                for (i=jz;i>=0;i--) fw += fq[i];
-               y[0] = (ih==0)? fw: -fw; 
+               y[0] = (ih==0)? fw: -fw;
                break;
            case 1:
            case 2:
                fw = 0.0;
-               for (i=jz;i>=0;i--) fw += fq[i]; 
-               y[0] = (ih==0)? fw: -fw; 
+               for (i=jz;i>=0;i--) fw += fq[i];
+               y[0] = (ih==0)? fw: -fw;
                fw = fq[0]-fw;
                for (i=1;i<=jz;i++) fw += fq[i];
-               y[1] = (ih==0)? fw: -fw; 
+               y[1] = (ih==0)? fw: -fw;
                break;
            case 3:     /* painful */
                for (i=jz;i>0;i--) {
-                   fw      = fq[i-1]+fq[i]; 
+                   fw      = fq[i-1]+fq[i];
                    fq[i]  += fq[i-1]-fw;
                    fq[i-1] = fw;
                }
                for (i=jz;i>1;i--) {
-                   fw      = fq[i-1]+fq[i]; 
+                   fw      = fq[i-1]+fq[i];
                    fq[i]  += fq[i-1]-fw;
                    fq[i-1] = fw;
                }
-               for (fw=0.0,i=jz;i>=2;i--) fw += fq[i]; 
+               for (fw=0.0,i=jz;i>=2;i--) fw += fq[i];
                if(ih==0) {
                    y[0] =  fq[0]; y[1] =  fq[1]; y[2] =  fw;
                } else {
index 77184d6ee57d3f4c2f7ead19fb606c41677f58b0..dc2da206d1b1fc5228eb9c7d5aaa693f0fdd38ce 100644 (file)
@@ -118,7 +118,7 @@ L(Lend:)
        rts
 
 /* We loop from least significant end of the arrays, which is only
-   permissable if the source and destination don't overlap, since the
+   permissible if the source and destination don't overlap, since the
    function is documented to work for overlapping source and destination.  */
 
 L(Lspecial:)
index 01dde0ab50e6a816ff9b9f2395cf1f1c9e45cf92..f529390cf85a033ff5ebe4322b8ee7663994431b 100644 (file)
@@ -71,7 +71,7 @@ L(Lnormal:)
        movel   MEM_POSTINC(s_ptr),R(d2)
        movel   R(d2),R(d0)
        lsll    R(d5),R(d0)             /* compute carry limb */
-   
+
        lsrl    R(cnt),R(d2)
        movel   R(d2),R(d1)
        subql   #1,R(s_size)
@@ -107,7 +107,7 @@ L(Lend:)
        rts
 
 /* We loop from most significant end of the arrays, which is only
-   permissable if the source and destination don't overlap, since the
+   permissible if the source and destination don't overlap, since the
    function is documented to work for overlapping source and destination.  */
 
 L(Lspecial:)
index 9e713fc4ca52c6a07a5bde08e14c46eec13e9c3d..5ae869f1501210d7859d295e495a26f9ad211bd9 100644 (file)
@@ -1,21 +1,21 @@
-/* dirfd -- Return the file desciptor used by a DIR stream.  Hurd version.
-Copyright (C) 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* dirfd -- Return the file descriptor used by a DIR stream.  Hurd version.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <dirent.h>
 #include <dirstream.h>
index bc90e33a7e58704104d3f9e1131d0f9b8b0d4ba5..f8d82a3cf7ab3d326bfc562161987c7fe3efeccf 100644 (file)
@@ -1,21 +1,21 @@
 /* Operating system support for run-time dynamic linker.  Hurd version.
-Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <hurd.h>
 #include <link.h>
@@ -265,7 +265,7 @@ _dl_sysdep_message (const char *msg, ...)
    dynamic linker re-relocates itself to be user-visible (for -ldl),
    it will get the user's definition (i.e. usually libc's).  */
 
-/* Open FILE_NAME and return a read-mmapable port in MEMOBJ_RD for it, or
+/* Open FILE_NAME and return a read-mmappable port in MEMOBJ_RD for it, or
    return an error.  If STAT is non-zero, stat the file into that stat buffer.  */
 static error_t
 open_file (const char *file_name, int mode,
index 16eca670ce9e9a954ed3639f1fb489826bdc22bc..264fab30157ae4e6d82585ed61ef86da11e672c0 100644 (file)
@@ -1,21 +1,21 @@
 /* Reentrant function to return the current login name.  Hurd version.
-Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
 #include <unistd.h>
@@ -23,7 +23,7 @@ Boston, MA 02111-1307, USA.  */
 #include <string.h>
 
 /* Return at most NAME_LEN characters of the login name of the user in NAME.
-   If it cannot be determined or some other error occured, return the error
+   If it cannot be determined or some other error occurred, return the error
    code.  Otherwise return 0.  */
 int
 getlogin_r (name, name_len)
index 610b4b253ad3577924c175e6c0fe32b38128e909..f52627e21e8d4a2908575b1ce18d4d7fecd4f7a3 100644 (file)
@@ -1,20 +1,20 @@
-/* Copyright (C) 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1992, 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <ansidecl.h>
 #include <errno.h>
@@ -27,7 +27,7 @@ Cambridge, MA 02139, USA.  */
 #include <fcntl.h>
 
 /* Create a one-way communication channel (pipe).
-   If successul, two file descriptors are stored in FDS;
+   If successful, two file descriptors are stored in FDS;
    bytes written on FDS[1] can be read from FDS[0].
    Returns 0 if successful, -1 if not.  */
 int
index aa99944e84d8f1663e12184a6c929a216dc49ea1..f51551a2f93cce56aa8a365e5f052931799a94a6 100644 (file)
@@ -1,20 +1,20 @@
 /* Copyright (C) 1991, 92, 93, 94, 95, 96 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <ansidecl.h>
 #include <sys/types.h>
@@ -117,7 +117,7 @@ DEFUN(__select, (nfds, readfds, writefds, exceptfds, timeout),
     return -1;
 
   /* Send them all io_select request messages.  */
-                    
+
   if (firstfd == -1)
     /* But not if there were no ports to deal with at all. */
     portset = __mach_reply_port ();
@@ -126,7 +126,7 @@ DEFUN(__select, (nfds, readfds, writefds, exceptfds, timeout),
       err = 0;
       got = 0;
       portset = MACH_PORT_NULL;
-      
+
       for (i = firstfd; i <= lastfd; ++i)
        if (d[i].type)
          {
@@ -176,7 +176,7 @@ DEFUN(__select, (nfds, readfds, writefds, exceptfds, timeout),
                if ((type & SELECT_ALL) == 0)
                  /* Bogus answer; treat like an error, as a fake positive.  */
                  type = SELECT_ALL;
-               
+
                /* This port is already ready already.  */
                d[i].type &= type;
                d[i].type |= SELECT_RETURNED;
@@ -186,7 +186,7 @@ DEFUN(__select, (nfds, readfds, writefds, exceptfds, timeout),
            _hurd_port_free (&d[i].cell->port, &d[i].ulink, d[i].io_port);
          }
     }
-  
+
   /* Now wait for reply messages.  */
   if (!err && got == 0)
     {
@@ -247,7 +247,7 @@ DEFUN(__select, (nfds, readfds, writefds, exceptfds, timeout),
                  msg.success.result = SELECT_ALL;
                }
 
-             /* Look up the respondant's reply port and record its
+             /* Look up the respondent's reply port and record its
                  readiness.  */
              {
                int had = got;
@@ -314,7 +314,7 @@ DEFUN(__select, (nfds, readfds, writefds, exceptfds, timeout),
     for (i = firstfd; i <= lastfd; ++i)
       {
        int type = d[i].type;
-       
+
        if ((type & SELECT_RETURNED) == 0)
          type = 0;
 
index 06f168bb55bc9bee0a1bccb9a735e6854229eec2..34904aa550e7610089f56ee71ab384beba0bea45 100644 (file)
@@ -1,21 +1,21 @@
 /* Generic definitions for dealing with Mach thread states.
-Copyright (C) 1994 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   Copyright (C) 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 
 /* Everything else is called `thread_state', but CMU's header file is
@@ -57,7 +57,7 @@ machine_get_state (thread_t thread, struct machine_thread_all_state *state,
     }
   else
     {
-      /* Noone asked about this flavor of state before; fetch the state
+      /* No one asked about this flavor of state before; fetch the state
         directly from the kernel into the sigcontext.  */
       mach_msg_type_number_t got = (size / sizeof (int));
       return (! __thread_get_state (thread, flavor, scpptr, &got)
index c00afbe5498b515cdf2853cb9faad25f2e739f73..9e80426ee372bccdcad1b003b59789f3bb1a5059 100644 (file)
@@ -14,9 +14,9 @@
    Library General Public License for more details.
 
    You should have received a copy of the GNU Library General Public
-   License along with the GNU C Library; see the file COPYING.LIB.  If
-   not, write to the Free Software Foundation, Inc.,
-   59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #define ELF_MACHINE_NAME "MIPS"
 
 #include <sys/mman.h>
 #include <unistd.h>
 
-/* DT_MIPS macro ranslate a processor specific dynamic tag to the index
+/* Translate a processor specific dynamic tag to the index
    in l_info array.  */
 #define DT_MIPS(x) (DT_MIPS_##x - DT_LOPROC + DT_NUM)
 
 #if 1
-/* XXX If FLAGS has the MAP_ALIGN bit, we need 64k alignement. */
+/* XXX If FLAGS has the MAP_ALIGN bit, we need 64k alignment. */
 #ifndef MAP_ALIGN
 #define MAP_ALIGN 0x1000
 #endif
index 020a46b120bcc97bf5d5ddd0281149095eef8f08..b3eec8f39abf0147123f9ed48a7e3099799ef15e 100644 (file)
 /* Set the mask of blocked signals to MASK,
    wait for a signal to arrive, and then restore the mask.  */
 int
-__sigpause (mask)
-     int mask;
+__sigpause (sig_or_mask, is_sig)
+     int sig_or_mask;
+     int is_sig;
 {
   sigset_t set;
   int sig;
 
-  if (__sigemptyset (&set) < 0)
-    return -1;
-
-  if (sizeof (mask) == sizeof (set))
-    *(int *) &set = mask;
-  else if (sizeof (unsigned long int) == sizeof (set))
-    *(unsigned long int *) &set = (unsigned int) mask;
+  if (is_sig != 0)
+    {
+      /* The modern X/Open implementation is requested.  */
+      if (sigprocmask (0, NULL, &set) < 0
+         /* Yes, we call `sigaddset' and not `__sigaddset'.  */
+         || sigaddset (&set, sig_or_mask) < 0)
+       return -1;
+    }
   else
-    for (sig = 1; sig < NSIG; ++sig)
-      if ((mask & sigmask (sig)) && __sigaddset (&set, sig) < 0)
+    {
+      if (__sigemptyset (&set) < 0)
        return -1;
 
+      if (sizeof (sig_or_mask) == sizeof (set))
+       *(int *) &set = sig_or_mask;
+      else if (sizeof (unsigned long int) == sizeof (set))
+       *(unsigned long int *) &set = (unsigned int) sig_or_mask;
+      else
+       for (sig = 1; sig < NSIG; ++sig)
+         if ((sig_or_mask & sigmask (sig)) && __sigaddset (&set, sig) < 0)
+           return -1;
+    }
+
   return sigsuspend (&set);
 }
-
-weak_alias (__sigpause, sigpause)
index 21012b4ccc5b49e6e08fe51638d86f53c7b203cf..ba8db2b985de9b98e804fd83c73f379d9ca6b37d 100644 (file)
@@ -1,29 +1,28 @@
-/* Copyright (C) 1994 Free Software Foundation, Inc.
+/* Copyright (C) 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
    Contributed by Joel Sherrill (jsherril@redstone-emh2.army.mil),
-     On-Line Applications Research Corporation.
-This file is part of the GNU C Library.
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   On-Line Applications Research Corporation.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* i960ca.h
  *
- *  This file contains macros which are used to access i80960CA 
+ *  This file contains macros which are used to access i80960CA
  *  registers which are not addressable by C.  The functions
- *  in this file sould be useful to the developer of target 
+ *  in this file should be useful to the developer of target
  *  specific code.
  */
 
@@ -37,22 +36,22 @@ typedef unsigned int    unsigned32;
 /*
  *  Intel i80960CA Processor Control Block
  */
+
 struct i80960ca_prcb {
-  unsigned32          *fault_tbl;     /* fault table base address     */ 
+  unsigned32          *fault_tbl;     /* fault table base address     */
   struct i80960ca_ctltbl
                       *control_tbl;   /* control table base address   */
   unsigned32           initial_ac;    /* AC register initial value    */
-  unsigned32           fault_config;  /* fault configuration word     */ 
+  unsigned32           fault_config;  /* fault configuration word     */
   void                *intr_tbl;      /* interrupt table base address */
-  void                *sys_proc_tbl;  /* system procedure table       */ 
-                                      /*   base address               */ 
-  unsigned32           reserved;      /* reserved                     */ 
-  unsigned32          *intr_stack;    /* interrupt stack pointer      */ 
-  unsigned32           ins_cache_cfg; /* instruction cache            */ 
-                                      /*   configuration word         */ 
-  unsigned32           reg_cache_cfg; /* register cache               */ 
-                                      /*   configuration word         */ 
+  void                *sys_proc_tbl;  /* system procedure table       */
+                                      /*   base address               */
+  unsigned32           reserved;      /* reserved                     */
+  unsigned32          *intr_stack;    /* interrupt stack pointer      */
+  unsigned32           ins_cache_cfg; /* instruction cache            */
+                                      /*   configuration word         */
+  unsigned32           reg_cache_cfg; /* register cache               */
+                                      /*   configuration word         */
 };
 
 /*
@@ -128,7 +127,7 @@ struct i80960ca_ctltbl {
                   : "0"  (_addr), "1"  (_mask) ); \
    (prev) = _mask; \
  }
-   
+
 #define delay( microseconds ) \
   { register unsigned32 _delay=(microseconds); \
     register unsigned32 _tmp; \
@@ -185,22 +184,22 @@ struct i80960ca_ctltbl {
                   : "0"  (_cmd), "1"  (_next), "2"  (_prcb) ); \
  }
 
-static inline unsigned32 pend_intrs() 
-{ register unsigned32 _intr=0; 
-  asm volatile( "mov sf0,%0" : "=d" (_intr) : "0" (_intr) ); 
-  return ( _intr ); 
+static inline unsigned32 pend_intrs()
+{ register unsigned32 _intr=0;
+  asm volatile( "mov sf0,%0" : "=d" (_intr) : "0" (_intr) );
+  return ( _intr );
 }
 
-static inline unsigned32 mask_intrs() 
+static inline unsigned32 mask_intrs()
 { register unsigned32 _intr=0;
-  asm volatile( "mov sf1,%0" : "=d" (_intr) : "0" (_intr) ); 
+  asm volatile( "mov sf1,%0" : "=d" (_intr) : "0" (_intr) );
   return( _intr );
 }
 
-static inline unsigned32 get_fp() 
-{ register unsigned32 _fp=0; 
-  asm volatile( "mov fp,%0" : "=d" (_fp) : "0" (_fp) ); 
-  return ( _fp ); 
+static inline unsigned32 get_fp()
+{ register unsigned32 _fp=0;
+  asm volatile( "mov fp,%0" : "=d" (_fp) : "0" (_fp) );
+  return ( _fp );
 }
 
 #endif
index 159070bab9652c23f20adc7fb66eea964054c516..cafb1abfe75224000736c33f0afa1813097147d1 100644 (file)
@@ -1,34 +1,32 @@
-/* Copyright (C) 1994 Free Software Foundation, Inc.
+/* Copyright (C) 1994, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
    Contributed by Joel Sherrill (jsherril@redstone-emh2.army.mil),
-     On-Line Applications Research Corporation.
-This file is part of the GNU C Library.
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
-
-#include <ansidecl.h>
+   On-Line Applications Research Corporation.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
 #include <standalone.h>
 #include "m68020.h"
 
 /* Console IO routines for a Motorola MVME135/MVME136 board.
-   
+
 They currently use the B port.  It should be possible to
 use the A port by filling in the reset of the chip structure,
 adding an ifdef for PORTA/PORTB, and switching the addresses,
-and maybe the macroes based on the macro. */
+and maybe the macros based on the macro. */
 
 /* M68681 DUART chip register structures and constants */
 
@@ -69,14 +67,15 @@ XON/XOFF flow control.  */
 #define XOFF            0x13            /* control-S */
 
 int
-DEFUN( _Console_Putc, (ch), char ch )
+_Console_Putc (ch)
+     char ch;
 {
   while ( ! (RD_M68681->srb & TXRDYB) ) ;
   while ( RD_M68681->srb & RXRDYB )        /* must be an XOFF */
-    if ( RD_M68681->rbb == XOFF ) 
+    if ( RD_M68681->rbb == XOFF )
       do {
         while ( ! (RD_M68681->srb & RXRDYB) ) ;
-      } while ( RD_M68681->rbb != XON ); 
+      } while ( RD_M68681->rbb != XON );
 
   WR_M68681->tbb = ch;
   return( 0 );
@@ -87,10 +86,11 @@ DEFUN( _Console_Putc, (ch), char ch )
 This routine reads a character from the UART and returns it. */
 
 int
-DEFUN( _Console_Getc, (poll), int poll )
+_Console_Getc (poll)
+     int poll;
 {
   if ( poll ) {
-    if ( !(RD_M68681->srb & RXRDYB) ) 
+    if ( !(RD_M68681->srb & RXRDYB) )
       return -1;
     else
       return RD_M68681->rbb;
index 06707cdd6043350b669d8f80f1bb54f32bd5add5..ce40a280130dd8e7e6269ba25720b65d52b76ee6 100644 (file)
@@ -1,21 +1,21 @@
-/* dirfd -- Return the file desciptor used by a DIR stream.  Stub version.
-Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Return the file descriptor used by a DIR stream.  Stub version.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <dirent.h>
 #include <dirstream.h>
index d8118180960e2cbd5a40d0b4d312a45723d442ac..1b6145c12df8212c8e364fcad0b8f63135a4208a 100644 (file)
@@ -21,7 +21,7 @@
 #include <unistd.h>
 
 /* Return at most NAME_LEN characters of the login name of the user in NAME.
-   If it cannot be determined or some other error occured, return the error
+   If it cannot be determined or some other error occurred, return the error
    code.  Otherwise return 0.  */
 int
 getlogin_r (name, name_len)
index 5eb698efb53bef23450eff0a9341ab63cec74f8b..63ea622cc470e9906a6f827f3d6f165805c7ea90 100644 (file)
@@ -61,7 +61,7 @@
 #define __libc_cleanup_region_end(DOIT)
 
 
-/* We need protable names for some of the functions.  */
+/* We need portable names for some of the functions.  */
 #define __libc_mutex_unlock
 
 #endif /* libc-lock.h */
index 771d1b0c16bb9768486219898b64254e91c9b726..42cc7ebbc947c3ff0ee57cd8e004badce2e9dcc2 100644 (file)
@@ -1,3 +1,3 @@
-/* This file should define the implementaton-specific limits described
+/* This file should define the implementation-specific limits described
    in posix[12]_lim.h.  If there are no useful values to give a limit,
    don't define it.  */
index c3ed56b2999bcf91d129e9d0fc051305e5da5f31..b566a19560e0465e93e2fca1a8fb1e424f5081ac 100644 (file)
@@ -1,27 +1,27 @@
 /* Copyright (C) 1991, 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
 #include <unistd.h>
 #include <stddef.h>
 
 /* Create a one-way communication channel (__pipe).
-   If successul, two file descriptors are stored in PIPEDES;
+   If successful, two file descriptors are stored in PIPEDES;
    bytes written on PIPEDES[1] can be read from PIPEDES[0].
    Returns 0 if successful, -1 if not.  */
 int
index 54d23ee262780a684170d2a188b9f354c1a4843c..5e68899ed8eaf0d42e2dfac8af2680648bb6d7d3 100644 (file)
@@ -1,31 +1,30 @@
 /* Copyright (C) 1991, 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
 #include <signal.h>
 
 int
-__sigpause (mask)
-     int mask;
+__sigpause (sig_or_mask, is_sig)
+     int sig_or_mask;
+     int is_sig;
 {
   __set_errno (ENOSYS);
   return -1;
 }
-stub_warning (sigpause)
-
-weak_alias (__sigpause, sigpause)
+stub_warning (__sigpause)
index 194eb149ecaaab67fe1b4051d33eda911bc44527..278cdeb1e2bad5bf94fc8e9750ad068ce42b0fce 100644 (file)
@@ -1,21 +1,21 @@
-/* Copyright (C) 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
+/* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifndef _SYS_SEM_BUF_H
 #define _SYS_SEM_BUF_H
@@ -41,7 +41,7 @@ __BEGIN_DECLS
 /* Data structure describing a set of semaphores.  */
 struct semid_ds
 {
-  struct ipc_perm sem_perm;            /* operation permisson struct */
+  struct ipc_perm sem_perm;            /* operation permission struct */
   __time_t sem_otime;                  /* last semop() time */
   __time_t sem_ctime;                  /* last time changed by semctl() */
   unsigned short int sem_nsems;                /* number of semaphores in set */
@@ -55,7 +55,7 @@ union semun
   unsigned short int *array;           /* array for GETALL & SETALL */
   struct seminfo *__buf;               /* buffer for IPC_INFO */
  };
+
 __END_DECLS
 
 #endif /* sys/sem_buf.h */
index c665d6c1609240f764ced5aaddbf0cf0204272de..45147d4b06c399104a5343f41b52c18ddccaead6 100644 (file)
@@ -1,21 +1,21 @@
-/* Copyright (C) 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
+/* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, August 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #ifndef _SYS_SHM_BUF_H
 #define _SYS_SHM_BUF_H
@@ -38,7 +38,7 @@ __BEGIN_DECLS
 /* Data structure describing a set of semaphores.  */
 struct shmid_ds
 {
-  struct ipc_perm sem_perm;            /* operation permisson struct */
+  struct ipc_perm sem_perm;            /* operation permission struct */
   int shm_segsz;                       /* size of segment in bytes */
   __time_t sem_atime;                  /* time of last shmat() */
   __time_t sem_dtime;                  /* time of last shmdt() */
index ce1dae094f6e15c4af452b6129b26cce166bad97..7904ea2c084e6d8c99cabec168393e0c8fb1b8c2 100644 (file)
@@ -1,20 +1,20 @@
 /* Copyright (C) 1991, 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
 #include <stddef.h>
@@ -63,7 +63,7 @@ tcsetattr (fd, optional_actions, termios_p)
 }
 
 
-/* Stricknine checking.  */
+/* Strychnine checking.  */
 static int
 bad_speed (speed)
      speed_t speed;
index e38345721e28648ee7f6bc1d87c95b23f8976b75..984d4becd3a6e5ac24cc5d2a063e2001dbb51056 100644 (file)
@@ -1,20 +1,20 @@
 /* Copyright (C) 1991, 92, 93, 95, 96 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <errno.h>
 #include <stdio.h>
@@ -22,7 +22,7 @@ Cambridge, MA 02139, USA.  */
 /* Generate a (hopefully) unique temporary filename
    in DIR (if applicable), using prefix PFX.
    If DIR_SEARCH is nonzero, perform directory searching
-   malarky as per the SVID for tempnam.
+   malarkey as per the SVID for tempnam.
    Return the generated filename or NULL if one could not
    be generated, putting the length of the string in *LENPTR.  */
 char *
index d809b6bd741658df74f13d44be35c5f1c87417e2..df400d4aaaac53fa71c8d9e329e0c8879ba2ef1c 100644 (file)
@@ -1,21 +1,22 @@
-/* Structure and constand definitions for sigaction et al.  OSF/1 version.
+/* Structure and constant definitions for sigaction et al.  OSF/1 version.
    Copyright (C) 1993, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
    Contributed by Brendan Kehoe (brendan@zen.org).
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* Structure describing the action to be taken when a signal arrives.  */
 struct sigaction
index c3c957e17eeb135b6d0bec85cdfa0bc79f3566c2..f00b1aba6524952ccf9273a9bc09c94af12ca82b 100644 (file)
@@ -42,7 +42,7 @@
 
 #define        RB_ASKNAME      0x01    /* ask for file name to reboot from */
 #define        RB_SINGLE       0x02    /* reboot to single user only */
-#define        RB_NOSYNC       0x04    /* dont sync before reboot */
+#define        RB_NOSYNC       0x04    /* don't sync before reboot */
 #define        RB_HALT         0x08    /* don't reboot, just halt */
 #define        RB_INITNAME     0x10    /* name given for /etc/init (unused) */
 #define        RB_DFLTROOT     0x20    /* use compiled-in rootdev */
index 850233aaad535372e6383f074a1d7abcadd82742..13506d2b8fb1a56a7076ee9976cfe28a57a869f3 100644 (file)
@@ -1,29 +1,29 @@
-/* Copyright (C) 1992 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Copyright (C) 1992, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
-#include <ansidecl.h>
 #include <unistd.h>
 #include <sys/types.h>
 #include <sys/time.h>
 
 /* Sleep USECONDS microseconds, or until a previously set timer goes off.  */
-unsigned int
-DEFUN(usleep, (useconds), unsigned int useconds)
+void
+usleep (useconds)
+     unsigned int useconds;
 {
   struct timeval delay;
 
@@ -32,6 +32,4 @@ DEFUN(usleep, (useconds), unsigned int useconds)
 
   (void) __select (0, (fd_set *) NULL, (fd_set *) NULL, (fd_set *) NULL,
                   &delay);
-
-  return 0;
 }
index d02c12a1fd9db445b6c4eb4a12760e3a19ee0dff..1180dfa63e588a18fe138a9bae4fa23308d7718d 100644 (file)
@@ -1,21 +1,21 @@
-/* dirfd -- Return the file desciptor used by a DIR stream.  Unix version.
-Copyright (C) 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+/* Return the file descriptor used by a DIR stream.  Unix version.
+   Copyright (C) 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <dirent.h>
 #include <dirstream.h>
index 868fdbee122bdffbee0efd397e093348b397cd25..75f17cb86f60d8d49e8286e951434df99f86c048 100644 (file)
@@ -27,7 +27,7 @@
 #include <utmp.h>
 
 /* Return at most NAME_LEN characters of the login name of the user in NAME.
-   If it cannot be determined or some other error occured, return the error
+   If it cannot be determined or some other error occurred, return the error
    code.  Otherwise return 0.  */
 
 int
diff --git a/sysdeps/unix/sysv/linux/clock.c b/sysdeps/unix/sysv/linux/clock.c
new file mode 100644 (file)
index 0000000..372afdd
--- /dev/null
@@ -0,0 +1,39 @@
+/* Copyright (C) 1991, 1992, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <sys/times.h>
+#include <time.h>
+#include <unistd.h>
+
+/* Return the time used by the program so far (user time + system time).  */
+clock_t
+clock (void)
+{
+  struct tms buf;
+  long clk_tck = __sysconf (_SC_CLK_TCK);
+
+  if (__times (&buf) < 0)
+    return (clock_t) -1;
+
+  return
+    (clk_tck <= CLOCKS_PER_SEC)
+    ? ((unsigned long) buf.tms_utime + buf.tms_stime) * (CLOCKS_PER_SEC
+                                                        / clk_tck)
+    : ((unsigned long) buf.tms_utime + buf.tms_stime) / (clk_tck
+                                                        / CLOCKS_PER_SEC);
+}
index 4508848a03f9c73bd259dea5d36d7d86755274dc..42fe89c269c7c99309c6794dc17c13b4d0bc8e38 100644 (file)
@@ -50,7 +50,7 @@ fi
 
 # The Linux filesystem standard prescribes where to place "essential"
 # files.  I.e., when the installation prefix is "/usr" we have to place
-# shared library objects and the configuation files on the root partition
+# shared library objects and the configuration files on the root partition
 # in /lib and /etc.
 if test "$prefix" = "/usr"; then
   libc_cv_slibdir="/lib"
index 174eb32ce12e2c41d7fb8237db5eedac60d10cbd..4ac65d02faf04a3ba39eb7c9c941d9d0cbf17d2a 100644 (file)
@@ -35,7 +35,7 @@ fi
 
 # The Linux filesystem standard prescribes where to place "essential"
 # files.  I.e., when the installation prefix is "/usr" we have to place
-# shared library objects and the configuation files on the root partition
+# shared library objects and the configuration files on the root partition
 # in /lib and /etc.
 if test "$prefix" = "/usr"; then
   libc_cv_slibdir="/lib"
index b313ab3409a4c4d96c9d12c3e544e1ecab5d1281..67e64208b380a6a637213b8248e024f48658f886 100644 (file)
@@ -79,7 +79,7 @@ gethostid ()
        return id;
     }
 
-  /* Getting from the file was not succesful.  An intelligent guess for
+  /* Getting from the file was not successful.  An intelligent guess for
      a unique number of a host is its IP address.  Return this.  */
   if (gethostname (hostname, MAXHOSTNAMELEN) < 0 || hostname[0] == '\0')
     /* This also fails.  Return and arbitrary value.  */
diff --git a/sysdeps/unix/sysv/linux/m68k/mremap.S b/sysdeps/unix/sysv/linux/m68k/mremap.S
new file mode 100644 (file)
index 0000000..2fec9aa
--- /dev/null
@@ -0,0 +1,29 @@
+/* Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <sysdep.h>
+
+/* The mremap system call is special because it needs to return
+   its value in register %a0.  */
+
+       .text
+PSEUDO (__mremap, mremap, 4)
+       move.l %d0, %a0
+       rts
+PSEUDO_END (__mremap)
+weak_alias (__mremap, mremap)
index d8930782d7fd9aa576b256b7145edcd6987851c1..13a6a0324889a7ba45dbc1c9958a5122ea5ad903 100644 (file)
@@ -1,21 +1,21 @@
 /* The proper definitions for Linux's sigaction.
-Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   Copyright (C) 1993, 1994, 1995, 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 /* Structure describing the action to be taken when a signal arrives.  */
 struct sigaction
@@ -27,7 +27,7 @@ struct sigaction
     __sigset_t sa_mask;
 
     /* Special flags.  */
-    unsigned long sa_flags;
+    int sa_flags;
 
     /* Restore handler.  */
     void (*sa_restorer) __P ((void));
index 0a2e67e4a53f594ac5b04ca99718ddea53beb053..d8a716f2e0f0cc9fc3c36a84b6f2be9fd5e2c1bf 100644 (file)
@@ -56,7 +56,7 @@
 #define        SIGVTALRM       26      /* Virtual alarm clock (4.2 BSD).  */
 #define        SIGPROF         27      /* Profiling alarm clock (4.2 BSD).  */
 #define        SIGWINCH        28      /* Window size change (4.3 BSD, Sun).  */
-#define        SIGPOLL         SIGIO   /* Pollable event occured (System V).  */
+#define        SIGPOLL         SIGIO   /* Pollable event occurred (System V).  */
 #define        SIGIO           29      /* I/O now possible (4.2 BSD).  */
 #define        SIGPWR          30      /* Power failure restart (System V).  */
 #define SIGUNUSED      31
index e669541eedabb9205120c63795398629bc41ea34..626c47ff7cd000691ff10030b99b2ac9a7f73a69 100644 (file)
@@ -1,22 +1,22 @@
-/* sleep - Implementation of the POSIX sleep function using nanosleep.
-Copyright (C) 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
+/* Implementation of the POSIX sleep function using nanosleep.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <time.h>
 #include <unistd.h>
index e62254ff4016cb218b5eb6909fdefb0fa7c17519..0b47da29e7b38697e581942aef89e99cf4aefdc3 100644 (file)
@@ -42,7 +42,7 @@ extern unsigned long int create_module __P ((__const char *__module_name,
 
 /* Initialize the module called MODULE_NAME with the CONTENTSSIZE
    bytes starting at address CONTENTS.  CONTENTS normally contains the
-   text and data segment of the module (the bss is implicity zeroed).
+   text and data segment of the module (the bss is implicitly zeroed).
    After copying the contents, the function pointed to by
    ROUTINES.init is executed.  When the module is no longer needed,
    ROUTINES.cleanup is executed.  SYMTAB is NULL if the module does
index 918b95d01f264e94c961654ca8dc9499abde6db0..45db6a51b427bc2ceae23e081e85f25c7cd6664a 100644 (file)
@@ -24,7 +24,7 @@
 #include <sys/ioctl.h>
 #include <linux/mtio.h>
 
-/* Specifiy default tape device.  */
+/* Specify default tape device.  */
 #ifndef DEFTAPE
 # define DEFTAPE       "/dev/tape"
 #endif
index 4770354fe2889c6086ccf7d1e9e322e31b13511f..049a71bc474894cd631f8d970e6d530170eba727 100644 (file)
@@ -42,7 +42,7 @@ __BEGIN_DECLS
 /* Data structure describing a set of semaphores.  */
 struct semid_ds
 {
-  struct ipc_perm sem_perm;            /* operation permisson struct */
+  struct ipc_perm sem_perm;            /* operation permission struct */
   __time_t sem_otime;                  /* last semop() time */
   __time_t sem_ctime;                  /* last time changed by semctl() */
   struct sem *__sembase;               /* ptr to first semaphore in array */
index 08e69eb84cf8b04a9c4ff26621bfcb02d8acf95d..f6d853744f4853bf3370f7fff04dc17b2f6f3d9f 100644 (file)
@@ -43,7 +43,7 @@ __BEGIN_DECLS
 /* Data structure describing a set of semaphores.  */
 struct shmid_ds
 {
-  struct ipc_perm shm_perm;            /* operation permisson struct */
+  struct ipc_perm shm_perm;            /* operation permission struct */
   int shm_segsz;                       /* size of segment in bytes */
   __time_t shm_atime;                  /* time of last shmat() */
   __time_t shm_dtime;                  /* time of last shmdt() */
index 3045c590a5f60a53998ae79d83da8165101233a3..536ced356df15c8d87242dc39237c2a202658ef4 100644 (file)
@@ -17,7 +17,7 @@
    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-/* Use the architecture dependend definitions from the kernel.  */
+/* Use the architecture dependent definitions from the kernel.  */
 #include <asm/termbits.h>
 
 #define _IOT_termios /* Hurd ioctl type field.  */ \
index c31f481a60f68b36987efe530951622e7dd0336c..52f666faf5509a856d44f3290f3e6798875a2d11 100644 (file)
@@ -35,9 +35,12 @@ struct timeval
 #ifndef _TIMEBITS_H
 # define _TIMEBITS_H   1
 
-# ifdef __USE_MISC
-#  include <asm/param.h>
-#  define CLOCKS_PER_SEC HZ    /* XXX names not kosher */
-# endif
+/* ISO/IEC 9899:1990 7.12.1: <time.h>
+   The macro `CLOCKS_PER_SEC' is the number per second of the value
+   returned by the `clock' function. */
+/* CAE XSH, Issue 4, Version 2: <time.h>
+   The value of CLOCKS_PER_SEC is required to be 1 million on all
+   XSI-conformant systems. */
+# define CLOCKS_PER_SEC  1000000
 
 #endif /* timebits.h */
index d08c6b6594a3923c5d57ae919ea52abf286f5ebd..9d36a90008eb36561d3f8861608d5dfe5a500a58 100644 (file)
@@ -1 +1,31 @@
-#include <sysdeps/unix/bsd/usleep.c>
+/* Implementation of the BSD usleep function using nanosleep.
+   Copyright (C) 1996 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
+
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
+
+#include <time.h>
+#include <unistd.h>
+
+void
+usleep (unsigned int useconds)
+{
+  struct timespec ts = { tv_sec: 0,
+                        tv_nsec: (long int) useconds * 1000ul };
+
+  __nanosleep (&ts, NULL);
+}
index c7793fb5f885328fc4928e5355f61d3c521b0671..b81c2bcf87375d2d78f01462b77de7c54715856d 100644 (file)
@@ -36,7 +36,7 @@
 #endif /* LIBC_SCCS and not lint */
 
 /*
- * Find the first occurence of c in the memory at cp (length n).
+ * Find the first occurrence of c in the memory at cp (length n).
  * Return pointer to match or null pointer.
  *
  * This code optimises the usual case (0 < n < 65535).
index 1683f564e2976ef8104f5afc1ec039ab36694ffd..70025cce6e2e741bfdf50731f19dae8d08adedb2 100644 (file)
@@ -36,7 +36,7 @@
 #endif /* LIBC_SCCS and not lint */
 
 /*
- * Find the first occurence of c in the string cp.
+ * Find the first occurrence of c in the string cp.
  * Return pointer to match or null pointer.
  *
  * char *
@@ -58,7 +58,7 @@ ENTRY(strchr, 0)
  */
        movab   tbl,r3          /* r3 = base of table */
        bbss    $0,(r3),Lreent  /* ensure not reentering */
-       movab   (r3)[r2],r5     
+       movab   (r3)[r2],r5
        incb    (r5)            /* mark both '\0' and c */
 0:
        scanc   r4,(r1),(r3),$1 /* look for c or '\0' */
index e5bfcf2a738d2a4a3fb105d10edad027ad244b3c..0758bd87295bf565638bc22f35ebae91b97d69f7 100644 (file)
@@ -53,14 +53,14 @@ ENTRY(strncmp, 0)
        movl    4(ap),r1        # r1 = s1
        movq    8(ap),r3        # r3 = s2; r4 = n
 1:
-       clrl    r5              # calculate min bytes to next page boundry
+       clrl    r5              # calculate min bytes to next page boundary
        subb3   r1,$255,r5      # r5 = (bytes - 1) to end of page for s1
        subb3   r3,$255,r0      # r0 = (bytes - 1) to end of page for s2
        cmpb    r0,r5           # r5 = min(r0, r5);
        bgtru   2f
        movb    r0,r5
 2:
-       incl    r5              # r5 = min bytes to next page boundry
+       incl    r5              # r5 = min bytes to next page boundary
        cmpl    r4,r5           # r5 = min(n, r5);
        bgeq    3f
        movl    r4,r5
index dffcddaef027eec7becce53888169d146f93a088..87313445c9c05c7641ff24334216e7cbc8a178e5 100644 (file)
@@ -36,7 +36,7 @@
 #endif /* LIBC_SCCS and not lint */
 
 /*
- * Find the last occurence of c in the string cp.
+ * Find the last occurrence of c in the string cp.
  * Return pointer to match or null pointer.
  *
  * char *
index fea545cd38327af25f127250a28126a1f37a6f32..963e9e4e4d8788fbd471acbf64a730f380e43ac6 100644 (file)
@@ -85,23 +85,27 @@ extern char *tzname[];
 #endif
 
 #ifndef __P
-#if defined (__GNUC__) || (defined (__STDC__) && __STDC__)
-#define __P(args) args
-#else
-#define __P(args) ()
-#endif  /* GCC.  */
+# if defined (__GNUC__) || (defined (__STDC__) && __STDC__)
+#  define __P(args) args
+# else
+#  define __P(args) ()
+# endif  /* GCC.  */
 #endif  /* Not __P.  */
 
 #ifndef PTR
-#ifdef __STDC__
-#define PTR void *
-#else
-#define PTR char *
-#endif
+# ifdef __STDC__
+#  define PTR void *
+# else
+#  define PTR char *
+# endif
 #endif
 
 #ifndef CHAR_BIT
-#define CHAR_BIT 8
+# define CHAR_BIT 8
+#endif
+
+#ifndef NULL
+# define NULL 0
 #endif
 
 #define TYPE_SIGNED(t) ((t) -1 < 0)
@@ -119,7 +123,7 @@ extern char *tzname[];
 #ifndef __isleap
 /* Nonzero if YEAR is a leap year (every 4 years,
    except every 100th isn't, and every 400th is).  */
-#define __isleap(year) \
+# define __isleap(year)        \
   ((year) % 4 == 0 && ((year) % 100 != 0 || (year) % 400 == 0))
 #endif
 
@@ -134,7 +138,7 @@ extern int __tz_compute __P ((time_t timer, const struct tm *tm));
 # if ! HAVE_LOCALTIME_R
 #  if ! HAVE_TM_GMTOFF
 /* Approximate gmtime_r as best we can in its absence.  */
-#define gmtime_r my_gmtime_r
+#  define gmtime_r my_gmtime_r
 static struct tm *gmtime_r __P ((const time_t *, struct tm *));
 static struct tm *
 gmtime_r (t, tp)
@@ -150,7 +154,7 @@ gmtime_r (t, tp)
 #  endif /* ! HAVE_TM_GMTOFF */
 
 /* Approximate localtime_r as best we can in its absence.  */
-#define localtime_r my_localtime_r
+#  define localtime_r my_localtime_r
 static struct tm *localtime_r __P ((const time_t *, struct tm *));
 static struct tm *
 localtime_r (t, tp)
@@ -194,23 +198,25 @@ static const char spaces[16] = "                ";
     {                                                                        \
       int _n = (n);                                                          \
       int _delta = width - _n;                                               \
-      i += _n + (_delta > 0 ? _delta : 0);                                   \
-      if (i >= maxsize)                                                              \
+      int _incr = _n + (_delta > 0 ? _delta : 0);                            \
+      if (i + _incr >= maxsize)                                                      \
        return 0;                                                             \
-      else                                                                   \
-       if (p)                                                                \
-         {                                                                   \
-           if (_delta > 0)                                                   \
-             memset_space (p, _delta);                                       \
-           f;                                                                \
-           p += _n;                                                          \
-         }                                                                   \
+      if (p)                                                                 \
+       {                                                                     \
+         if (_delta > 0)                                                     \
+           memset_space (p, _delta);                                         \
+         f;                                                                  \
+         p += _n;                                                            \
+       }                                                                     \
+      i += _incr;                                                            \
     } while (0)
 
 #define        cpy(n, s) \
     add ((n),                                                                \
         if (to_lowcase)                                                      \
           memcpy_lowcase (p, (s), _n);                                       \
+        else if (to_uppcase)                                                 \
+          memcpy_uppcase (p, (s), _n);                                       \
         else                                                                 \
           memcpy ((PTR) p, (PTR) (s), _n))
 
@@ -237,6 +243,19 @@ memcpy_lowcase (dest, src, len)
   return dest;
 }
 
+static char *memcpy_uppcase __P ((char *dest, const char *src, size_t len));
+
+static char *
+memcpy_uppcase (dest, src, len)
+     char *dest;
+     const char *src;
+     size_t len;
+{
+  while (len-- > 0)
+    dest[len] = TOUPPER (src[len]);
+  return dest;
+}
+
 #if ! HAVE_TM_GMTOFF
 /* Yield the difference between *A and *B,
    measured in seconds, ignoring leap seconds.  */
@@ -393,6 +412,7 @@ strftime (s, maxsize, format, tp)
                    : INT_STRLEN_BOUND (int))];
       int width = -1;
       int to_lowcase = 0;
+      int to_uppcase = 0;
 
 #if DO_MULTIBYTE
 
@@ -468,16 +488,19 @@ strftime (s, maxsize, format, tp)
 #endif /* ! DO_MULTIBYTE */
 
       /* Check for flags that can modify a number format.  */
-      ++f;
       while (1)
        {
-         switch (*f)
+         switch (*++f)
            {
            case '_':
            case '-':
            case '0':
-             pad = *f++;
-             break;
+             pad = *f;
+             continue;
+
+           case '^':
+             to_uppcase = 1;
+             continue;
 
            default:
              pad = 0;
@@ -563,10 +586,18 @@ strftime (s, maxsize, format, tp)
 
        subformat:
          {
+           char *old_start = p;
            size_t len = strftime (NULL, maxsize - i, subfmt, tp);
            if (len == 0 && *subfmt)
              return 0;
            add (len, strftime (p, maxsize - i, subfmt, tp));
+
+           if (to_uppcase)
+             while (old_start < p)
+               {
+                 *old_start = TOUPPER (*old_start);
+                 ++old_start;
+               }
          }
          break;
 
index 935de80c7a94730939e329d626245f1a3aa2a27f..e824e64b9d59ed704bc1cca1f6bae112d8666259 100644 (file)
@@ -265,10 +265,10 @@ extern int dysize __P ((int __year));
 #endif
 
 
-#ifdef __USE_POSIX
 /* Pause execution for a number of nanoseconds.  */
 extern int __nanosleep __P ((__const struct timespec *__requested_time,
                             struct timespec *__remaining));
+#ifdef __USE_POSIX199309
 extern int nanosleep __P ((__const struct timespec *__requested_time,
                           struct timespec *__remaining));
 #endif
index a354a1ece399f5a531f21518cae63b4b7c9251f7..f75834c6c3fd9af289c2697b6569a1c6514bc1fb 100644 (file)
@@ -1,6 +1,6 @@
 #ifndef lint
 #ifndef NOID
-static char    elsieid[] = "@(#)zic.c  7.78";
+static char    elsieid[] = "@(#)zic.c  7.79";
 #endif /* !defined NOID */
 #endif /* !defined lint */
 
@@ -359,6 +359,7 @@ char * const        ptr;
 {
        if (ptr == NULL) {
                const char *e = strerror(errno);
+
                (void) fprintf(stderr, _("%s: Memory exhausted: %s\n"),
                        progname, e);
                (void) exit(EXIT_FAILURE);
@@ -608,6 +609,7 @@ const char * const  tofile;
                        (void) exit(EXIT_FAILURE);
                if (link(fromname, toname) != 0) {
                        const char *e = strerror(errno);
+
                        (void) fprintf(stderr,
                                _("%s: Can't link from %s to %s: %s\n"),
                                progname, fromname, toname, e);
@@ -780,6 +782,7 @@ const char *        name;
                fp = stdin;
        } else if ((fp = fopen(name, "r")) == NULL) {
                const char *e = strerror(errno);
+
                (void) fprintf(stderr, _("%s: Can't open %s: %s\n"),
                        progname, name, e);
                (void) exit(EXIT_FAILURE);
@@ -848,6 +851,7 @@ _("%s: panic: Invalid l_value %d\n"),
        }
        if (fp != stdin && fclose(fp)) {
                const char *e = strerror(errno);
+
                (void) fprintf(stderr, _("%s: Error closing %s: %s\n"),
                        progname, filename, e);
                (void) exit(EXIT_FAILURE);
@@ -1422,11 +1426,22 @@ const char * const      name;
        fullname = erealloc(fullname,
                (int) (strlen(directory) + 1 + strlen(name) + 1));
        (void) sprintf(fullname, "%s/%s", directory, name);
+       /*
+       ** Remove old file, if any, to snap links.
+       */
+       if (!itsdir(fullname) && remove(fullname) != 0 && errno != ENOENT) {
+               const char *e = strerror(errno);
+
+               (void) fprintf(stderr, _("%s: Can't remove %s: %s\n"),
+                       progname, fullname, e);
+               (void) exit(EXIT_FAILURE);
+       }
        if ((fp = fopen(fullname, "wb")) == NULL) {
                if (mkdirs(fullname) != 0)
                        (void) exit(EXIT_FAILURE);
                if ((fp = fopen(fullname, "wb")) == NULL) {
                        const char *e = strerror(errno);
+
                        (void) fprintf(stderr, _("%s: Can't create %s: %s\n"),
                                progname, fullname, e);
                        (void) exit(EXIT_FAILURE);
@@ -2114,6 +2129,7 @@ char * const      argname;
                        */
                        if (mkdir(name, 0755) != 0) {
                                const char *e = strerror(errno);
+
                                (void) fprintf(stderr,
                                    _("%s: Can't create directory %s: %s\n"),
                                    progname, name, e);
index 19042238480eea5e315db510c3733ba1190ce4ca..14f13ea89d32fad284815bf7c808f139b01cdf6e 100644 (file)
--- a/values.h
+++ b/values.h
@@ -1,4 +1,4 @@
-/* Old compatiblity names for <limits.h> and <float.h> constants.
+/* Old compatibility names for <limits.h> and <float.h> constants.
    Copyright (C) 1995, 1996 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
index 4d6d8ffbbebaf52400f9fa06c17574b179952015..689428bacffefdc31f33d8935c10e459ea88c473 100644 (file)
@@ -92,9 +92,9 @@ extern size_t wcsxfrm __P ((wchar_t *__s1, __const wchar_t *__s2, size_t __n));
 /* Duplicate S, returning an identical malloc'd string.  */
 extern wchar_t *wcsdup __P ((__const wchar_t *__s));
 
-/* Find the first occurence of WC in WCS.  */
+/* Find the first occurrence of WC in WCS.  */
 extern wchar_t *wcschr __P ((__const wchar_t *__wcs, wchar_t __wc));
-/* Find the last occurence of WC in WCS.  */
+/* Find the last occurrence of WC in WCS.  */
 extern wchar_t *wcsrchr __P ((__const wchar_t *__wcs, wchar_t __wc));
 
 /* Return the length of the initial segmet of WCS which
@@ -104,10 +104,10 @@ extern size_t wcscspn __P ((__const wchar_t *__wcs,
 /* Return the length of the initial segmet of WCS which
    consists entirely of wide-characters in  ACCEPT.  */
 extern size_t wcsspn __P ((__const wchar_t *__wcs, __const wchar_t *__accept));
-/* Find the first occurence in WCS of any character in ACCEPT.  */
+/* Find the first occurrence in WCS of any character in ACCEPT.  */
 extern wchar_t *wcspbrk __P ((__const wchar_t *__wcs,
                              __const wchar_t *__accept));
-/* Find the first occurence of NEEDLE in HAYSTACK.  */
+/* Find the first occurrence of NEEDLE in HAYSTACK.  */
 extern wchar_t *wcsstr __P ((__const wchar_t *__haystack,
                             __const wchar_t *__needle));
 /* Divide WCS into tokens separated by characters in DELIM.  */
index 64af0bf456dddfa57ca9937f09eb2f14943080ea..7f5c7dcba2d3b40cd13709993d20ce85d9851af1 100644 (file)
@@ -1,25 +1,25 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
+   This file is part of the GNU C Library.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.         If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <wchar.h>
 
 
-/* Find the first ocurrence of WC in WCS.  */
+/* Find the first occurrence of WC in WCS.  */
 wchar_t *
 wcschr (wcs, wc)
      register const wchar_t *wcs;
index fb554cbfb5e0c57fe23cb15fc4fbd7bedca8a026..9b317725693ecac940f497982efb307caddba6c2 100644 (file)
@@ -1,28 +1,28 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper <drepper@gnu.ai.mit.edu>, 1995.
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.  If
-not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <wchar.h>
 
 
 /* Compare no more than N characters of S1 and S2,
    returning less than, equal to or greater than zero
-   if S1 is lexiographically less than, equal to or
+   if S1 is lexicographically less than, equal to or
    greater than S2.  */
 int
 wcsncmp (s1, s2, n)
index 91c5573722248f53acc83533224344433a0cb179..85794ef31a6d307f4c40791ee8641c6bf14943f2 100644 (file)
@@ -1,26 +1,26 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.         If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <wchar.h>
 
 
-/* Find the first ocurrence in WCS of any wide-character in ACCEPT.  */
+/* Find the first occurrence in WCS of any wide-character in ACCEPT.  */
 wchar_t *
 wcspbrk (wcs, accept)
      register const wchar_t *wcs;
index ae31dc410444dd0f4c5ad58cc66d2002b5fc19b0..9f032c7624567bde6df25b16aa6bf83253e5535c 100644 (file)
@@ -1,26 +1,26 @@
 /* Copyright (C) 1995, 1996 Free Software Foundation, Inc.
-This file is part of the GNU C Library.
-Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>
+   This file is part of the GNU C Library.
+   Contributed by Ulrich Drepper, <drepper@gnu.ai.mit.edu>
 
-The GNU C Library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public License as
-published by the Free Software Foundation; either version 2 of the
-License, or (at your option) any later version.
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Library General Public License as
+   published by the Free Software Foundation; either version 2 of the
+   License, or (at your option) any later version.
 
-The GNU C Library is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-Library General Public License for more details.
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Library General Public License for more details.
 
-You should have received a copy of the GNU Library General Public
-License along with the GNU C Library; see the file COPYING.LIB.         If
-not, write to the Free Software Foundation, Inc., 675 Mass Ave,
-Cambridge, MA 02139, USA.  */
+   You should have received a copy of the GNU Library General Public
+   License along with the GNU C Library; see the file COPYING.LIB.  If not,
+   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+   Boston, MA 02111-1307, USA.  */
 
 #include <wchar.h>
 
 
-/* Find the last ocurrence of WC in WCS.  */
+/* Find the last occurrence of WC in WCS.  */
 wchar_t *
 wcsrchr (wcs, wc)
      register const wchar_t *wcs;