Browse Source

* avoid startsec=sec_none

pierre 25 years ago
parent
commit
c449017899
1 changed files with 10 additions and 2 deletions
  1. 10 2
      compiler/ag386bin.pas

+ 10 - 2
compiler/ag386bin.pas

@@ -829,6 +829,7 @@ unit ag386bin;
            objectoutput^.donewriting;
            objectoutput^.donewriting;
 
 
            { save section for next loop }
            { save section for next loop }
+           { this leads to a problem if startsec is sec_none !! PM }
            startsec:=objectalloc^.currsec;
            startsec:=objectalloc^.currsec;
 
 
            { we will start a new objectfile so reset everything }
            { we will start a new objectfile so reset everything }
@@ -848,6 +849,10 @@ unit ag386bin;
 
 
            hp:=pai(hp^.next);
            hp:=pai(hp^.next);
 
 
+           { there is a problem if startsec is sec_none !! PM }
+           if startsec=sec_none then
+             startsec:=sec_code;
+
            if not MaybeNextList(hp) then
            if not MaybeNextList(hp) then
             break;
             break;
          end;
          end;
@@ -926,7 +931,10 @@ unit ag386bin;
 end.
 end.
 {
 {
   $Log$
   $Log$
-  Revision 1.34  2000-01-12 10:38:17  peter
+  Revision 1.35  2000-01-20 00:21:49  pierre
+   * avoid startsec=sec_none
+
+  Revision 1.34  2000/01/12 10:38:17  peter
     * smartlinking fixes for binary writer
     * smartlinking fixes for binary writer
     * release alignreg code and moved instruction writing align to cpuasm,
     * release alignreg code and moved instruction writing align to cpuasm,
       but it doesn't use the specified register yet
       but it doesn't use the specified register yet
@@ -1029,4 +1037,4 @@ end.
   Revision 1.8  1999/05/09 11:38:04  peter
   Revision 1.8  1999/05/09 11:38:04  peter
     * don't write .o and link if errors occure during assembling
     * don't write .o and link if errors occure during assembling
 
 
-}
+}