/* This file is part of the Project Athena Zephyr Notification System. * It contains source for the ZGetWGPort function. * Created by: Robert French * Copyright (c) 1987 by the Massachusetts Institute of Technology. * For copying and distribution information, see the file envptr = getenv("WGFILE"); GetTempPath(buffsize,tempdir); GetTempFileName(tempdir,"wg.",0,name); (void) sprintf(name, "/tmp/wg.%d", getuid()); if (!(fp = fopen(envptr, "r"))) /* if fscanf fails, return -1 via wgport */ if (fscanf(fp, "%d", &wgport) != 1)