Commit Graph

197 Commits

Author SHA1 Message Date
kleink 0cca1fcb27 Perform stdio stream locking as appropriate. 1998-09-09 12:08:05 +00:00
kleink 96deb0c4ec s/c_plusplus/__cplusplus/ 1998-09-08 15:10:12 +00:00
kleink 83d4043d4c s/NULL/NUL/ where appropriate. 1998-09-08 14:13:36 +00:00
kleink 100b813fad Deploy stdio stream locking as necessary. 1998-09-07 14:37:13 +00:00
kleink caa80a1e72 Sloppy stdio stream lock tracking. 1998-09-07 14:31:57 +00:00
kleink 18a528c1cf Minor KNF nit. 1998-09-07 14:22:30 +00:00
kleink 77c6af31c7 Sloppy stdio stream lock tracking. 1998-09-06 16:37:27 +00:00
perry 315aabd347 make sure asprintf and vasprintf get MLINKS to printf.3 1998-08-30 23:29:18 +00:00
lukem ce83c69e00 first pass at fixing up capitalization of function names and
arguments; ensure that each is correct with respect to the
implementation, rather than being correct as per english.
1998-08-29 08:32:32 +00:00
perry 05ffc15e02 document asprintf and vasprintf 1998-08-28 22:21:23 +00:00
perry 253ef37df2 add asprintf and vasprintf, originally written by Todd Miller for OpenBSD 1998-08-28 21:33:10 +00:00
mycroft 0816a4773b Update the date on this man page. 1998-07-28 17:11:12 +00:00
mycroft f1f53ef7e8 Add an internal name for perror(3). 1998-07-28 12:22:31 +00:00
mycroft 0bbc075c20 Document mkdtemp(3). 1998-07-27 16:41:40 +00:00
mycroft 90cb894b40 Mention mkdtemp() in the warnings. 1998-07-27 16:39:11 +00:00
mycroft cbb3325e89 Actually, FreeBSD calls this mkdtemp(). No point in creating a new name. 1998-07-27 16:12:01 +00:00
mycroft 7daf213c0f Add a mktempdir(), like mkstemp(), but it creates a directory. 1998-07-27 16:05:07 +00:00
mycroft 1b5106953f Delint (partially). 1998-07-27 14:04:01 +00:00
mycroft 201e4eaca0 If AUDIT, do not compile certain functions. 1998-07-27 13:42:27 +00:00
mycroft c427e33070 If AUDIT, do not compile certain functions. 1998-07-27 13:36:43 +00:00
mycroft c18a540460 Minor nit. 1998-07-26 13:55:44 +00:00
mycroft eb69773cbb const poisoning. 1998-07-26 13:51:44 +00:00
mycroft dae9fd960e const poisoning. 1998-07-26 12:35:24 +00:00
mycroft be9c427d60 const poisoning. 1998-07-26 12:29:33 +00:00
jeremy 20de71c33e Changed HISTORY section to reflect that vsnprintf and snprintf first
appeared in 4.4BSD, rather than ``the current release''.
1998-06-08 23:45:37 +00:00
lukem fc90756956 Implement a new manual page category ``SECURITY CONSIDERATIONS''
(suggested by mycroft)
1998-06-08 12:41:41 +00:00
kleink 01709792a9 Need <stdlib.h> for mkstemp() prototype. 1998-06-01 20:19:46 +00:00
kleink c1d274c3ee Need <stdlib.h> for mkstemp() and mktemp() prototypes. 1998-06-01 20:17:50 +00:00
kleink 4c4cda3733 Prototypes have moved: change inclusion of <unistd.h> to <stdlib.h>. 1998-06-01 20:16:37 +00:00
fair a27dd1341b "System V" -> ".At V" 1998-04-28 20:59:29 +00:00
fair 8e1d7f3de1 fix mdoc references and other mistakes 1998-04-28 20:58:00 +00:00
fair dc026e0515 Change occurrences of "UNIX" to .Ux or .At as appropriate. 1998-04-28 06:00:51 +00:00
lukem c197a64bba don't assume buf is NL_TEXTMAX long 1998-02-16 11:27:15 +00:00
perry 312aca536f add LIBRARY section to man page 1998-02-05 18:45:17 +00:00
perry a16d9e868b .Bx'ize 1998-02-03 21:42:54 +00:00
perry c8bafd6265 remove obsolete register declarations 1998-02-03 18:38:12 +00:00
mycroft 704290aaa1 Deal with GCC warning. 1998-02-03 01:40:49 +00:00
perry 3da5be9552 merge lite-2 1998-02-02 03:32:51 +00:00
jtc a1de770ebd Use rwlocks as appropriate. 1998-01-22 08:21:45 +00:00
jtc b559f98b9b Use FLOCKFILE() and FUNLOCKFILE() macros from reentrant.h so that stdio
can be made thread-safe.
1998-01-22 06:35:01 +00:00
jtc da2013ac86 Use FLOCKFILE() and FUNLOCKFILE() macros from reentrant.h so that stdio
can be made thread-safe.
1998-01-19 07:38:41 +00:00
kleink f47d490f87 Change several functions to return -1 instead of EOF, which was semantically
wrong.
1997-12-19 14:08:41 +00:00
mrg 4e252e8c4d add missing .Nm entries. from spz@serpens.swb.de. 1997-11-14 02:04:36 +00:00
thorpej 2a43f22095 __warn_references and __indr_reference semicolon fixups. From
Chris Demetriou <cgd@pa.dec.com>.
1997-11-04 23:52:05 +00:00
lukem d0e23d974a - use CPPFLAGS instead of CFLAGS
- use ${COMPILE.C} ... instead of ${CC} ${CFLAGS} -c ...
1997-10-22 23:14:04 +00:00
mycroft 15de1c9fd2 Use S_IS*(), not S_IF*. 1997-10-19 17:54:18 +00:00
mycroft 3c891ba5b1 Fix a bizarre formatting error. 1997-10-14 07:27:57 +00:00
hubertf 26f31c2590 Partly backing out last change, only leaving lstat() instead of stat().
Pointed out by Enami Tsugutomo <enami@but-b.or.jp>.
1997-10-07 00:02:44 +00:00
hubertf 681b2f48bc remove(3) doesn't remove dangling links due to stat() returning an
error. Now try lstat() before really aborting.
OK'd by thorpej.
1997-10-06 00:28:14 +00:00
phil a25ce426d4 Remove the flag test when seeing if _double is zero or not. We
are only testing for the cvt problem, not for alternate forms.
This change makes %#e and %e both correctly print 0.  It is just
a question of is it the proper number of zeros or not?
1997-08-29 05:31:11 +00:00
kleink c213a3af8b Add missing `STANDARDS' compliance statements. As we #define _POSIX_VERSION
to 199009L, bump existing statements to 1003.1-1990.
1997-07-14 23:19:39 +00:00
christos 0c339c443a Fix RCSID's
Fix gcc warnings.
Add prototypes for functions that were declared in more than one place
to local.h or extern.h and use that instead.
1997-07-13 20:15:17 +00:00
christos 23312f88d4 Fix RCSID's
Fix gcc warnings.
Add prototypes for functions that were declared in more than one place
to local.h or extern.h and use that instead.
1997-07-13 20:14:49 +00:00
phil 4de11835a6 Modify to have _gettemp generate different names on repeated calls even if the
file was not created.  Tempnam modified to make use of full possibilities.
1997-07-07 17:47:00 +00:00
kleink 72a0532ba2 Add an Xref to rmdir(2). 1997-06-03 22:28:25 +00:00
kleink 5ddc3f534d Always use rmdir(2) to remove a directory, as the file system may prohibit
using unlink(2) on directories.
1997-06-03 22:26:38 +00:00
kleink 5a4d11e445 Upon an attempt to write to a stream that can't be written to, set errno
to EBADF.
1997-05-03 09:01:48 +00:00
lukem c3e5a4fdb6 use lstat() instead of stat() when checking for existance.
from Keith Bostic <bostic@bostic.com>
1997-04-08 06:14:39 +00:00
kleink f87eccf5b4 RCSid police 1997-04-02 12:50:23 +00:00
lukem 0607611785 * clarify that tempnam and tmpnam still have problems
* advise mkstemp() over mktemp(), tmpnam(), tempnam(), and indicate
  link-time warning if latter 3 are used
* minor cleanups
1997-03-24 11:39:10 +00:00
lukem 15d4b08009 explain why mktemp() should generally be avoided in favour of mkstemp() 1997-03-24 09:22:15 +00:00
lukem 1960b7137d add warn_refs for mktemp(), tempnam(), and tmpnam() since most code
use these incorrectly. mkstemp() is ok however. inspired by openbsd
1997-03-16 05:00:38 +00:00
mouse ff44468136 alternate -> alternative, per PR 2643 1997-03-08 13:36:38 +00:00
mrg 9cd5492c02 - convert unsafe strcpy(), strcat() and sprintf() to the `n' versions.
- some KNF.
1997-01-23 14:01:45 +00:00
mikel 37ee5d07f0 xref lseek(2) instead of seek(2); PR lib/2750
also note fpos_t/off_t discrepancy.
1997-01-23 08:10:04 +00:00
perry 49f0a0ae54 fix pr-2664, second param to fgets is int not size_t, from SAITOH Masanobu 1997-01-17 02:38:19 +00:00
cgd 316aac5b98 pull in local.h for prototypes. first arg to __sflags() is const char * 1996-12-20 20:26:00 +00:00
mouse b88c4afb8d Apply PR 2751 - writefn's second arg is const char *, not char *. 1996-11-07 09:23:10 +00:00
explorer 5b3a9aad8d Cute little bug with operator precedence in our stdio code. It appears
that flushing wasn't done right when input buffers were refilled, due
to a check like
	if (foo == _A | _B) which, since _A and _B are both != 0, always
