From: Sam Tebbs Date: Wed, 28 Nov 2018 17:08:17 +0000 (+0000) Subject: [PATCH][GCC][AARCH64] Replace calls to strtok with strtok_r in aarch64 attribute... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7185a4ebc2121b9bef7f8697ad432e55a4ab5d25;p=gcc.git [PATCH][GCC][AARCH64] Replace calls to strtok with strtok_r in aarch64 attribute handling code 2018-11-28 Sam Tebbs * config/aarch64/aarch64.c (aarch64_process_target_attr): Replace calls to strtok with strtok_r. From-SVN: r266570 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 695c1ff6093..2e4af6f97f7 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2018-11-28 Sam Tebbs + + * config/aarch64/aarch64.c (aarch64_process_target_attr): Replace + calls to strtok with strtok_r. + 2018-11-28 Richard Biener PR tree-optimization/88223 diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c index 496cf7117ad..3d597ca95c7 100644 --- a/gcc/config/aarch64/aarch64.c +++ b/gcc/config/aarch64/aarch64.c @@ -12017,7 +12017,7 @@ aarch64_process_target_attr (tree args) unsigned int num_commas = num_occurences_in_str (',', str_to_check); /* Handle multiple target attributes separated by ','. */ - char *token = strtok (str_to_check, ","); + char *token = strtok_r (str_to_check, ",", &str_to_check); unsigned int num_attrs = 0; while (token) @@ -12029,7 +12029,7 @@ aarch64_process_target_attr (tree args) return false; } - token = strtok (NULL, ","); + token = strtok_r (NULL, ",", &str_to_check); } if (num_attrs != num_commas + 1)