+/*********************************************************************
+ *
+ * Function : savearg
+ *
+ * Description : Called from `load_config'. It saves each non-empty
+ * and non-comment line from config into a list. This
+ * list is used to create the show-proxy-args page.
+ *
+ * Parameters :
+ * 1 : c = config setting that was found
+ * 2 : o = the setting's argument (if any)
+ *
+ * Returns : N/A
+ *
+ *********************************************************************/
+static void savearg(char *c, char *o, struct configuration_spec * config)
+{
+ char buf[BUFFER_SIZE];
+
+ *buf = '\0';
+
+ if ( ( NULL != c ) && ( '\0' != *c ) )
+ {
+ if ((c = html_encode(c)))
+ {
+ sprintf(buf, "<a href=\"" REDIRECT_URL "option#%s\">%s</a> ", c, c);
+ }
+ freez(c);
+ }
+ if ( ( NULL != o ) && ( '\0' != *o ) )
+ {
+ if ((o = html_encode(o)))
+ {
+ if (strncmpic(o, "http://", 7) == 0)
+ {
+ strcat(buf, "<a href=\"");
+ strcat(buf, o);
+ strcat(buf, "\">");
+ strcat(buf, o);
+ strcat(buf, "</a>");
+ }
+ else
+ {
+ strcat(buf, o);
+ }
+ }
+ freez(o);
+ }
+
+ strcat(buf, "<br>\n");
+
+ config->proxy_args = strsav(config->proxy_args, buf);
+
+}
+
+