Index: usr.sbin/newsyslog/newsyslog.c =================================================================== --- usr.sbin/newsyslog/newsyslog.c +++ usr.sbin/newsyslog/newsyslog.c @@ -809,7 +809,6 @@ struct include_entry *inc; int gmatch, fnres; - defconf = NULL; STAILQ_INIT(&inclist); filelist = malloc(sizeof(struct cflist)); @@ -841,7 +840,7 @@ if (verbose) printf("Processing %s\n", inc->file); - parse_file(f, filelist, globlist, defconf, &inclist); + parse_file(f, filelist, globlist, NULL, &inclist); (void) fclose(f); } @@ -855,25 +854,19 @@ if (*files == NULL) { expand_globs(filelist, globlist); free_clist(globlist); - if (defconf != NULL) - free_entry(defconf); return (filelist); - /* NOTREACHED */ } /* * If newsyslog was given a specific list of files to process, * it may be that some of those files were not listed in any * config file. Those unlisted files should get the default - * rotation action. First, create the default-rotation action - * if none was found in a system config file. + * rotation action. First, create the default-rotation action. */ - if (defconf == NULL) { - defconf = init_entry(DEFAULT_MARKER, NULL); - defconf->numlogs = 3; - defconf->trsize = 50; - defconf->permissions = S_IRUSR|S_IWUSR; - } + defconf = init_entry(DEFAULT_MARKER, NULL); + defconf->numlogs = 3; + defconf->trsize = 50; + defconf->permissions = S_IRUSR|S_IWUSR; /* * If newsyslog was run with a list of specific filenames,