diff --git a/ChangeLog b/ChangeLog
index 97b895af..b6a05528 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2013-09-11  Joerg Wunsch <j.gnu@uriah.heep.sax.de>
+
+	* fileio.c (fileio): Don't exit(1) if something goes wrong; return
+	-1 instead.  Don't refer to obsolete option -f to specify the file
+	format.
+
 2013-09-10  Joerg Wunsch <j.gnu@uriah.heep.sax.de>
 
 	Submitted by Matthias Trute:
diff --git a/fileio.c b/fileio.c
index 92003a5d..c636e6b2 100644
--- a/fileio.c
+++ b/fileio.c
@@ -1542,9 +1542,9 @@ int fileio(int op, char * filename, FILEFMT format,
     if (using_stdio) {
       fprintf(stderr, 
               "%s: can't auto detect file format when using stdin/out.\n"
-              "     Please specify a file format using the -f option and try again.\n", 
-              progname);
-      exit(1);
+              "%s  Please specify a file format and try again.\n", 
+              progname, progbuf);
+      return -1;
     }
 
     format = fmt_autodetect(fname);