/* needed functions for Amiga sox * * D. Champion, 28 Jun 1992 * * other necessities, such as * * bcopy() and index() #defines, * * can be found in "st.h" */ #include #include #include #include "amiga.h" char tmpnam_count=0; char *tmpnam(char *s) { extern char *myname; /* myname MUST exist! */ extern char tmpnam_count; char *uniqsuff=".00000000.00000000.00"; int i; strcpy (s,P_tmpdir); strncat(s,myname,B_tmpnam); /* start tmpfilename with 1st B_tmpnam chars of myname */ sprintf(uniqsuff,".%8x.%8x.%2x\0",(ULONG)FindTask(NULL),(ULONG)time(),(char)tmpnam_count); for(i=0;i