BSD 4_4 release
[unix-history] / usr / src / usr.bin / uucp / libuu / gename.c
index d4d2624..a370e6b 100644 (file)
@@ -1,6 +1,15 @@
+/*-
+ * Copyright (c) 1985, 1993
+ *     The Regents of the University of California.  All rights reserved.
+ *
+ * This module is believed to contain source code proprietary to AT&T.
+ * Use and redistribution is subject to the Berkeley Software License
+ * Agreement and your Software Agreement with AT&T (Western Electric).
+ */
+
 #ifndef lint
 #ifndef lint
-static char sccsid[] = "@(#)gename.c   5.6 (Berkeley) %G%";
-#endif
+static char sccsid[] = "@(#)gename.c   8.1 (Berkeley) 6/6/93";
+#endif /* not lint */
 
 #include "uucp.h"
 
 
 #include "uucp.h"
 
@@ -61,10 +70,9 @@ char pre, *sys, grade, *file;
                        }
                        snum[SEQLEN-1] = alphabet[0];
                } else {
                        }
                        snum[SEQLEN-1] = alphabet[0];
                } else {
-                       extern int errno;
+                       syslog(LOG_WARNING, "open(%s) failed: %m", SEQFILE);
                        fd = creat(SEQFILE, 0666);
 getrandseq:            srand((int)time((time_t *)0));
                        fd = creat(SEQFILE, 0666);
 getrandseq:            srand((int)time((time_t *)0));
-                       assert(SEQFILE, "is missing or trashed\n", errno);
                        for (i = 0; i < SEQLEN; i++)
                                snum[i] = alphabet[rand() % (sizeof alphabet - 1)];
                        snum[SEQLEN-1] = alphabet[0];
                        for (i = 0; i < SEQLEN; i++)
                                snum[i] = alphabet[rand() % (sizeof alphabet - 1)];
                        snum[SEQLEN-1] = alphabet[0];