delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2001/04/17/12:24:33

From: Martin Str|mberg <ams AT ludd DOT luth DOT se>
Message-Id: <200104171624.SAA29620@mother.ludd.luth.se>
Subject: Re: Stub trying to find COMSPEC=A:\COMMAND.COM\CWSDPMI.EXE!
To: djgpp-workers AT delorie DOT com
Date: Tue, 17 Apr 2001 18:24:12 +0200 (MEST)
Cc: sandmann AT clio DOT rice DOT edu (Charles Sandmann)
In-Reply-To: <10104170423.AA18680@clio.rice.edu> from "Charles Sandmann" at Apr 16, 2001 11:23:34 PM
X-Mailer: ELM [version 2.5 PL2]
MIME-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

According to Charles Sandmann:
> I looked at the stub.asm code (well, some version I have lying around
> which I am guessing is the same as the current release) and it's buggy.
> 
> There is a section:
>         call    store_env_string        ; to "loadname"
>         cmp     si, loadname            ; anything there?
>         je      do_exec                 ; final try (no path) let it return
> 
> Which won't work at all, since we never check for a difference between
> null and ; as delimiters (si == loadname only after a double null).
> A poorly thought out fix might be:                        
> 
>         call    store_env_string        ; to "loadname"
>         or      al,al                   ; check terminating char
>         jne     @f1                     ; if ; continue
>         dec     di                      ; else point at null for next pass
> @f1:
>         cmp     si, loadname            ; anything there?
>         je      do_exec                 ; final try (no path) let it return
> 
> This appears to have been there since October 1994 ...

This corrects the problem. Any objections to commiting this?


Right,

						MartiS

- Raw text -


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