To: djgpp AT delorie DOT com Date: Wed, 03 May 2000 06:12:22 0000 From: "nimrod a. abing" Message-ID: Mime-Version: 1.0 Cc: eliz AT is DOT elta DOT co DOT il X-Sent-Mail: off X-Mailer: MailCity Service Subject: Re: gdb problem or just silly me - please help X-Sender-Ip: 208.160.246.197 Organization: QUALCOMM Eudora Web-Mail (http://www.eudoramail.com:80) Content-Type: text/plain; charset=us-ascii Content-Language: en Content-Transfer-Encoding: 7bit Reply-To: djgpp AT delorie DOT com On Tue, 2 May 2000 14:10:13 Eli Zaretskii wrote: > >On Tue, 2 May 2000, nimrod a. abing wrote: > >> BTW. Why does it crash? Isn't `char *stringtable[]' >> equivalent to `char **stringtable'? Please explain >> what happens. > >I don't have the source anymore, so I cannot comment on your >questions. As far as I remember, the code dereferenced a NULL >pointer. > Here it is again: code in file1.c: char *a_string_array[] = { "Now is the time for all good men", "To destroy the earth", "And have beer parties across the galaxy.", "" }; code in file2.c: #include extern char **a_string_array; int main(void) { int i=0; char *a_string; a_string = a_string_array[i]; while (a_string[0]) { printf("%s\n", a_string); i++; a_string = a_string_array[i]; } return 0; } Good thing I save my messages. Now in most C books, they say `char **string_array' is equivalent to `char *string_array[]'. Now why does it crash? >I was just pointing out that lobbying people to remove Windows while >you yourself are using it looks---how shall I put it?---odd... Yes, it is ;-). What was I thinking? But during the time I wrote my sig, I thought of nothing else. (Have any good ones?) >> Just a thought, has anyone figured out how to use LFN >> from MS-DOS mode in Win9x? In DOS mode, Win9x seems to >> forget how to read long file names. > >You can't. The LFN support is part of the Windows file I/O layer, >and that part of Windows is shut down when you go to DOS mode. > There was a thread discussing this a few days back. But I never pay much attention to these things. But if I know those MS guys, the VFAT entries for LFN must be stored somewhere on the disk. Methinks a TSR can do this. It should be possible to read and write these entries in DOS mode using a TSR program. It loads into memory when Windows shuts down to DOS mode and replaces that part of Windows that does the LFN thing in GUI mode. But then again, why do all that unecessary work? That's why I still use Windows when I program using DJGPP. --- nimrod_a_abing No sig for now... Join 18 million Eudora users by signing up for a free Eudora Web-Mail account at http://www.eudoramail.com