delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2000/09/07/10:53:36

From: Martin Stromberg <Martin DOT Stromberg AT lu DOT erisoft DOT se>
Message-Id: <200009071453.QAA05356@lws256.lu.erisoft.se>
Subject: djasm.y and start of .EXEs
To: djgpp-workers AT delorie DOT com (DJGPP-WORKERS)
Date: Thu, 7 Sep 2000 16:53:00 +0200 (MET DST)
X-Mailer: ELM [version 2.5 PL3]
MIME-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com

Snippet from djasm.y:

>   exe[20] = start_ptr;          /* IP */
>   exe[21] = start_ptr >> 8;
>   exe[22] = 0;                  /* relative CS */
>   exe[23] = 0;
> 
>   time(&now);
>   sprintf(exe+28, "\r\n%s generated from %s by djasm, on %.24s\r\n", argv[2], argv[1], ctime(&now));
>   if (copyright)
>     strncat(exe+36, copyright, 476-strlen(exe+36));
>   strcat(exe+36, "\r\n\032");


I understand why it says 476-strlen(exe+36), I think, as 476+36 is
512. But why 36? Why not 28, which I probably would have used?


Right,

						MartinS

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019