case PPP_DIR_RUNTIME:
path = PPP_PATH_VARRUN;
break;
+#ifdef PPP_WITH_PLUGINS
case PPP_DIR_PLUGIN:
path = PPP_PATH_PLUGIN;
break;
+#endif
case PPP_DIR_CONF:
path = PPP_PATH_CONFDIR;
break;
case PPP_DIR_RUNTIME:
path = PPP_PATH_VARRUN;
break;
+#ifdef PPP_WITH_PLUGINS
case PPP_DIR_PLUGIN:
path = PPP_PATH_PLUGIN;
break;
- case PPP_DIR_CONF:
+#endif
+ case PPP_DIR_CONF:
path = PPP_PATH_CONFDIR;
break;
}
err:
fclose(f);
+ free(option_source);
privileged_option = oldpriv;
option_source = oldsource;
return ret;
/* The name never changes, so allocate it with the structure */
if (uep == NULL) {
uep = malloc(sizeof (*uep) + (eqp-arg));
+ if (uep == NULL) {
+ novm("environment variable");
+ return 1;
+ }
strncpy(uep->ue_name, arg, eqp-arg);
uep->ue_name[eqp-arg] = '\0';
uep->ue_next = NULL;
/* The name never changes, so allocate it with the structure */
if (uep == NULL) {
uep = malloc(sizeof (*uep) + strlen(arg));
+ if (uep == NULL) {
+ novm("environment variable");
+ return 1;
+ }
strcpy(uep->ue_name, arg);
uep->ue_next = NULL;
insp = &userenv_list;