Date: Thu, 13 Sep 2001 11:23:17 +0200 (IST) From: Eli Zaretskii X-Sender: eliz AT is To: dima 3141596 cc: djgpp AT delorie DOT com Subject: Re: addressing question In-Reply-To: <9nppvi$2c8g$1@pandora.alkar.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Thu, 13 Sep 2001, dima 3141596 wrote: > I have 2 pointers: > char *seg1, *seg2; > > How can I make that any operation like on *seg1='1'; was addressed by > ES register and > *seg2='2'; by DS ? You can't, not with DJGPP: ES and DS are segment registers, and in protected mode they can only be loaded with valid segment selectors, not with any arbitrary number. If you load a value that is not a valid selector, your program will get a GPF and crash. Why do you need to do that, anyway?