<feed xmlns='http://www.w3.org/2005/Atom'>
<title>paraslash/filter_common.c, branch pu</title>
<subtitle>paraslash - network audio streaming tools</subtitle>
<id>https://git.tue.mpg.de/cgit/paraslash/atom?h=pu</id>
<link rel='self' href='https://git.tue.mpg.de/cgit/paraslash/atom?h=pu'/>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/'/>
<updated>2026-03-17T22:45:43Z</updated>
<entry>
<title>Switch to SPDX identifiers.</title>
<updated>2026-03-17T22:45:43Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2026-03-15T14:57:29Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=ea0cecf96e08c489fdcc94d046019f4ce46f58e2'/>
<id>urn:sha1:ea0cecf96e08c489fdcc94d046019f4ce46f58e2</id>
<content type='text'>
Generated with

	sed -i 's|Copyright.*Andre Noll.*|SPDX-License-Identifier: GPL-2.0 */|g' *.c *.h

followed by manually tweaking the result a bit. No license change intended.
</content>
</entry>
<entry>
<title>Include regex.h from para.h.</title>
<updated>2025-05-19T17:35:58Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2025-05-18T20:05:45Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=67388cd4fae0cfd1674aada937f4f4d2faeeee1f'/>
<id>urn:sha1:67388cd4fae0cfd1674aada937f4f4d2faeeee1f</id>
<content type='text'>
Every .c file includes it anyway.
</content>
</entry>
<entry>
<title>Return from filter_setup() so callers can reset the terminal.</title>
<updated>2024-05-26T16:24:22Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2022-11-23T18:21:25Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=65b5042f307aebb25eed0ba42e05023ac2798b79'/>
<id>urn:sha1:65b5042f307aebb25eed0ba42e05023ac2798b79</id>
<content type='text'>
This function of filter_common.c calls exit(3) on errors. This is OK
for para_filter and para_audiod, but not for para_play because there
the function is called after readline has initialized the terminal for
its own use. If the function calls exit(3), the terminal settings are
not reset as they should have been. This can be observed for example
on the attempt to open an mp3 file with an para_play executable that
lacks mp3 support.

This commit changes the function to return an error code instead and
deals with the fallout in the three callers. Although play.c already
had error checking for calls to filter_setup(), it still needs a minor
tweak because we now have to deal with the fact that the filter and
writer node don't exist in eof_cleanup().
</content>
</entry>
<entry>
<title>filter_common: Annotate possible NULL pointer confusion.</title>
<updated>2024-05-26T16:12:45Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2024-05-13T21:25:08Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=05a0de6800ab6dc66a62bffaf3a137b4fd192b4b'/>
<id>urn:sha1:05a0de6800ab6dc66a62bffaf3a137b4fd192b4b</id>
<content type='text'>
We know at this point that filter_num is good, so filter_get()
returns non-NULL. But gcc-13's static analyzer does not see this and
warns. The added assertion makes the warning go away and tells the
reader that f == NULL is impossible here.
</content>
</entry>
<entry>
<title>Rename -&gt;{pre,post}_select methods to -&gt;{pre,post}_monitor.</title>
<updated>2022-08-25T13:37:26Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2021-10-10T16:10:09Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=e3a7e12639c34fd86d48a072beb48add8c498d09'/>
<id>urn:sha1:e3a7e12639c34fd86d48a072beb48add8c498d09</id>
<content type='text'>
The word "monitor" is neutral and continues to be correct after the
switch from select(2) to poll(2).

Pure rename, nothing to see here.
</content>
</entry>
<entry>
<title>Consolidate receiver/filter/writer {pre,post}_select() docs.</title>
<updated>2022-08-25T13:37:26Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2021-10-07T17:22:47Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=7e0a0badba66c0cdcb0dcbc8cf3d0f5b71001ca3'/>
<id>urn:sha1:7e0a0badba66c0cdcb0dcbc8cf3d0f5b71001ca3</id>
<content type='text'>
The documentation of these three -&gt;pre_select() and -&gt;post_select()
methods overlapped quite a bit. Some comments stated general properties
of the sched API which fit better in the documentation of sched.h,
so move these bits there.

Improve the text a bit while at it and avoid talking about select(2)
and fd sets as these are implementation details. Instead, focus on
the general concept of fd monitoring.

Pure comment cleanups, no code changes.
</content>
</entry>
<entry>
<title>Shorten copyright notice.</title>
<updated>2017-09-22T14:35:22Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2017-09-10T12:15:50Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=d31995b3074bb19aa4da66ce5c4774ca9ed101a1'/>
<id>urn:sha1:d31995b3074bb19aa4da66ce5c4774ca9ed101a1</id>
<content type='text'>
The GPLv2 line does not add any additional information, so drop
it. This leaves a single line of legalese text for most files, which
is about the amount of screen real estate it deserves.

This patch was created with the following script (plus some manual
fixups):

	awk '{
		if (NR &lt;= 5) {
			gs = gensub(/.*Copyright.* ([0-9]+).*Andre Noll.*/, "\\1", "g")
			if (gs != $0)
				year = gs
			next
		}
		if (NR == 6 &amp;&amp; year != "")
			printf("/* Copyright (C) %s Andre Noll &lt;maan@tuebingen.mpg.de&gt;, see file COPYING. */\n", year)
		print
	}'
</content>
</entry>
<entry>
<title>filter: Simplify FOR_EACH_FILTER().</title>
<updated>2017-08-26T19:09:42Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2017-08-14T00:00:33Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=c3237b2165f8300955db7ada200fd916c983c788'/>
<id>urn:sha1:c3237b2165f8300955db7ada200fd916c983c788</id>
<content type='text'>
Use the FILTER_CMD() macro rather than open-coding it.
</content>
</entry>
<entry>
<title>filter: Handle bad filter numbers gracefully.</title>
<updated>2017-06-14T17:54:01Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2017-06-13T20:33:26Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=c6dc6e36a70e580892d8bc190cd41376f449bdfd'/>
<id>urn:sha1:c6dc6e36a70e580892d8bc190cd41376f449bdfd</id>
<content type='text'>
This modifies filter_get() to return NULL if an invalid filter number
is given, rather than aborting the process. This way applications
can loop over all filters without having to include filter_cmd.lsg.h.

filter_name(), which also receives a filter number, has no such
sanity check and could possibly access uninitialized memory if an
invalid argument was passed. This commit adds the check and makes the
function return NULL in this case, just like filter_get(). Moreover,
the function lacked documentation, so let's add it now.
</content>
</entry>
<entry>
<title>Convert para_filter to lopsub.</title>
<updated>2017-03-26T09:02:28Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@tuebingen.mpg.de</email>
</author>
<published>2016-06-12T18:46:10Z</published>
<link rel='alternate' type='text/html' href='https://git.tue.mpg.de/cgit/paraslash/commit/?id=2b9f5ff978bcbbe0a101a4cdf4ca7f69f14a148d'/>
<id>urn:sha1:2b9f5ff978bcbbe0a101a4cdf4ca7f69f14a148d</id>
<content type='text'>
Changes the semantics in case --filter is not given. We used to
print an error, but it makes more sense to show the list of supported
filters in this case.

If no filters are given, we now print the list of available filters. A
new function in filter_common.c, print_filter_list(), is introduced
for this purpose.

The manual page of para_filter has been extended to include an overall
description of the command.

The only error code of filter.c, E_NO_FILTERS, becomes unused and is
removed.
</content>
</entry>
</feed>
