示例#1
0
/* get no-spaces version of R_HOME from the module path: 
   used in Rgui, Rterm and Rcmd
*/
char *getRHOME(int m)
{
    char *p;
    int hasspace = 0;

    getRHOMElong(m);
    /* make sure no spaces in path */
    for (p = rhomebuf; *p; p++)
	if (isspace(*p)) { hasspace = 1; break; }
    if (hasspace)
	GetShortPathName(rhomebuf, rhomebuf, MAX_PATH);
    return (rhomebuf);
}
示例#2
0
文件: rhome.c 项目: radfordneal/pqR
/* get no-spaces version of R_HOME from the module path: 
   used in Rgui, Rterm and Rcmd
*/
char *getRHOME(int m)
{
    char *p;
    int hasspace = 0;

    getRHOMElong(m);
    /* make sure no spaces in path */
    for (p = rhomebuf; *p; p++)
	if (isspace(*p)) { hasspace = 1; break; }
    if (hasspace)
	/* NOTE: this fails when short names are not enabled */
	GetShortPathName(rhomebuf, rhomebuf, MAX_PATH);
    return (rhomebuf);
}