cvsuser     05/02/15 00:55:41

  Modified:    src      string.c
  Log:
  test for empty icu data dir
  
  Revision  Changes    Path
  1.231     +5 -1      parrot/src/string.c
  
  Index: string.c
  ===================================================================
  RCS file: /cvs/public/parrot/src/string.c,v
  retrieving revision 1.230
  retrieving revision 1.231
  diff -u -r1.230 -r1.231
  --- string.c  11 Jan 2005 13:09:41 -0000      1.230
  +++ string.c  15 Feb 2005 08:55:41 -0000      1.231
  @@ -1,6 +1,6 @@
   /*
   Copyright: 2001-2003 The Perl Foundation.  All Rights Reserved.
  -$Id: string.c,v 1.230 2005/01/11 13:09:41 leo Exp $
  +$Id: string.c,v 1.231 2005/02/15 08:55:41 leo Exp $
   
   =head1 NAME
   
  @@ -262,7 +262,10 @@
               build_path = data_dir = const_cast(DEFAULT_ICU_DATA_DIR);
               /*
                * if the installed --prefix directory exists then use it
  +             * but only, if data_dir isn't empty
                */
  +            if (!*data_dir)
  +                goto no_set;
               prefix = Parrot_get_runtime_prefix(interpreter, NULL);
               if (prefix) {
                   p = strstr(build_path, "blib");        /* .../blib/lib/... */
  @@ -275,6 +278,7 @@
               }
           }
           string_set_data_directory(data_dir);
  +no_set:
           if (free_data_dir)
               mem_sys_free((void*)data_dir); /* cast away the constness */
       }
  
  
  

Reply via email to