]> Zhao Yanbai Git Server - minix.git/commitdiff
get rid of leftover _DIRENT_NAME_LEN=61
authorBen Gras <ben@minix3.org>
Thu, 1 Sep 2011 16:27:28 +0000 (16:27 +0000)
committerBen Gras <ben@minix3.org>
Thu, 1 Sep 2011 16:27:28 +0000 (16:27 +0000)
commands/backup/backup.c
commands/compress/compress.c
include/minix/dirent.h
nbsd_include/sys/dirent.h

index 5d0127a5c746cd07ebf691231008d6ac91e36bf0..3c0783dbf03a4b37f25c2deccb808429bc001404 100644 (file)
@@ -43,7 +43,7 @@
 #include <stdio.h>
 #include <dirent.h>
 
-#define NAME_SIZE _DIRENT_NAME_LEN
+#define NAME_SIZE NAME_MAX
 
 #undef NARROW                  /* Width of verbose output */
 #define COPY_SIZE 4096
index 8bab386bf82b61986e5560b28da4a15e102fa34b..d2d73b731a5ca35039a27f673a3126f16850fff4 100644 (file)
@@ -575,7 +575,7 @@ char **argv;
                                        cp++;
                                else
                                        cp = ofname;
-                               if (strlen(cp) >= _DIRENT_NAME_LEN-3) 
+                               if (strlen(cp) >= NAME_MAX-3) 
                                {
                                    fprintf(stderr,"%s: filename too long to tack on .Z\n",cp);
                                    continue;
index 03b222efe88e4c421b9f7c9b88e4aea06dd7cbfb..44ff02ffb7f4840796e7507b3ce42b06d074d266 100644 (file)
@@ -46,8 +46,6 @@ typedef struct {
                                                 */
 } DIR;
 
-#define _DIRENT_NAME_LEN 61
-
 struct dirent {                /* Largest entry (8 slots) */
        ino_t           d_ino;          /* I-node number */
        off_t           d_off;          /* Offset in directory */
index 49db5d70f4fd75615adbd25b73040142ad31c73b..4fd459a3edb74357b9bd09a35724a83fdda3b1c5 100644 (file)
@@ -21,11 +21,6 @@ struct dirent {              /* Largest entry (8 slots) */
 #define        d_fileno        d_ino
 #endif
 
-#define _DIRENT_NAME_LEN 61 /* Backward compatibility with Minix. */
-#if defined(_NETBSD_SOURCE)
-#define        MAXNAMLEN       _DIRENT_NAME_LEN
-#endif
-
 
 /*
  * The _DIRENT_ALIGN macro returns the alignment of struct dirent.  It