delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2023/01/29/08:17:25

X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f
X-Recipient: djgpp-workers AT delorie DOT com
X-Yandex-Fwd: 1
X-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1674998136;
bh=9bpHC41psCvablcmbOu1ipvtsuFS3EQlplzhCneMtyU=;
h=Subject:To:Message-ID:Date:From;
b=Ygc8tmgBfmD92xsVEz0MXHPZPBkMtCUfCmZU9b0Sc8/AFGn1VQKNdxy8Z+4PPwC5v
Qbm8w+Ok6l3lI4X0c1d6WIFbzSbmooHOUApKLTw7n1wuDOGeShRRmGS0Jw8XbJGhGf
4ikQkhD83cYTG7YdMX6+bXco0w9IqZUbEROOwcKk=
Authentication-Results: iva4-a626432a24f0.qloud-c.yandex.net; dkim=pass header.i=@yandex.ru
Message-ID: <efccb9e3-86b5-60b3-9afc-5066f1cfda46@yandex.ru>
Date: Sun, 29 Jan 2023 18:15:35 +0500
MIME-Version: 1.0
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101
Thunderbird/102.4.2
To: djgpp-workers AT delorie DOT com
From: "stsp (stsp2 AT yandex DOT ru) [via djgpp-workers AT delorie DOT com]" <djgpp-workers AT delorie DOT com>
Subject: [PATCH] process: add _dos_exec5()
Reply-To: djgpp-workers AT delorie DOT com

This is a multi-part message in MIME format.
--------------T0j1IvHBFF3e8YOJRHiCUZnw
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

Same as _dos_exec() but with "flags" as 5th arg.
The flags are passed to AL when calling int21/4Bh.
In addition to an execution mode in AL, freedos defines the loadhigh
flag 0x80.

--------------T0j1IvHBFF3e8YOJRHiCUZnw
Content-Type: text/x-patch; charset=UTF-8;
 name="0001-process-add-_dos_exec5.patch"
Content-Disposition: attachment; filename="0001-process-add-_dos_exec5.patch"
Content-Transfer-Encoding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------------T0j1IvHBFF3e8YOJRHiCUZnw--

- Raw text -


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