evaluates to true.

Found by proven@cygnus.com
1996-08-13 07:54:00 +00:00
pk 204be49cb4 typo: DV -> Dv 1996-05-05 19:21:20 +00:00
mycroft 0fd4b530e0 Change suggested by Chris Torek to fix problem freopen()ing with a closed
file descriptor.
1996-05-04 19:25:19 +00:00
jtc da8d0ce8e0 Add explict function return types 1996-03-29 23:29:06 +00:00
jtc 0bcc20d745 Fix typo in funopen prototype; Reported by Noriyuki Soda in PR #1954 1996-01-17 01:42:55 +00:00
jtc b01f461032 Remove trailing comma from cross reference list. 1995-07-03 22:49:10 +00:00
jtc 615fb07b15 The C Standard says that printf's format string is a multi-byte
character string.  NA1 says that the 99 characters required by the
Standard have representations in the initial state which are one byte
long and do not alter the state.

Thus we can safely break apart the format string with mbtowc() until
we reach a '%' character, and the process format directive characters
one by one.

We really shouldn't be using mbtowc(), rather mbrtowc() (which takes a
mbstate-t argument) but we don't have the NA1 functions implemented
yet.  This is safe, because even when we do we're not likely to
support multi-byte character encodings that use shift states.
1995-05-02 19:52:41 +00:00
jtc 2ef4abe78f change second arg of fgets() from size_t to int 1995-03-25 02:50:04 +00:00
jtc 4255068068 Removed const qualifier from ftell's FILE * argument. It's not ANSI,
and the recent change to flush output causes it to be changed.
1995-03-22 18:17:24 +00:00
jtc 3b29974599 Added "long long" support %ll{d,x,o,i}. 1995-03-22 00:56:55 +00:00
jtc 38937f73d0 flush so that the offset will be correct on streams opened in
append mode (from chris torek).
1995-03-05 06:56:09 +00:00
cgd 3d5508dc07 mktemp.c belongs here, not gen/Makefile.inc 1995-02-25 17:06:28 +00:00
cgd 708504beb1 when you have a pointer and want to assign to a quad, you must cast it
to long to quiet the compiler.
1995-02-25 07:06:38 +00:00
cgd 9386b82936 when you have a quad and want to assign to a pointer, you must say:
ptr = (ptr_type)(long)quad;
to quiet the compiler.
1995-02-25 07:02:16 +00:00
jtc edead1feee revert 1995-02-02 02:16:48 +00:00
jtc 255db7b26b Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
1995-02-02 02:09:03 +00:00
jtc 389c46c57d Merged with 4.4lite.
Changed to conform to NetBSD's new RCS Id convention.
1995-02-02 01:15:33 +00:00
jtc 7cd7db23c2 imported from 44lite 1995-02-02 00:57:36 +00:00
jtc 6a96a52c80 Handle long doubles.
Like Plauger's implementation in "The Standard C Library", we use strtod(),
which will limit the range of values that can be converter properly if
long double has greater precision or range than double.

