Browse Source

More <sys/file.h> vs. <fcntl.h> and open() flags fixes.

OPENBSD_2_6
millert 25 years ago
parent
commit
f110e3be6d
4 changed files with 11 additions and 11 deletions
  1. +3
    -3
      src/lib/libc/hash/rmd160hl.c
  2. +3
    -3
      src/lib/libc/hash/sha1hl.c
  3. +3
    -3
      src/lib/libutil/logwtmp.c
  4. +2
    -2
      src/lib/libutil/uucplock.c

+ 3
- 3
src/lib/libc/hash/rmd160hl.c View File

@ -8,13 +8,13 @@
*/ */
#if defined(LIBC_SCCS) && !defined(lint) #if defined(LIBC_SCCS) && !defined(lint)
static char rcsid[] = "$OpenBSD: rmd160hl.c,v 1.1 1997/07/17 05:37:01 millert Exp $";
static char rcsid[] = "$OpenBSD: rmd160hl.c,v 1.2 1999/08/17 09:13:12 millert Exp $";
#endif /* LIBC_SCCS and not lint */ #endif /* LIBC_SCCS and not lint */
#include <stdlib.h> #include <stdlib.h>
#include <stdio.h> #include <stdio.h>
#include <errno.h> #include <errno.h>
#include <sys/file.h>
#include <fcntl.h>
#include <sys/types.h> #include <sys/types.h>
#include <sys/uio.h> #include <sys/uio.h>
#include <unistd.h> #include <unistd.h>
@ -54,7 +54,7 @@ RMD160File (filename, buf)
RMD160Init(&ctx); RMD160Init(&ctx);
if ((fd = open(filename,O_RDONLY)) < 0)
if ((fd = open(filename, O_RDONLY)) < 0)
return(0); return(0);
while ((num = read(fd, buffer, sizeof(buffer))) > 0) while ((num = read(fd, buffer, sizeof(buffer))) > 0)


+ 3
- 3
src/lib/libc/hash/sha1hl.c View File

@ -8,13 +8,13 @@
*/ */
#if defined(LIBC_SCCS) && !defined(lint) #if defined(LIBC_SCCS) && !defined(lint)
static char rcsid[] = "$OpenBSD: sha1hl.c,v 1.1 1997/07/12 20:06:03 millert Exp $";
static char rcsid[] = "$OpenBSD: sha1hl.c,v 1.2 1999/08/17 09:13:12 millert Exp $";
#endif /* LIBC_SCCS and not lint */ #endif /* LIBC_SCCS and not lint */
#include <stdlib.h> #include <stdlib.h>
#include <stdio.h> #include <stdio.h>
#include <errno.h> #include <errno.h>
#include <sys/file.h>
#include <fcntl.h>
#include <sys/types.h> #include <sys/types.h>
#include <sys/uio.h> #include <sys/uio.h>
#include <unistd.h> #include <unistd.h>
@ -54,7 +54,7 @@ SHA1File (filename, buf)
SHA1Init(&ctx); SHA1Init(&ctx);
if ((fd = open(filename,O_RDONLY)) < 0)
if ((fd = open(filename, O_RDONLY)) < 0)
return(0); return(0);
while ((num = read(fd, buffer, sizeof(buffer))) > 0) while ((num = read(fd, buffer, sizeof(buffer))) > 0)


+ 3
- 3
src/lib/libutil/logwtmp.c View File

@ -1,4 +1,4 @@
/* $OpenBSD: logwtmp.c,v 1.3 1996/06/17 07:46:03 downsj Exp $ */
/* $OpenBSD: logwtmp.c,v 1.4 1999/08/17 09:13:13 millert Exp $ */
/* /*
* Copyright (c) 1988, 1993 * Copyright (c) 1988, 1993
* The Regents of the University of California. All rights reserved. * The Regents of the University of California. All rights reserved.
@ -34,14 +34,14 @@
#if defined(LIBC_SCCS) && !defined(lint) #if defined(LIBC_SCCS) && !defined(lint)
/* from: static char sccsid[] = "@(#)logwtmp.c 8.1 (Berkeley) 6/4/93"; */ /* from: static char sccsid[] = "@(#)logwtmp.c 8.1 (Berkeley) 6/4/93"; */
static char *rcsid = "$Id: logwtmp.c,v 1.3 1996/06/17 07:46:03 downsj Exp $";
static char *rcsid = "$Id: logwtmp.c,v 1.4 1999/08/17 09:13:13 millert Exp $";
#endif /* LIBC_SCCS and not lint */ #endif /* LIBC_SCCS and not lint */
#include <sys/types.h> #include <sys/types.h>
#include <sys/file.h>
#include <sys/time.h> #include <sys/time.h>
#include <sys/stat.h> #include <sys/stat.h>
#include <fcntl.h>
#include <string.h> #include <string.h>
#include <unistd.h> #include <unistd.h>
#include <utmp.h> #include <utmp.h>


+ 2
- 2
src/lib/libutil/uucplock.c View File

@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE. * SUCH DAMAGE.
* *
* $Id: uucplock.c,v 1.5 1999/03/16 01:26:02 brian Exp $
* $Id: uucplock.c,v 1.6 1999/08/17 09:13:13 millert Exp $
* *
*/ */
@ -39,9 +39,9 @@ static const char sccsid[] = "@(#)uucplock.c 8.1 (Berkeley) 6/6/93";
#endif /* not lint */ #endif /* not lint */
#include <sys/types.h> #include <sys/types.h>
#include <sys/file.h>
#include <dirent.h> #include <dirent.h>
#include <errno.h> #include <errno.h>
#include <fcntl.h>
#include <unistd.h> #include <unistd.h>
#include <signal.h> #include <signal.h>
#include <stdio.h> #include <stdio.h>


Loading…
Cancel
Save