[xiph-commits] r13997 - trunk/ezstream/src

moritz at svn.xiph.org moritz at svn.xiph.org
Tue Oct 16 07:44:42 PDT 2007


Author: moritz
Date: 2007-10-16 07:44:42 -0700 (Tue, 16 Oct 2007)
New Revision: 13997

Modified:
   trunk/ezstream/src/ezstream.c
Log:
Return a proper error message when there's no more data to read from standard
input.


Modified: trunk/ezstream/src/ezstream.c
===================================================================
--- trunk/ezstream/src/ezstream.c	2007-10-16 14:28:23 UTC (rev 13996)
+++ trunk/ezstream/src/ezstream.c	2007-10-16 14:44:42 UTC (rev 13997)
@@ -855,7 +855,10 @@
 		if (errno == EINTR) {
 			clearerr(filepstream);
 			ret = STREAM_CONT;
-		} else
+		} else if (errno == EBADF && isStdin)
+			printf("%s: No (more) data available on standard input\n",
+			       __progname);
+		else
 			printf("%s: sendStream(): Error while reading '%s': %s\n",
 			       __progname, fileName, strerror(errno));
 	}



More information about the commits mailing list