diff options
author | Darren Tucker <dtucker@zip.com.au> | 2005-11-10 19:29:12 +1100 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2005-11-10 19:29:12 +1100 |
commit | 30d6974124fd54c5bd9f101d9e31291fc9eda1b9 (patch) | |
tree | 1a659540ea531ac03bffdde09e6c2c76b8c592e7 /openbsd-compat | |
parent | fe80d7a0683d5e8e55a9cb057f9271f9a5b883c5 (diff) |
- (dtucker) [openbsd-compat/sigact.c] Update from OpenBSD 1.3 -> 1.4.
Id and copyright sync only, there were no substantial changes we need.
Diffstat (limited to 'openbsd-compat')
-rw-r--r-- | openbsd-compat/base64.c | 5 | ||||
-rw-r--r-- | openbsd-compat/bsd-closefrom.c | 4 | ||||
-rw-r--r-- | openbsd-compat/sigact.c | 4 |
3 files changed, 7 insertions, 6 deletions
diff --git a/openbsd-compat/base64.c b/openbsd-compat/base64.c index 6eadb5c10..9a60f583b 100644 --- a/openbsd-compat/base64.c +++ b/openbsd-compat/base64.c | |||
@@ -139,7 +139,7 @@ b64_ntop(u_char const *src, size_t srclength, char *target, size_t targsize) | |||
139 | size_t datalength = 0; | 139 | size_t datalength = 0; |
140 | u_char input[3]; | 140 | u_char input[3]; |
141 | u_char output[4]; | 141 | u_char output[4]; |
142 | int i; | 142 | u_int i; |
143 | 143 | ||
144 | while (2 < srclength) { | 144 | while (2 < srclength) { |
145 | input[0] = *src++; | 145 | input[0] = *src++; |
@@ -206,7 +206,8 @@ b64_ntop(u_char const *src, size_t srclength, char *target, size_t targsize) | |||
206 | int | 206 | int |
207 | b64_pton(char const *src, u_char *target, size_t targsize) | 207 | b64_pton(char const *src, u_char *target, size_t targsize) |
208 | { | 208 | { |
209 | int tarindex, state, ch; | 209 | u_int tarindex, state; |
210 | int ch; | ||
210 | char *pos; | 211 | char *pos; |
211 | 212 | ||
212 | state = 0; | 213 | state = 0; |
diff --git a/openbsd-compat/bsd-closefrom.c b/openbsd-compat/bsd-closefrom.c index 61a9fa391..5b7b94ae4 100644 --- a/openbsd-compat/bsd-closefrom.c +++ b/openbsd-compat/bsd-closefrom.c | |||
@@ -46,7 +46,7 @@ | |||
46 | # define OPEN_MAX 256 | 46 | # define OPEN_MAX 256 |
47 | #endif | 47 | #endif |
48 | 48 | ||
49 | RCSID("$Id: bsd-closefrom.c,v 1.1 2004/08/15 08:41:00 djm Exp $"); | 49 | RCSID("$Id: bsd-closefrom.c,v 1.2 2005/11/10 08:29:13 dtucker Exp $"); |
50 | 50 | ||
51 | #ifndef lint | 51 | #ifndef lint |
52 | static const char sudorcsid[] = "$Sudo: closefrom.c,v 1.6 2004/06/01 20:51:56 millert Exp $"; | 52 | static const char sudorcsid[] = "$Sudo: closefrom.c,v 1.6 2004/06/01 20:51:56 millert Exp $"; |
@@ -67,7 +67,7 @@ closefrom(int lowfd) | |||
67 | 67 | ||
68 | /* Check for a /proc/$$/fd directory. */ | 68 | /* Check for a /proc/$$/fd directory. */ |
69 | len = snprintf(fdpath, sizeof(fdpath), "/proc/%ld/fd", (long)getpid()); | 69 | len = snprintf(fdpath, sizeof(fdpath), "/proc/%ld/fd", (long)getpid()); |
70 | if (len != -1 && len <= sizeof(fdpath) && (dirp = opendir(fdpath))) { | 70 | if (len >= 0 && (u_int)len <= sizeof(fdpath) && (dirp = opendir(fdpath))) { |
71 | while ((dent = readdir(dirp)) != NULL) { | 71 | while ((dent = readdir(dirp)) != NULL) { |
72 | fd = strtol(dent->d_name, &endp, 10); | 72 | fd = strtol(dent->d_name, &endp, 10); |
73 | if (dent->d_name != endp && *endp == '\0' && | 73 | if (dent->d_name != endp && *endp == '\0' && |
diff --git a/openbsd-compat/sigact.c b/openbsd-compat/sigact.c index d1431a0d9..8b8e4dd2c 100644 --- a/openbsd-compat/sigact.c +++ b/openbsd-compat/sigact.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* $OpenBSD: sigaction.c,v 1.3 1999/06/27 08:14:21 millert Exp $ */ | 1 | /* $OpenBSD: sigaction.c,v 1.4 2001/01/22 18:01:48 millert Exp $ */ |
2 | 2 | ||
3 | /**************************************************************************** | 3 | /**************************************************************************** |
4 | * Copyright (c) 1998 Free Software Foundation, Inc. * | 4 | * Copyright (c) 1998,2000 Free Software Foundation, Inc. * |
5 | * * | 5 | * * |
6 | * Permission is hereby granted, free of charge, to any person obtaining a * | 6 | * Permission is hereby granted, free of charge, to any person obtaining a * |
7 | * copy of this software and associated documentation files (the * | 7 | * copy of this software and associated documentation files (the * |