diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d8c5125c17cb..7f024889c463 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2010-09-24 Iain Sandoe + Dominique Dhumieres + + PR bootstrap/45751 + * gcc/config/darwin-driver.c (darwin_default_min_version): + Adjust size passed to memcpy in two places. + 2010-09-24 Richard Guenther * c-decl.c (pop_scope): Always set file-scope DECL_CONTEXT. diff --git a/gcc/config/darwin-driver.c b/gcc/config/darwin-driver.c index 099226c25d32..1123aa37c438 100644 --- a/gcc/config/darwin-driver.c +++ b/gcc/config/darwin-driver.c @@ -76,7 +76,7 @@ darwin_default_min_version (unsigned int *decoded_options_count, generate_option (OPT_mmacosx_version_min_, macosx_deployment_target, 1, CL_DRIVER, &(*decoded_options)[1]); memcpy (*decoded_options + 2, argv + 1, - (argc - 1) * sizeof (struct cl_decoded_option *)); + (argc - 1) * sizeof (struct cl_decoded_option)); return; } } @@ -128,7 +128,7 @@ darwin_default_min_version (unsigned int *decoded_options_count, generate_option (OPT_mmacosx_version_min_, new_flag, 1, CL_DRIVER, &(*decoded_options)[1]); memcpy (*decoded_options + 2, argv + 1, - (argc - 1) * sizeof (struct cl_decoded_option *)); + (argc - 1) * sizeof (struct cl_decoded_option)); return; parse_failed: