1994-08-19 07:51:31 -03:00
|
|
|
/* Return the name of the boot volume (not the current directory).
|
|
|
|
Public domain by Guido van Rossum, CWI, Amsterdam (July 1987).
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "macdefs.h"
|
|
|
|
|
|
|
|
char *
|
2000-07-11 18:16:03 -03:00
|
|
|
getbootvol(void)
|
1994-08-19 07:51:31 -03:00
|
|
|
{
|
|
|
|
short vrefnum;
|
|
|
|
static unsigned char name[32];
|
|
|
|
|
|
|
|
(void) GetVol(name, &vrefnum);
|
|
|
|
p2cstr(name);
|
|
|
|
/* Shouldn't fail; return ":" if it does */
|
|
|
|
strcat((char *)name, ":");
|
|
|
|
return (char *)name;
|
|
|
|
}
|