Path: utzoo!news-server.csri.toronto.edu!rutgers!maverick.ksu.ksu.edu!zaphod.mps.ohio-state.edu!usc!jarthur!nntp-server.caltech.edu!suncub.bbso.caltech.edu!EYCHANER From: eychaner@suncub.bbso.caltech.edu (Amateurgrammer) Newsgroups: comp.lang.c Subject: Re: A quick question... Message-ID: <1991Mar13.174154.12537@nntp-server.caltech.edu> Date: 13 Mar 91 17:41:54 GMT References: <1991Mar12.030759.26698@nntp-server.caltech.edu> <1991Mar12.062941.2369@nntp-server.caltech.edu>,<24247@hydra.gatech.EDU> Sender: news@nntp-server.caltech.edu Reply-To: eychaner@suncub.bbso.caltech.edu Organization: Big Bear Solar Observatory, Caltech Lines: 16 cc100aa@prism.gatech.EDU (Ray Spalding) writes: >eychaner@suncub.bbso.caltech.edu writes: >>[...] >>unsigned char *arrayptr; >>[...] >> else if (type == SHORT) { >> *(short *)arrayptr++ = othervalue(); /* Declared elsewhere */ > >I think what you want here is: > *((short *)arrayptr)++ = othervalue(); Yup. This one is what I meant. Accidentally lost a set of parentheses when I copied this in...oops...and no one else noticed! ****************************************************************************** Glenn Eychaner - Big Bear Solar Observatory - eychaner@suncub.bbso.caltech.edu "...this morning's unprecedented solar eclipse is no cause for alarm." -_Flash Gordon_