]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Rename FILESYSTEM_PREFIX_LEN.
authorBruno Haible <bruno@clisp.org>
Sun, 8 Aug 2004 16:58:11 +0000 (16:58 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 23 Jun 2009 10:11:53 +0000 (12:11 +0200)
gettext-runtime/intl/ChangeLog
gettext-runtime/intl/relocatable.c
gettext-tools/lib/ChangeLog
gettext-tools/lib/basename.c
gettext-tools/lib/concatpath.c
gettext-tools/lib/pathname.h
gettext-tools/lib/progreloc.c
gettext-tools/lib/relocatable.c

index 29ccf0b080ae6bd0db7f25f57d37f680ba0949a7..b6c3c03ee51aabfc2d6ce59515ac1a94d1d06246 100644 (file)
@@ -1,3 +1,9 @@
+2004-08-08  Bruno Haible  <bruno@clisp.org>
+
+       * relocatable.c (FILE_SYSTEM_PREFIX_LEN): Renamed from
+       FILESYSTEM_PREFIX_LEN.
+       (compute_curr_prefix): Update.
+
 2004-05-14  Bruno Haible  <bruno@clisp.org>
 
        * vasnprintf.c (VASNPRINTF): Correctly handle the case of a precision
index c14b53f97d5bd97816fce921f72ccec8a79f50e0..2683ace717893d917662384493372ae79016b87d 100644 (file)
      && (P)[1] == ':')
 # define IS_PATH_WITH_DIR(P) \
     (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P))
-# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
+# define FILE_SYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
 #else
   /* Unix */
 # define ISSLASH(C) ((C) == '/')
 # define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL)
-# define FILESYSTEM_PREFIX_LEN(P) 0
+# define FILE_SYSTEM_PREFIX_LEN(P) 0
 #endif
 
 /* Original installation prefix.  */
