Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!sri-spam!ames!oliveb!sun!cmcmanis From: cmcmanis@sun.uucp (Chuck McManis) Newsgroups: comp.sys.amiga Subject: Re: Garbage in argv[] w/Lattice C (and arg limits) Message-ID: <9823@sun.uucp> Date: Tue, 2-Dec-86 13:42:32 EST Article-I.D.: sun.9823 Posted: Tue Dec 2 13:42:32 1986 Date-Received: Tue, 2-Dec-86 21:41:18 EST References: <8612011757.AA11780@cory.Berkeley.EDU> Organization: Sun Microsystems, Inc. Lines: 25 Summary: Fixed in the 3.10 release A couple of people have mentioned that they didn't like the way the Lattice code handled putting the arguments into argc and argv. If you have version 3.03 or below (Amiga C 1.1 = Lattice 3.03) then your best bet is to get the new main.c module off the developers "include" disk. (beta, gamma, release, doesn't matter) Or you can hack the copy you have (it's in the 'source' directory on the Lattice disk, I don't know where it would be on the Amiga C disk) One of the new features of the 3.10 compiler is that if you have been launched (nice term) from the workbench argv points to the workbench startup message. Also file handles (like stdin) are now Amiga Filehandles and *not* and index into a table so you can't assume they are file numbers 0,1,and 2 but you can use Andy Finkel's method of tracking down the window that they are connected to and modifying it. Final note, for 3.03 and Amiga C users, if your code gets a recoverable alert at startup under 1.2 check the c.a module is sources to make sure it either clears D0 or sets it to LIBRARY_REV before it calls OpenLibrary on the Dos library. -- --Chuck McManis uucp: {anywhere}!sun!cmcmanis BIX: cmcmanis ARPAnet: cmcmanis@sun.com These opinions are my own and no one elses, but you knew that didn't you.