From: Silviu Simen Newsgroups: comp.os.msdos.djgpp Subject: outportb problem ? Date: Fri, 25 Sep 1998 10:14:40 +0300 Organization: EUnet Romania Lines: 30 Message-ID: <360B42E0.7A0E2FDC@ubisoft.ro> NNTP-Posting-Host: 193.226.152.153 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk I have recently ported a program originaly writen for Borland C. The same code, compiled with bcc works, but with gcc won't. Code is supposed to read CMOS data. Here is the part of code with problem: =========================================== typedef unsigned char byte; byte byte_read_cmos(byte adresa) { byte x; outportb(0x70,adresa); delay(2); x =inportb(0x71); return x; } void read_cmos(void) { byte i; byte *p; for(p=(char*)&cmos,i=0;i