@@ -189,7 +189,7 @@ compute_curr_prefix (const char *orig_installprefix,
 
   /* Determine the current installation directory.  */
   {
-    const char *p_base = curr_pathname + FILESYSTEM_PREFIX_LEN (curr_pathname);
+    const char *p_base = curr_pathname + FILE_SYSTEM_PREFIX_LEN (curr_pathname);
     const char *p = curr_pathname + strlen (curr_pathname);
     char *q;
 
@@ -216,7 +216,7 @@ compute_curr_prefix (const char *orig_installprefix,
     const char *rp = rel_installdir + strlen (rel_installdir);
     const char *cp = curr_installdir + strlen (curr_installdir);
     const char *cp_base =
-      curr_installdir + FILESYSTEM_PREFIX_LEN (curr_installdir);
+      curr_installdir + FILE_SYSTEM_PREFIX_LEN (curr_installdir);
 
     while (rp > rel_installdir && cp > cp_base)
       {
index 80b1b9bf7530f6b19ae1e6962e71426c4a8c8f0c..2d21a87e209d2f758ad02214c8d323435218d6fa 100644 (file)
@@ -1,3 +1,16 @@
+2004-08-08  Bruno Haible  <bruno@clisp.org>
+
+       * pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
+       FILESYSTEM_PREFIX_LEN.
+       * progreloc.c: Likewise.
+       * concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
+       * basename.c (FILE_SYSTEM_PREFIX_LEN): Renamed from
+       FILESYSTEM_PREFIX_LEN.
+       (basename): Update.
+       * relocatable.c (FILE_SYSTEM_PREFIX_LEN): Renamed from
+       FILESYSTEM_PREFIX_LEN.
+       (compute_curr_prefix): Update.
+
 2004-05-27  Bruno Haible  <bruno@clisp.org>
 
        * execute.c (environ): Declare if needed.
index d993347383ab0c81eb823b746fd027b2a80fabff..8fd3438273611f3a052d18b3e63da9ea50c940ea 100644 (file)
 # define HAS_DEVICE(P) \
     ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
      && (P)[1] == ':')
-# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
+# define FILE_SYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
 # define ISSLASH(C) ((C) == '/' || (C) == '\\')
 #endif
 
-#ifndef FILESYSTEM_PREFIX_LEN
-# define FILESYSTEM_PREFIX_LEN(Filename) 0
+#ifndef FILE_SYSTEM_PREFIX_LEN
+# define FILE_SYSTEM_PREFIX_LEN(Filename) 0
 #endif
 
 #ifndef ISSLASH
@@ -63,7 +63,7 @@
 char *
 basename (char const *name)
 {
-  char const *base = name += FILESYSTEM_PREFIX_LEN (name);
+  char const *base = name += FILE_SYSTEM_PREFIX_LEN (name);
   int all_slashes = 1;
   char const *p;
 
index cce81d6791049941853d6945b184a7a09ca473b9..4ca3c1e433d75ccd878568337d2fc60f85acbf86 100644 (file)
@@ -53,7 +53,7 @@ concatenated_pathname (const char *directory, const char *filename,
     {
       size_t directory_len = strlen (directory);
       int need_slash =
-       (directory_len > FILESYSTEM_PREFIX_LEN (directory)
+       (directory_len > FILE_SYSTEM_PREFIX_LEN (directory)
         && !ISSLASH (directory[directory_len - 1]));
       result = (char *) xmalloc (directory_len + need_slash
                                 + strlen (filename)
index 1bce49bf7a3faa7af438eaf6b17191170b187dd8..418acae8e600cf0fdb2d31695ef45ef1f0f5db20 100644 (file)
@@ -38,13 +38,13 @@ extern "C" {
 # define IS_ABSOLUTE_PATH(P) (ISSLASH ((P)[0]) || HAS_DEVICE (P))
 # define IS_PATH_WITH_DIR(P) \
     (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P))
-# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
+# define FILE_SYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
 #else
   /* Unix */
 # define ISSLASH(C) ((C) == '/')
 # define IS_ABSOLUTE_PATH(P) ISSLASH ((P)[0])
 # define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL)
-# define FILESYSTEM_PREFIX_LEN(P) 0
+# define FILE_SYSTEM_PREFIX_LEN(P) 0
 #endif
 
 /* Concatenate a directory pathname, a relative pathname and an optional
index 21a2c810c13120605d86cec7480a445d276b2e33..22f2350063a9dd6758d008c56d7bfcddc743e766 100644 (file)
      && (P)[1] == ':')
 # define IS_PATH_WITH_DIR(P) \
     (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P))
-# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
+# define FILE_SYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
 #else
   /* Unix */
 # define ISSLASH(C) ((C) == '/')
 # define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL)
-# define FILESYSTEM_PREFIX_LEN(P) 0
+# define FILE_SYSTEM_PREFIX_LEN(P) 0
 #endif
 
 #undef set_program_name
index c14b53f97d5bd97816fce921f72ccec8a79f50e0..2683ace717893d917662384493372ae79016b87d 100644 (file)
      && (P)[1] == ':')
 # define IS_PATH_WITH_DIR(P) \
     (strchr (P, '/') != NULL || strchr (P, '\\') != NULL || HAS_DEVICE (P))
-# define FILESYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
+# define FILE_SYSTEM_PREFIX_LEN(P) (HAS_DEVICE (P) ? 2 : 0)
 #else
   /* Unix */
 # define ISSLASH(C) ((C) == '/')
 # define IS_PATH_WITH_DIR(P) (strchr (P, '/') != NULL)
-# define FILESYSTEM_PREFIX_LEN(P) 0
+# define FILE_SYSTEM_PREFIX_LEN(P) 0
 #endif
 
 /* Original installation prefix.  */
@@ -189,7 +189,7 @@ compute_curr_prefix (const char *orig_installprefix,
 
   /* Determine the current installation directory.  */
   {
-    const char *p_base = curr_pathname + FILESYSTEM_PREFIX_LEN (curr_pathname);
+    const char *p_base = curr_pathname + FILE_SYSTEM_PREFIX_LEN (curr_pathname);
     const char *p = curr_pathname + strlen (curr_pathname);
     char *q;
 
@@ -216,7 +216,7 @@ compute_curr_prefix (const char *orig_installprefix,
     const char *rp = rel_installdir + strlen (rel_installdir);
     const char *cp = curr_installdir + strlen (curr_installdir);
     const char *cp_base =
-      curr_installdir + FILESYSTEM_PREFIX_LEN (curr_installdir);
+      curr_installdir + FILE_SYSTEM_PREFIX_LEN (curr_installdir);
 
     while (rp > rel_installdir && cp > cp_base)
       {