into Command, an array conversion is illegal here. Uncovered by
ACATS B460005.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@47435
138bc75d-0d04-0410-961f-
82ee72b054a4
+2001-11-29 Ed Schonberg <schonber@gnat.com>
+
+ * g-os_lib.adb (Add_To_Command): use explicit loop to move string
+ into Command, an array conversion is illegal here. Uncovered by
+ ACATS B460005.
+
2001/11/28 Geert Bosch <bosch@gnat.com>
* init.c: Minor whitespace changes.
begin
Command_Last := Command_Last + S'Length;
- Command (First .. Command_Last) := Chars (S);
+
+ -- Move characters one at a time, because Command has
+ -- aliased components.
+
+ for J in S'Range loop
+ Command (First + J - S'First) := S (J);
+ end loop;
Command_Last := Command_Last + 1;
Command (Command_Last) := ASCII.NUL;