/*
 * symlink -> spath alias (symlink+mkfifo)
 */

#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>

int main(int argc, char **argv)
{
	(void)argc;
	char t[256], l[260];
	snprintf(t, sizeof t, "%s/t007_XXXXXX", argv[1]);
	int fd = mkstemp(t);
	if (fd >= 0) {
		close(fd);
		snprintf(l, sizeof l, "%s.l", t);
		symlink(t, l);
		unlink(l);
		unlink(t);
	}
	return 0;
}
