Print this page
make: fix GCC warnings

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/make/lib/mksh/macro.cc
          +++ new/usr/src/cmd/make/lib/mksh/macro.cc
↓ open down ↓ 32 lines elided ↑ open up ↑
  33   33  /*
  34   34   * Included files
  35   35   */
  36   36  #include <mksh/dosys.h>         /* sh_command2string() */
  37   37  #include <mksh/i18n.h>          /* get_char_semantics_value() */
  38   38  #include <mksh/macro.h>
  39   39  #include <mksh/misc.h>          /* retmem() */
  40   40  #include <mksh/read.h>          /* get_next_block_fn() */
  41   41  #include <mksdmsi18n/mksdmsi18n.h>      /* libmksdmsi18n_init() */
  42   42  
       43 +#include <widec.h>
       44 +
  43   45  /*
  44   46   * File table of contents
  45   47   */
  46   48  static void     add_macro_to_global_list(Name macro_to_add);
  47   49  #ifdef NSE
  48   50  static void     expand_value_with_daemon(Name name, register Property macro, register String destination, Boolean cmd);
  49   51  #else
  50   52  static void     expand_value_with_daemon(Name, register Property macro, register String destination, Boolean cmd);
  51   53  #endif
  52   54  
↓ open down ↓ 804 lines elided ↑ open up ↑
 857  859  }
 858  860  
 859  861  static void
 860  862  add_macro_to_global_list(Name macro_to_add)
 861  863  {
 862  864          Macro_list      new_macro;
 863  865          Macro_list      macro_on_list;
 864  866          char            *name_on_list = (char*)NULL;
 865  867          char            *name_to_add = macro_to_add->string_mb;
 866  868          char            *value_on_list = (char*)NULL;
 867      -        char            *value_to_add = (char*)NULL;
      869 +        const char      *value_to_add = (char*)NULL;
 868  870  
 869  871          if (macro_to_add->prop->body.macro.value != NULL) {
 870  872                  value_to_add = macro_to_add->prop->body.macro.value->string_mb;
 871  873          } else {
 872  874                  value_to_add = "";
 873  875          }
 874  876  
 875  877          /* 
 876  878           * Check if this macro is already on list, if so, do nothing
 877  879           */
↓ open down ↓ 533 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX