Date: Wed, 5 Mar 1997 23:51:47 -0500 (EST) From: Michael Phelps To: djgpp AT delorie DOT com Subject: Re: gettextinfo(), cprintf() question In-Reply-To: <331DABEB.72DA45E5@alcyone.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Wed, 5 Mar 1997, Erik Max Francis wrote: > Michael Phelps wrote: > > > Unless you are using C++, you need to declare this as > > struct text_info *foo; > ... > > My guess is that you want to call function gettextinfo like so: > > gettextinfo(foo); > > This will cause a crash, since foo is not pointing to anything. > Good point. I forgot: foo = (struct text_info *)malloc(sizeof(struct text_info)); > Try: > > struct text_info foo; > gettextinfo(&foo); > > -- > Erik Max Francis, &tSftDotIotE / email: max AT alcyone DOT com > Alcyone Systems / web: http://www.alcyone.com/max/ > San Jose, California, United States / icbm: 37 20 07 N 121 53 38 W > \ > "I am become death, / destroyer of worlds." > / J. Robert Oppenheimer (quoting legend) > ---Michael Phelps morphine AT cs DOT jhu DOT edu CH3 | N / | ______/ | / \ CH2 _____/ \__|__ // \\ / | \\ // \\______/___CH2 \\ \ / \ / \______/ \_____/ / ------ \ / \ OH \ / OH O Morphine