deviceList[_i1] = _tmpb;
deviceList[_i1] = strdup(_tmpb);
GetDeviceList (argc, argv)    int		argc;    char	**argv;{    int		i;    char	*envList = NULL;    char	*cmdList = NULL;    char	**deviceList = (char **)NULL;    char	*ttyn = NULL;    char	*p;    int		ttyfd = -1;    char	ttyE0[] = "/dev/ttyE0";    for (i = 1; i < argc; i++)	if (strcmp (argv[i], "-dev") == 0 && i+1 < argc) {	    cmdList = argv[i + 1];	    break;	}    if (!cmdList)	envList = getenv ("XDEVICE");    if (!cmdList && !envList) {	if (isatty(2))	    ttyfd = 2;	else if (isatty(0))	    ttyfd = 0;	else if (isatty(1))	    ttyfd = 1;	if (ttyfd >= 0) {	    if ((p = ttyname(ttyfd)) == NULL)		ttyn = ttyE0;	    else if (strncmp(p, ttyE0, strlen(ttyE0)-1) == 0) 		ttyn = p;	    else		ttyn = ttyE0;        } else	    ttyn = ttyE0;    }    if (cmdList || envList || ttyn) {	char	*_tmpa;	char	*_tmpb;	int	_i1;	deviceList = (char **) xalloc ((MAXSCREENS + 1) * sizeof (char *));	_tmpa = (cmdList) ? cmdList : (envList) ? envList : ttyn;	for (_i1 = 0; _i1 < MAXSCREENS; _i1++) {	    _tmpb = strtok (_tmpa, ":");	    if (_tmpb)		deviceList[_i1] = _tmpb;	    else		deviceList[_i1] = NULL;	    _tmpa = NULL;	}	deviceList[MAXSCREENS] = NULL;    }#if 0    if (!deviceList) {	/* no environment and no cmdline, so default */	deviceList =	    (char **) xalloc ((FALLBACK_LIST_LEN + 1) * sizeof (char *));	for (i = 0; i < FALLBACK_LIST_LEN; i++)	    deviceList[i] = fallbackList[i];	deviceList[FALLBACK_LIST_LEN] = NULL;    }#endif    return deviceList;}