[xiph-commits] r15413 - in trunk/vorbis-tools: . ogg123
ivo at svn.xiph.org
ivo at svn.xiph.org
Sat Oct 18 16:56:51 PDT 2008
Author: ivo
Date: 2008-10-18 16:56:51 -0700 (Sat, 18 Oct 2008)
New Revision: 15413
Modified:
trunk/vorbis-tools/CHANGES
trunk/vorbis-tools/ogg123/ogg123.c
trunk/vorbis-tools/ogg123/status.c
trunk/vorbis-tools/ogg123/status.h
Log:
Unset non-blocking mode on stderr. Patch by Zden?\196?\155k P?\197?\153ikryl.
Modified: trunk/vorbis-tools/CHANGES
===================================================================
--- trunk/vorbis-tools/CHANGES 2008-10-18 18:36:12 UTC (rev 15412)
+++ trunk/vorbis-tools/CHANGES 2008-10-18 23:56:51 UTC (rev 15413)
@@ -12,6 +12,7 @@
* ogg123: fixed CPU issue when outputting to a closed pipe (#1357)
* ogg123: return value to stop decoding after buffer is shut down (#1357)
* ogg123: support for ReplayGain; requires libvorbis 1.2.1 or later (#381)
+ * ogg123: unset non-blocking mode on stderr
* oggdec: gettextized help text (#1385)
* oggdec: gettextized all strings
* oggdec: call ov_open_callbacks instead of ov_open; it works on Windows now
Modified: trunk/vorbis-tools/ogg123/ogg123.c
===================================================================
--- trunk/vorbis-tools/ogg123/ogg123.c 2008-10-18 18:36:12 UTC (rev 15412)
+++ trunk/vorbis-tools/ogg123/ogg123.c 2008-10-18 23:56:51 UTC (rev 15413)
@@ -503,6 +503,7 @@
}
playlist_array_destroy(playlist_array, items);
+ status_deinit();
exit (exit_status);
}
Modified: trunk/vorbis-tools/ogg123/status.c
===================================================================
--- trunk/vorbis-tools/ogg123/status.c 2008-10-18 18:36:12 UTC (rev 15412)
+++ trunk/vorbis-tools/ogg123/status.c 2008-10-18 23:56:51 UTC (rev 15413)
@@ -324,12 +324,18 @@
void status_init (int verbosity)
{
#if defined(HAVE_FCNTL) && defined(HAVE_UNISTD_H)
- fcntl (STDERR_FILENO, F_SETFL, O_NONBLOCK);
+ fcntl (STDERR_FILENO, F_SETFL, fcntl(STDERR_FILENO, F_GETFL) | O_NONBLOCK);
#endif
max_verbosity = verbosity;
}
+void status_deinit ()
+{
+#if defined(HAVE_FCNTL) && defined(HAVE_UNISTD_H)
+ fcntl (STDERR_FILENO, F_SETFL, fcntl(STDERR_FILENO, F_GETFL) & ~O_NONBLOCK);
+#endif
+}
void status_reset_output_lock ()
{
Modified: trunk/vorbis-tools/ogg123/status.h
===================================================================
--- trunk/vorbis-tools/ogg123/status.h 2008-10-18 18:36:12 UTC (rev 15412)
+++ trunk/vorbis-tools/ogg123/status.h 2008-10-18 23:56:51 UTC (rev 15413)
@@ -60,6 +60,7 @@
void stat_format_cleanup (stat_format_t *stats);
void status_init (int verbosity);
+void status_deinit ();
void status_reset_output_lock ();
void status_clear_line ();
void status_print_statistics (stat_format_t *stats,
More information about the commits
mailing list