diff options
author | Bernardo Innocenti <bernie@develer.com> | 2004-07-25 22:43:23 +0200 |
---|---|---|
committer | Bernardo Innocenti <bernie@gcc.gnu.org> | 2004-07-25 22:43:23 +0200 |
commit | 5d038c4cb11480bb8ee68bdc71846a0abfe11f02 (patch) | |
tree | d0ebdb183f6e1572fbcf9e7c4fd5488f5016e704 /gcc/c-opts.c | |
parent | b12a648242a3b58bfa7a3e2d24c9f7404ab35df0 (diff) | |
download | gcc-5d038c4cb11480bb8ee68bdc71846a0abfe11f02.tar.gz |
bitmap.c: Use type-safe memory allocation macros from libiberty.
* bitmap.c: Use type-safe memory allocation macros from libiberty.
* c-common.c: Likewise.
* c-decl.c: Likewise.
* c-lang.c: Likewise.
* c-lex.c: Likewise.
* c-opts.c: Likewise.
* c-parse.in: Likewise.
* c-typeck.c: Likewise.
* genconditions.c: Likewise.
* gengtype-lex.l: Likewise.
* gengtype-yacc.y: Likewise.
* gengtype.c: Likewise.
* genmodes.c: Likewise.
* gensupport.c: Likewise.
* read-rtl.c: Likewise.
* read-rtl.c (read_constants): Use INSERT instead of TRUE in call to
htab_find_slot().
From-SVN: r85163
Diffstat (limited to 'gcc/c-opts.c')
-rw-r--r-- | gcc/c-opts.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/c-opts.c b/gcc/c-opts.c index 656aa2d9dcf..2b4ab9f76dc 100644 --- a/gcc/c-opts.c +++ b/gcc/c-opts.c @@ -226,7 +226,7 @@ c_common_init_options (unsigned int argc, const char ** ARG_UNUSED (argv)) flag_exceptions = c_dialect_cxx (); warn_pointer_arith = c_dialect_cxx (); - deferred_opts = xmalloc (argc * sizeof (struct deferred_opt)); + deferred_opts = XNEWVEC (struct deferred_opt, argc); result = lang_flags[c_language]; @@ -913,7 +913,7 @@ c_common_post_options (const char **pfilename) /* Canonicalize the input and output filenames. */ if (in_fnames == NULL) { - in_fnames = xmalloc (sizeof (in_fnames[0])); + in_fnames = XNEWVEC (const char *, 1); in_fnames[0] = ""; } else if (strcmp (in_fnames[0], "-") == 0) @@ -1256,7 +1256,7 @@ add_prefixed_path (const char *suffix, size_t chain) prefix = iprefix ? iprefix : cpp_GCC_INCLUDE_DIR; prefix_len = iprefix ? strlen (iprefix) : cpp_GCC_INCLUDE_DIR_len; - path = xmalloc (prefix_len + suffix_len + 1); + path = (char *) xmalloc (prefix_len + suffix_len + 1); memcpy (path, prefix, prefix_len); memcpy (path + prefix_len, suffix, suffix_len); path[prefix_len + suffix_len] = '\0'; |