We will need a string to long double function to handle this properly, but
this change is better than the previous behavior of ignoring the existance
of long doubles.
1995-01-30 00:45:59 +00:00
jtc f0c0009971 Added support for quad_t and u_quad_t's with the 'q' flag. 1995-01-27 15:20:25 +00:00
jtc 2893ea1742 Removed conflicting "backwards compatibility" code to make scanf
ANSI compliant.
1995-01-26 01:34:44 +00:00
jtc a40e8f9215 Fixed bug with '+' or ' ' flags and precision.
for example, printf("% 6.4d\n", 77) output one two many padding chars.
1995-01-25 11:20:41 +00:00
mycroft 33c7f89b0e Remove useless invocation of the evil getdtablesize(3). 1994-12-30 04:40:13 +00:00
cgd ae9172d6cd specify man pages the new way. 1994-12-22 09:57:51 +00:00
cgd fee4815efc fix pr 594, pointed out by Chuck Silvers. fix taken from 4.4-Lite, rather
than his patch.  (functionally identical, though...)
1994-12-08 22:58:47 +00:00
jtc 14c8a82a15 Fix zero padding when using the # format modifier. 1994-10-20 03:56:56 +00:00
cgd 4d09105f58 needs string.h 1994-10-19 03:18:47 +00:00
jtc e19f10c79b Change size of array passed to __strerror() from 128 to NL_TEXTMAX. 1994-10-06 18:14:53 +00:00
jtc c36fd69bc3 The decimal point character is locale specific. 1994-09-30 02:39:13 +00:00
mycroft e9d5734eb6 Move FLOATING_POINT definition into Makefile.inc. 1994-09-19 04:43:02 +00:00
jtc 0d6ff3aeed Increased the size of char buffer used by perror(); the error strings may
be much longer in some locales.
1994-09-03 05:20:00 +00:00
jtc c7527f8b84 Converted to use link-time warning messages. 1994-07-21 17:13:35 +00:00