Remove redundant errno. Prefer NAME_MAX over MAXNAMLEN.
This commit is contained in:
parent
b5311f7827
commit
840fe72e12
4 changed files with 54 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
|||
$NetBSD: distinfo,v 1.6 2005/07/11 17:29:16 veego Exp $
|
||||
$NetBSD: distinfo,v 1.7 2005/12/19 14:34:33 joerg Exp $
|
||||
|
||||
SHA1 (minicom-2.1.tar.gz) = 720273f6ee8db5fb2da4379ac610a520a31aba70
|
||||
RMD160 (minicom-2.1.tar.gz) = 58121cf29991a92914acee855d6e86486c6d370d
|
||||
|
@ -8,3 +8,6 @@ SHA1 (patch-ab) = 4cfb8bc389f4052c08551651aa86f98d0e751028
|
|||
SHA1 (patch-ac) = 91a2acce80d7d1815a29843b1de5e1acc172024a
|
||||
SHA1 (patch-ad) = 5e866091f58585a16da93fdf9d8bec417c0adc19
|
||||
SHA1 (patch-ae) = b037623c4e3ee4cbc8c73c4b04c6b7f77c689d38
|
||||
SHA1 (patch-af) = 38905432b60a796742d43be1aed84ee2774bb222
|
||||
SHA1 (patch-ag) = c8947fb6693d2508d7caa79916142af346e27cdd
|
||||
SHA1 (patch-ah) = da65045ad1d02a7c005aba863a106472d05f5c1c
|
||||
|
|
12
comms/minicom/patches/patch-af
Normal file
12
comms/minicom/patches/patch-af
Normal file
|
@ -0,0 +1,12 @@
|
|||
$NetBSD: patch-af,v 1.4 2005/12/19 14:34:33 joerg Exp $
|
||||
|
||||
--- src/wkeys.c.orig 2005-12-19 14:23:08.000000000 +0000
|
||||
+++ src/wkeys.c
|
||||
@@ -48,7 +48,6 @@ extern char *_tptr;
|
||||
|
||||
static char erasechar;
|
||||
static int gotalrm;
|
||||
-extern int errno;
|
||||
int pendingkeys = 0;
|
||||
int io_pending = 0;
|
||||
|
19
comms/minicom/patches/patch-ag
Normal file
19
comms/minicom/patches/patch-ag
Normal file
|
@ -0,0 +1,19 @@
|
|||
$NetBSD: patch-ag,v 1.3 2005/12/19 14:34:33 joerg Exp $
|
||||
|
||||
--- src/getsdir.c.orig 2005-12-19 14:23:45.000000000 +0000
|
||||
+++ src/getsdir.c
|
||||
@@ -207,9 +207,14 @@ int *len;
|
||||
int l;
|
||||
|
||||
/* copy the filename */
|
||||
+#ifdef NAME_MAX
|
||||
+ strncpy(datb_cur->data[datb_cur->cnt].fname,
|
||||
+ dp->d_name, NAME_MAX);
|
||||
+#else
|
||||
strncpy(datb_cur->data[datb_cur->cnt].fname,
|
||||
dp->d_name,
|
||||
MAXNAMLEN);
|
||||
+#endif
|
||||
|
||||
/* get information about the directory entry */
|
||||
snprintf(fpath, sizeof(fpath), "%s/%s", dirpath, dp->d_name);
|
19
comms/minicom/patches/patch-ah
Normal file
19
comms/minicom/patches/patch-ah
Normal file
|
@ -0,0 +1,19 @@
|
|||
$NetBSD: patch-ah,v 1.1 2005/12/19 14:34:33 joerg Exp $
|
||||
|
||||
--- src/getsdir.h.orig 2005-12-19 14:24:44.000000000 +0000
|
||||
+++ src/getsdir.h
|
||||
@@ -19,9 +19,14 @@
|
||||
*/
|
||||
|
||||
#include <dirent.h>
|
||||
+#include <limits.h>
|
||||
|
||||
typedef struct dirEntry { /* structure of data item */
|
||||
+#ifdef NAME_MAX
|
||||
+ char fname[NAME_MAX + 1];
|
||||
+#else
|
||||
char fname[MAXNAMLEN + 1]; /* filename + terminating null */
|
||||
+#endif
|
||||
time_t time; /* last modification date */
|
||||
mode_t mode; /* file mode (dir? etc.) */
|
||||
ushort cflags; /* caller field for convenience */
|
Loading…
Reference in a new issue