Browse Source

Don't patch on-computer file size when --outputbin is given.

git-svn-id: file:///var/svn/tigccpp/trunk@1151 9552661e-59e3-4036-b4f2-dbe53926924f
kevinkofler 17 years ago
parent
commit
5181b0125e
1 changed files with 2 additions and 1 deletions
  1. 2 1
      tigcc/ld-tigcc/export/pucrunch.c

+ 2 - 1
tigcc/ld-tigcc/export/pucrunch.c

@@ -28,6 +28,7 @@
 #include "../generic.h"
 #include "../formats/packhead.h" // compressed header definition
 #include "../formats/tios.h"
+#include "export.h"
 #include "pucrunch.h"
 
 #define VERBOSE_OUT stdout
@@ -192,7 +193,7 @@ static int SavePack(unsigned char *data, int size, EXP_FILE *fp, int escape,
         ExportWrite(fp, data, size, 1);                 // write compressed data
 
         /* Now fix the on-computer size */
-        {
+        if (!OutputBin) {
             long position = ExportTell(fp);
             HI4 packedSizeEnc;
             packedSize += 2 + sizeof (TIOS_HOST_FILE_HEADER) + sizeof (TIOS_HOST_FILE_FOOTER);