[xiph-commits] r17719 - in trunk/ao/src/plugins: esd nas

xiphmont at svn.xiph.org xiphmont at svn.xiph.org
Mon Dec 6 12:13:20 PST 2010


Author: xiphmont
Date: 2010-12-06 12:13:20 -0800 (Mon, 06 Dec 2010)
New Revision: 17719

Modified:
   trunk/ao/src/plugins/esd/ao_esd.c
   trunk/ao/src/plugins/nas/ao_nas.c
Log:
Update ESD, NAS to accept 'server' in addition to 'host'


Modified: trunk/ao/src/plugins/esd/ao_esd.c
===================================================================
--- trunk/ao/src/plugins/esd/ao_esd.c	2010-12-06 20:09:29 UTC (rev 17718)
+++ trunk/ao/src/plugins/esd/ao_esd.c	2010-12-06 20:13:20 UTC (rev 17719)
@@ -40,7 +40,7 @@
 
 extern char **environ;
 
-static char *ao_esd_options[] = {"host","matrix","verbose","quiet","debug"};
+static char *ao_esd_options[] = {"server","host","matrix","verbose","quiet","debug"};
 static ao_info ao_esd_info =
 {
 	AO_TYPE_LIVE,
@@ -146,7 +146,7 @@
 {
 	ao_esd_internal *internal = (ao_esd_internal *) device->internal;
 
-	if (!strcmp(key, "host")) {
+	if (!strcmp(key, "host") || !strcmp(key, "server")) {
 		if(internal->host) free(internal->host);
 		internal->host = strdup(value);
 	}

Modified: trunk/ao/src/plugins/nas/ao_nas.c
===================================================================
--- trunk/ao/src/plugins/nas/ao_nas.c	2010-12-06 20:09:29 UTC (rev 17718)
+++ trunk/ao/src/plugins/nas/ao_nas.c	2010-12-06 20:13:20 UTC (rev 17719)
@@ -41,7 +41,8 @@
 #define AO_NAS_BUF_SIZE 4096
 
 static char *ao_nas_options[] = {
-  "host",    /* NAS server. See nas(1) for format. */
+  "server",    /* NAS server. See nas(1) for format. */
+  "host",    /* synonym for server */
   "buf_size", /* Buffer size on server */
   "quiet",
   "verbose",
@@ -116,7 +117,7 @@
 {
 	ao_nas_internal *internal = (ao_nas_internal *) device->internal;
 
-	if (!strcmp(key, "host")) {
+	if (!strcmp(key, "host") || !strcmp(key, "server")) {
           char *tmp = strdup (value);
  	  if (!tmp) return 0;
  	  if (internal->host) free (internal->host);



More information about the commits mailing list