This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[vms/committed] Do not make CODE sections writable


Hi,

a one word patch to prevent CODE sections from being writable in bfd outputs.

Tristan.

bfd/
2010-08-04  Tristan Gingold  <gingold@adacore.com>

	* vms-alpha.c (alpha_vms_create_eisd_for_section): Do not make
	CODE sections writable.

diff --git a/bfd/vms-alpha.c b/bfd/vms-alpha.c
index 916c279..1f6e97f 100644
--- a/bfd/vms-alpha.c
+++ b/bfd/vms-alpha.c
@@ -2901,7 +2901,7 @@ alpha_vms_create_eisd_for_section (bfd *abfd, asection *se
 
   if (sec->flags & SEC_CODE)
     eisd->u.eisd.flags |= EISD__M_EXE;
-  if (!(sec->flags & SEC_READONLY))
+  else if (!(sec->flags & SEC_READONLY))
     eisd->u.eisd.flags |= EISD__M_WRT | EISD__M_CRF;
 
   if (!(sec->flags & SEC_LOAD))


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]