/*
 *  filename.C from ObjectProDSP 0.1
 *  Copyright (C) 1994, Mountain Math Software, All rights reserved.
 *  Licensed for free use and distribution under version 2 of the Gnu General
 *  Public License. Please see file COPYING for details and restrictions.
 *  
 *  ObjectProDSP is a trademark of Mountain Math Software.
 */
#include <string.h>

#include "filename.h"

char * MakeFullName(const char * DirName,const char * Name, const char * sub)
{
	int Start = 0;
	if (sub) Start=1+strlen(sub);
	char * Tname = new char [strlen(Name)+strlen(DirName) +2+Start];
	strcpy(Tname,DirName);
	strcat(Tname,"/");
	if (sub) {
		strcat(Tname,sub);
		strcat(Tname,"/");
	}
	strcat(Tname,Name);
	return Tname ;
}

