+2001-11-13 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-elf.c (obj_elf_version): Ensure terminating NUL is
+ put in note section. Use sizeof instead of hard-coded constants.
+
2001-11-12 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
* config/tc-mips.c (support_64bit_objects): Define for OBJ_ELF only.
* config/tc-avr.c (mcu_types): Update for new devices.
-2001-11-02 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+2001-11-09 Stephane Carrez <Stephane.Carrez@worldnet.fr>
* doc/Makefile.am (POD2MAN): Use 'GNU Development Tools' for
the page man title.
{
char *name;
unsigned int c;
- char ch;
char *p;
asection *seg = now_seg;
subsegT subseg = now_subseg;
Elf_Internal_Note i_note;
Elf_External_Note e_note;
asection *note_secp = (asection *) NULL;
- int i, len;
+ int len;
SKIP_WHITESPACE ();
if (*input_line_pointer == '\"')
i_note.descsz = 0; /* no description */
i_note.type = NT_VERSION;
p = frag_more (sizeof (e_note.namesz));
- md_number_to_chars (p, (valueT) i_note.namesz, 4);
+ md_number_to_chars (p, (valueT) i_note.namesz, sizeof (e_note.namesz));
p = frag_more (sizeof (e_note.descsz));
- md_number_to_chars (p, (valueT) i_note.descsz, 4);
+ md_number_to_chars (p, (valueT) i_note.descsz, sizeof (e_note.descsz));
p = frag_more (sizeof (e_note.type));
- md_number_to_chars (p, (valueT) i_note.type, 4);
+ md_number_to_chars (p, (valueT) i_note.type, sizeof (e_note.type));
+ p = frag_more (len + 1);
+ strcpy (p, name);
- for (i = 0; i < len; i++)
- {
- ch = *(name + i);
- {
- FRAG_APPEND_1_CHAR (ch);
- }
- }
frag_align (2, 0, 0);
subseg_set (seg, subseg);