Mail Archives: djgpp/1999/12/10/07:10:09

From: ido_b AT my-deja DOT com
Newsgroups: comp.os.msdos.djgpp
Subject: __dpmi_allocate_dos_memory causes program to abort
Date: Fri, 10 Dec 1999 10:45:48 GMT
Organization: - Before you buy.
Lines: 29
Message-ID: <82qlkr$lfp$>
X-Article-Creation-Date: Fri Dec 10 09:43:53 1999 GMT
X-Http-User-Agent: Mozilla/4.0 (Windows 95;US) Opera 3.60 [en]
X-Http-Proxy: 1.0 (Squid/1.1.22) for client
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com


I read chapter 18 of the FAQ and didn't fully understand how to use software
interrupts from within my program. I used something like: __dpmi_regs regs; = ...

__dpmi_int(..., &regs);

but I need to pass a memory address of a buffer in DS:SI.
I cannot use FP_SEG and FP_OFF, so I tried
__dpmi_allocate_dos_memory  in order to get the segment.
when I call that function like this:
__adpmi_raddr adr;

adr.segment =
  __dpmi_allocate_dos_memory, it sends an abort signal and exits;

1. What's wrong with my code?
2. Is there a better way to do this?

Thanks, in advance,

Sent via
Before you buy.

- Raw text -

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