| delorie.com/archives/browse.cgi | search | 
| From: | "Michael" <melias AT mediaone DOT net> | 
| Newsgroups: | comp.os.msdos.djgpp | 
| Subject: | Help getting around segread | 
| Lines: | 33 | 
| X-Newsreader: | Microsoft Outlook Express 4.72.3110.1 | 
| X-MimeOLE: | Produced By Microsoft MimeOLE V4.72.3155.0 | 
| Message-ID: | <2Sbg4.6437$eO5.86576@news1.mia> | 
| Date: | Sat, 15 Jan 2000 23:34:47 -0500 | 
| NNTP-Posting-Host: | 209.214.141.105 | 
| X-Trace: | news1.mia 947997182 209.214.141.105 (Sat, 15 Jan 2000 23:33:02 EST) | 
| NNTP-Posting-Date: | Sat, 15 Jan 2000 23:33:02 EST | 
| To: | djgpp AT delorie DOT com | 
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp | 
| Reply-To: | djgpp AT delorie DOT com | 
It was brought to my attention that the segread function does not exisit in
DJGPP.  I understand that DJGPP uses the _my_cs, _my_ds, and
_my_ss functions for the same purpose as segread but I have no idea how to
implement them.  Does anyone know how to get around this?
My program won't compile because it states that segread is undefined.  Any
help at all would be much appreciated.
        //
        //  Make call to the Btrieve Record Manager.
        //
        rmidb->rm.edx = NULL;
// always at start of segment
        rmidb->rm.ds  = DOSBuffSeg;                                      //
our real mode segment value
        rmidb->rm.sp  = rmidb->rm.ss  = NULL;                     // use
DPMI stack
        regs.w.ax  = 0x300;
        regs.h.bh  = 0;
        regs.h.bl  = BTR_INT;
        regs.w.cx  = NULL;
        regs.x.edi = offsetof(RMIDB,rm);
        segread(&sregs);
        sregs.es   = DOSBuffDes;
        int386x(DPMI,®s,®s,&sregs);
        if( regs.x.cflag ) return BTR_ERR;
Mike
| webmaster | delorie software privacy | 
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |