/* iras_root.c

	Copyright (c) Kapteyn Laboratorium Groningen 1991
	All Rights Reserved.

#>            iras_root.dc3

Function:     iras_root

Purpose:      provide a string containing the basename of the IRAS server

Category:     IRAS

File:         iras_root.c

Author:       Do Kester		do@guspace.rug.nl

Use:  integer iras_root_c( 
	root )		O	character*(*)

	root	the name of the IRAS root (enclosed in backslashes)

	returns the number of characters in root
		-1 : not enough characters in root

Dependent:    System dependent name; now : /rog11/

Updates:      29 Nov 1991: DK, Creation date

#<

Fortran to C interface:

@ integer function iras_root( character )

*/

#include	"gipsyc.h"
#include	"string.h"
#define		IRASROOT	"/rog11/"
#define		ROOTLENG	7		/* number of char in root */
#define		TOOSHORT	-1		/* not enough chars in root */

fint iras_root_c( 
	fchar 	root ) 
{
	if ( root.l <= ROOTLENG ) return( TOOSHORT ) ;
	strcpy( root.a, IRASROOT ) ;
	return( ROOTLENG ) ;	
}

