paraslash.git
13 years agomysql_selector.c: refresh selector info on com_us and com_snp
Andre Noll [Thu, 15 Mar 2007 18:42:39 +0000 (19:42 +0100)]
mysql_selector.c: refresh selector info on com_us and com_snp

13 years agoChange year in GPL header to 2007
Andre Noll [Thu, 15 Mar 2007 17:53:47 +0000 (18:53 +0100)]
Change year in GPL header to 2007

13 years agoNEWS: Update
Andre Noll [Thu, 15 Mar 2007 17:53:15 +0000 (18:53 +0100)]
NEWS: Update

13 years agofd.c: Kill para_fread() and para_fseek()
Andre Noll [Wed, 14 Mar 2007 18:22:11 +0000 (19:22 +0100)]
fd.c: Kill para_fread() and para_fseek()

as they've become unused due to the switch to memory mapped audio files.

13 years agoMerge /home/maan/scm/paraslash_fml/paraslash into mmap
Andre Noll [Wed, 14 Mar 2007 17:48:21 +0000 (18:48 +0100)]
Merge /home/maan/scm/paraslash_fml/paraslash into mmap

13 years agomp3_afh.c: More documentation updates
Andre Noll [Tue, 13 Mar 2007 23:53:40 +0000 (00:53 +0100)]
mp3_afh.c: More documentation updates

13 years agomp3_afh.c: Documentation update
Andre Noll [Tue, 13 Mar 2007 23:28:15 +0000 (00:28 +0100)]
mp3_afh.c: Documentation update

13 years agovss.c: simplify vss_eof()
Andre Noll [Tue, 13 Mar 2007 23:05:21 +0000 (00:05 +0100)]
vss.c: simplify vss_eof()

the function was never called with af == NULL, so kill the check.
This check was the only real use of this parameter, so kill the
parameter as well.

13 years agovss.c: Switch from fopen() to open()
Andre Noll [Tue, 13 Mar 2007 22:57:04 +0000 (23:57 +0100)]
vss.c: Switch from fopen() to open()

13 years agokill file parameter from get_file_info of struct audio format handler
Andre Noll [Tue, 13 Mar 2007 22:20:10 +0000 (23:20 +0100)]
kill file parameter from get_file_info of struct audio format handler

Now that all audio format handlers use mmap(), this parameter is unused.

13 years agomp3_afh.c: Switch to memory mapped input file
Andre Noll [Tue, 13 Mar 2007 22:15:57 +0000 (23:15 +0100)]
mp3_afh.c: Switch to memory mapped input file

13 years agoaac_afh: use the file mapping rather than read()
Andre Noll [Mon, 12 Mar 2007 21:33:34 +0000 (22:33 +0100)]
aac_afh: use the file mapping rather than read()

This simplifies this audio format handler quite a bit.

Also fix a bug in error.h: E_AAC_OVERRUN is an error of the aac decoder,
so move the corresponding define to where it belongs.

13 years agovss.c: Use the file mapping instead of fseek()/read()
Andre Noll [Mon, 12 Mar 2007 20:19:37 +0000 (21:19 +0100)]
vss.c: Use the file mapping instead of fseek()/read()

13 years agofirst draft of the mmap patch series
Andre Noll [Mon, 12 Mar 2007 19:38:43 +0000 (20:38 +0100)]
first draft of the mmap patch series

The purpose of these changes to para_server is to not call
read()/fseek() in the audio format handlers and in vss.c but to use
mmap() instead which should result in less code and should also be
faster and less error-prone.

This first patch implements the basic infrastructure for mmap but
keeps the file pointer so that changes may be merged step by step and
changes the ogg vorbis audio format handler to use the new mapping
of the audio file.

Subsequent patches will change the other audio format handlers and
the virtual streaming system to also use mmap instead of read()/fseek().

13 years agodccp.c was modified in 2007, so change header to reflect this
Andre Noll [Mon, 12 Mar 2007 15:18:16 +0000 (16:18 +0100)]
dccp.c was modified in 2007, so change header to reflect this

13 years agoNEWS: cosmetic menu item fix
Andre Noll [Mon, 12 Mar 2007 15:17:33 +0000 (16:17 +0100)]
NEWS: cosmetic menu item fix

13 years agoMerge ../paraslash_meins/paraslash
Andre Noll [Mon, 12 Mar 2007 15:10:05 +0000 (16:10 +0100)]
Merge ../paraslash_meins/paraslash

13 years agovss.c: rename get_song() to vss_get_audio_file()
Andre Noll [Sun, 11 Mar 2007 19:22:45 +0000 (20:22 +0100)]
vss.c: rename get_song() to vss_get_audio_file()

13 years agocomment out some noisy debug messages
Andre Noll [Sun, 11 Mar 2007 19:14:18 +0000 (20:14 +0100)]
comment out some noisy debug messages

13 years agosmall documentation cleanup
Andre Noll [Sun, 11 Mar 2007 18:19:09 +0000 (19:19 +0100)]
small documentation cleanup

13 years agocommand.c kill unused declaration of user_list
Andre Noll [Sun, 11 Mar 2007 18:18:30 +0000 (19:18 +0100)]
command.c kill unused declaration of user_list

13 years agoogg_afh.c: make two functions static
Andre Noll [Sun, 11 Mar 2007 18:17:30 +0000 (19:17 +0100)]
ogg_afh.c: make two functions static

13 years agofix doxygen comment of the init functions of all audio format handlers.
Andre Noll [Sun, 11 Mar 2007 17:59:07 +0000 (18:59 +0100)]
fix doxygen comment of the init functions of all audio format handlers.

13 years agomp3_afh.c: Kill global variable num_chunks and seconds.
Andre Noll [Sun, 11 Mar 2007 17:56:01 +0000 (18:56 +0100)]
mp3_afh.c: Kill global variable num_chunks and seconds.

num_chunks has the same meaning as chunks_total in struct audio format.
Similarly, mp3.seconds has the same meaning as afi->seconds. So use these.

13 years agokill close_audio_file handler from struct audio format.
Andre Noll [Sun, 11 Mar 2007 17:40:08 +0000 (18:40 +0100)]
kill close_audio_file handler from struct audio format.

All audio format handlers just did  fclose(), so do this from vss.c
and kill the handler. This also allows to get rid of the global
infile variable in all audio format handlers.

13 years agokill global variable af from all audio format handlers
Andre Noll [Sun, 11 Mar 2007 17:23:24 +0000 (18:23 +0100)]
kill global variable af from all audio format handlers

Also rename the argument of the init function from "p" to "afh".

13 years agoaac_afh.c: kill global variables inbuf and inbuf_len
Andre Noll [Sun, 11 Mar 2007 17:19:36 +0000 (18:19 +0100)]
aac_afh.c: kill global variables inbuf and inbuf_len

Pass them to read_chunk_table() instead.

13 years agoaac_afh.c: free the inbuffer already in aac_get_file_info()
Andre Noll [Sun, 11 Mar 2007 17:11:37 +0000 (18:11 +0100)]
aac_afh.c: free the inbuffer already in aac_get_file_info()

No need to wait for this until the audio file gets closed. This
patch also fixes two occurences of a bug where the length of the
input buffer was not set correctly.

13 years agoaac_afh.c: Kill global variable af
Andre Noll [Sun, 11 Mar 2007 16:52:59 +0000 (17:52 +0100)]
aac_afh.c: Kill global variable af

It's only used in aac_afh_init.

13 years agoaac_afh.c: Kill global variable num_chunks
Andre Noll [Sun, 11 Mar 2007 16:50:23 +0000 (17:50 +0100)]
aac_afh.c: Kill global variable num_chunks

It's already stored in afi->chunks_total

13 years agoaac_afh.c: Kill global variable inbuf_size
Andre Noll [Sun, 11 Mar 2007 16:44:14 +0000 (17:44 +0100)]
aac_afh.c: Kill global variable inbuf_size

it's constant and equals AAC_INBUF_SIZE.

13 years agointroduce struct audio_format_info
Andre Noll [Sun, 11 Mar 2007 16:34:00 +0000 (17:34 +0100)]
introduce struct audio_format_info

This further simplifies the audio format handlers. The chunk_table
and the header info is now contained in that struct which allows
to move the cleanup on eof from the audio format handlers to the
virtual streaming system.

13 years agoogg_afh.c: Kill tunetable()
Andre Noll [Sat, 10 Mar 2007 19:35:34 +0000 (20:35 +0100)]
ogg_afh.c: Kill tunetable()

A rather crappy piece of code that is (1) broken and (2) unneccessary.

13 years agoogg_afh.c: Switch to ogg vorbis callbacks
Andre Noll [Sat, 10 Mar 2007 19:31:00 +0000 (20:31 +0100)]
ogg_afh.c: Switch to ogg vorbis callbacks

This allows to call ov_clear() already during ogg_get_file_info() which
in turn simplifies ogg_close_audio_file().

This is a preparation for moving the close function of the audio
format handlers to the virtual streaming system as they all do
essentially the same now.

13 years agoREADMY.mysql: replace --enable-mysql-headers by --with-mysql-headers
Andre Noll [Sat, 10 Mar 2007 09:38:50 +0000 (10:38 +0100)]
READMY.mysql: replace --enable-mysql-headers by --with-mysql-headers

The configure option was changed some time ago, but the README file
still uses the old syntax.

13 years agosimplify dccp_set_socket() (Gerrit Renker)
Andre Noll [Fri, 9 Mar 2007 12:41:43 +0000 (13:41 +0100)]
simplify dccp_set_socket() (Gerrit Renker)

This patch kills two unneccessary setsocketopt calls
and cleans up the resulting fallout.

13 years agoaudiod: avoid busy loop on startup
Andre Noll [Mon, 5 Mar 2007 22:41:09 +0000 (23:41 +0100)]
audiod: avoid busy loop on startup

The restart barrier of the status task must be also set in case
client_open() failed. This avoids spamming the log file.

13 years agoogg_afh.c: Fix format string compiler warning
Andre Noll [Mon, 5 Mar 2007 22:39:48 +0000 (23:39 +0100)]
ogg_afh.c: Fix format string compiler warning

13 years agomysql_selector.c: mark mysql_macro_list[] const
Andre Noll [Mon, 5 Mar 2007 19:47:42 +0000 (20:47 +0100)]
mysql_selector.c: mark mysql_macro_list[] const

13 years agomysql.c: fix -Wshadow warnings
Andre Noll [Mon, 5 Mar 2007 19:40:52 +0000 (20:40 +0100)]
mysql.c: fix -Wshadow warnings

13 years agoMakefile.in: use CPPFLAGS also for target mysql.o
Andre Noll [Mon, 5 Mar 2007 19:36:31 +0000 (20:36 +0100)]
Makefile.in: use CPPFLAGS also for target mysql.o

13 years agoaac_afh.c: Make "handle" a local variable
Andre Noll [Sun, 4 Mar 2007 23:45:21 +0000 (00:45 +0100)]
aac_afh.c: Make "handle" a local variable

Also, clean up the definition of static variables.

13 years agomp3_afh.c: Mark frequencies, bitrate and frame_size_index arrays const
Andre Noll [Sun, 4 Mar 2007 23:36:14 +0000 (00:36 +0100)]
mp3_afh.c: Mark frequencies, bitrate and frame_size_index arrays const

13 years agomp3_afh.c: Kill unused mp3.filename
Andre Noll [Sun, 4 Mar 2007 23:21:27 +0000 (00:21 +0100)]
mp3_afh.c: Kill unused mp3.filename

13 years agoogg_afh.c: Kill unneccessary inclusion of fd.h
Andre Noll [Sun, 4 Mar 2007 23:18:36 +0000 (00:18 +0100)]
ogg_afh.c: Kill unneccessary inclusion of fd.h

13 years agoogg_afh.c: Kill global variable num_chunks
Andre Noll [Sun, 4 Mar 2007 23:15:38 +0000 (00:15 +0100)]
ogg_afh.c: Kill global variable num_chunks

The code is more readable if this is returned by ogg_compute_chunk_table()
and passed where neccessary.

13 years agoogg_afh.c: make vi_sampling_rate, vi_bitrate local
Andre Noll [Sun, 4 Mar 2007 23:00:31 +0000 (00:00 +0100)]
ogg_afh.c: make vi_sampling_rate, vi_bitrate local

13 years agoogg_afh.c: Kill unused vi_bitrate_nominal
Andre Noll [Sun, 4 Mar 2007 22:57:26 +0000 (23:57 +0100)]
ogg_afh.c: Kill unused vi_bitrate_nominal

13 years agoogg_afh.c: get rid of global variable max_chunk_len
Andre Noll [Sun, 4 Mar 2007 22:56:21 +0000 (23:56 +0100)]
ogg_afh.c: get rid of global variable max_chunk_len

It's only used in ogg_compute_chunk_table(). So make it a local variable.

13 years agosimplify ogg_compute_chunk_table()
Andre Noll [Sun, 4 Mar 2007 22:54:17 +0000 (23:54 +0100)]
simplify ogg_compute_chunk_table()

it rewinds the input file on entry and on exit. Do this in the caller instead
which allows to get rid of the file parameter in ogg_compute_chunk_table().

13 years agoogg_afh.c: Kill global variable infile
Andre Noll [Sun, 4 Mar 2007 22:48:29 +0000 (23:48 +0100)]
ogg_afh.c: Kill global variable infile

Pass it where neccessary instead.

13 years agoogg_afh.c: Kill superflous vi_channels
Andre Noll [Sun, 4 Mar 2007 22:39:13 +0000 (23:39 +0100)]
ogg_afh.c: Kill superflous vi_channels

13 years agoogg_afh.c: Kill unused inbuf and inbuf_size
Andre Noll [Sun, 4 Mar 2007 22:37:16 +0000 (23:37 +0100)]
ogg_afh.c: Kill unused inbuf and inbuf_size

13 years agomp3_afh.c: Kill unused inbuf and inbuf_size;
Andre Noll [Sun, 4 Mar 2007 22:34:45 +0000 (23:34 +0100)]
mp3_afh.c: Kill unused inbuf and inbuf_size;

13 years agosimplify vss_read_chunk()
Andre Noll [Sun, 4 Mar 2007 22:22:43 +0000 (23:22 +0100)]
simplify vss_read_chunk()

All its parameters are known globally within vss.c, so omit them.
Also, return an int instead of the pointer to the inbuffer which is
also known to the caller.

This patch also introduces para_fseek() in fd.c which is used by
mp3.c and vss.c and changes the mp3 audio format handler so that it
uses the new function and always check the return value.

13 years agokill the read_chunk handler of struct audio_format handler
Andre Noll [Sun, 4 Mar 2007 21:31:52 +0000 (22:31 +0100)]
kill the read_chunk handler of struct audio_format handler

chunks are now read by vss_read_chunk(), i.e. the same function is
used for all audio formats.

13 years agomake get_file_info() return the chunk table
Andre Noll [Sun, 4 Mar 2007 21:08:04 +0000 (22:08 +0100)]
make get_file_info() return the chunk table

This is a preparation for the moving the read_chunk handler to
the vss layer.

13 years agovss.c: Kill check for get_file_info == NULL
Andre Noll [Sun, 4 Mar 2007 20:54:36 +0000 (21:54 +0100)]
vss.c: Kill check for get_file_info == NULL

This can never happen.

13 years agokill the reposition handler in struct audio_format_handler
Andre Noll [Sun, 4 Mar 2007 20:35:44 +0000 (21:35 +0100)]
kill the reposition handler in struct audio_format_handler

All three audio format handlers provided only a dummy function. Kill
these as well.

13 years agounify all audio format handlers
Andre Noll [Sun, 4 Mar 2007 20:07:33 +0000 (21:07 +0100)]
unify all audio format handlers

This changes the ogg vorbis audio format handler such that its read_chunk and
reposition_stream functions coincide with those of the other audio format
handlers.

13 years agoogg_afh.c: Rename oggbuf_len to inbuf_size
Andre Noll [Sun, 4 Mar 2007 19:26:52 +0000 (20:26 +0100)]
ogg_afh.c: Rename oggbuf_len to inbuf_size

so that it matches the naming of the other audio format handlers

13 years agoogg_afh.c: Rename oggbuf to inbuf
Andre Noll [Sun, 4 Mar 2007 19:24:02 +0000 (20:24 +0100)]
ogg_afh.c: Rename oggbuf to inbuf

To make naming consistent with the aac and mp3 audio format handler.

13 years agounify aac and mp3 audio format handlers
Andre Noll [Sun, 4 Mar 2007 19:18:34 +0000 (20:18 +0100)]
unify aac and mp3 audio format handlers

This makes the mp3 audio format handler use a chunk table just like
m4a and ogg vorbis already do. Moreover, the aac and mp3 audio format
handlers now have identical read_chunk and reposition_stream handlers.

Next step is to tweak the ogg vorbis audio format handler so that
it also fits into this scheme. In the end, this allows to move
read_chunk() and reposition_stream() from the audio format handlers
one layer up to the virtual streaming system and to kill the function
pointers in struct audio_format.

The advantage of this change that it avoids duplicated/similar code, and
that new audio format handlers can added easier.

13 years agostring.c para_realloc(): report requested size on realloc failures
Andre Noll [Sun, 4 Mar 2007 19:10:27 +0000 (20:10 +0100)]
string.c para_realloc(): report requested size on realloc failures

13 years agoogg_afh.c: chunk_table is an array of type size_t
Andre Noll [Sat, 3 Mar 2007 17:51:23 +0000 (18:51 +0100)]
ogg_afh.c: chunk_table is an array of type size_t

13 years agosimplify ogg_compute_header_len()
Andre Noll [Sat, 3 Mar 2007 14:27:52 +0000 (15:27 +0100)]
simplify ogg_compute_header_len()

13 years agodccp_recv.c, stdout.h: change year in GPL header to 2007
Andre Noll [Sat, 3 Mar 2007 13:42:08 +0000 (14:42 +0100)]
dccp_recv.c, stdout.h: change year in GPL header to 2007

These two files have changed in 2007, so..

13 years agorename DB_READ, DB_WRITE to AFS_READ, AFS_WRITE
Andre Noll [Sat, 3 Mar 2007 13:26:49 +0000 (14:26 +0100)]
rename DB_READ, DB_WRITE to AFS_READ, AFS_WRITE

13 years agoMerge /fml/ag-raetsch/home/maan/scm/paraslash_meins/paraslash/
Andre Noll [Fri, 2 Mar 2007 09:20:40 +0000 (10:20 +0100)]
Merge /fml/ag-raetsch/home/maan/scm/paraslash_meins/paraslash/

13 years agoFEATURES update
Andre Noll [Fri, 2 Mar 2007 09:15:03 +0000 (10:15 +0100)]
FEATURES update

13 years agoosx_write.c: Kill sleep() on buffer underruns
Andre Noll [Fri, 2 Mar 2007 09:14:31 +0000 (10:14 +0100)]
osx_write.c: Kill sleep() on buffer underruns

This was a leftover from the mpg123 patch for mac os which does
more harm than good. It could cause para_write/para_audiod to
block under certain circumstances.

13 years agoNEWS update
Andre Noll [Thu, 1 Mar 2007 20:09:54 +0000 (21:09 +0100)]
NEWS update

13 years agostdout.h: Kill unused bufsize
Andre Noll [Thu, 1 Mar 2007 19:44:21 +0000 (20:44 +0100)]
stdout.h: Kill unused bufsize

13 years agofilter.c: Register tasks in proper order
Andre Noll [Thu, 1 Mar 2007 19:42:32 +0000 (20:42 +0100)]
filter.c: Register tasks in proper order

The order is important as it determines the order in which
the pre_select functions are going to be called by the scheduler.

In the previous code, the scheduler called stdin->pre_select _before_
filter_chain->pre_select() which gave rise to the following scenario
(note that there's no filter_chain->post_select()):

stdin->pre_select(): set stdin for reading
filter_chain->pre_select(): nothing to do
stdin->post_select(): read buffer
stdin->pre_select(): do _not_ set stdin for reading as stdin buffer is full

For para_filter, after the last there are no fds set which causes the
scheduler to use the default timeout of 1s. This had the effect that
decoding of aac files started only after a few seconds.

With the roles of interchanged tasks the scenario is as follows:

filter_chain->pre_select(): nothing to do
stdin->pre_select(): set stdin for reading
stdin->post_select(): read buffer
filter_chain->pre_select(): convert buffer
stdin->pre_select(): set stdin _again_ as stdin buffer is not full

Alternative fix might be to use filter_pre_select() also for post_select.

13 years agorename db.c to afs.c and db.h to afs.h
Andre Noll [Tue, 20 Feb 2007 20:15:53 +0000 (21:15 +0100)]
rename db.c to afs.c and db.h to afs.h

13 years agodb.c find_audio_files(): use int rather than char for cwd_fd
Andre Noll [Tue, 20 Feb 2007 20:07:33 +0000 (21:07 +0100)]
db.c find_audio_files(): use int rather than char for cwd_fd

13 years agoMerge /home/maan/scm/paraslash_fml/paraslash
Andre Noll [Tue, 20 Feb 2007 19:16:09 +0000 (20:16 +0100)]
Merge /home/maan/scm/paraslash_fml/paraslash

13 years agosimplify get_atts()
Andre Noll [Tue, 20 Feb 2007 19:14:12 +0000 (20:14 +0100)]
simplify get_atts()

remove pointless ret variable and clarify comment.

13 years agofix typo in dccp_writer
Andre Noll [Mon, 19 Feb 2007 21:24:17 +0000 (22:24 +0100)]
fix typo in dccp_writer

Again, a serious typo that causes the dccp writer to not error
out under certain circumstances.

13 years agosimplify setup_default_wng()
Andre Noll [Mon, 19 Feb 2007 21:19:20 +0000 (22:19 +0100)]
simplify setup_default_wng()

The default writer is known at compile time, so replace the code
that computes it at runtime by a #define in configure.ac.

13 years agohttp_recv.c: Fix typo in http_recv_open()
Andre Noll [Mon, 19 Feb 2007 21:06:06 +0000 (22:06 +0100)]
http_recv.c: Fix typo in http_recv_open()

Quite serious as it causes the http receiver not to error
out if get_host_info() fails.

13 years agonew codename, reset version to git
Andre Noll [Fri, 16 Feb 2007 19:24:18 +0000 (20:24 +0100)]
new codename, reset version to git

13 years agothe paraslash-0.2.15 release tarball
Andre Noll [Fri, 16 Feb 2007 19:18:18 +0000 (20:18 +0100)]
the paraslash-0.2.15 release tarball

13 years agoparaslash 0.2.15 v0.2.15
Andre Noll [Fri, 16 Feb 2007 19:13:09 +0000 (20:13 +0100)]
paraslash 0.2.15

13 years agoMakefile.in: fix target web/misc
Andre Noll [Fri, 16 Feb 2007 19:09:45 +0000 (20:09 +0100)]
Makefile.in: fix target web/misc

It depends on @PACKAGE_TARNAME@-@PACKAGE_VERSION@.tar.bz2 rather than on
paraslash-git.tar.bz2.

13 years agoMakefile.in: only build and install man pages for supported binaries
Andre Noll [Thu, 15 Feb 2007 17:42:24 +0000 (18:42 +0100)]
Makefile.in: only build and install man pages for supported binaries

This makes it possible again to install from the git repo even if not
all binaries can be build, e.g. Mac OS which always lacks para_fade
(reverts a858de7cf9437cf9a3569eb4bc297c5b0e768994).

Also, don't refuse to install and don't complain if $VARDIR
(/var/paraslash) can not be created, as this is non-fatal.

13 years agoconfigure.ac: Detect os type, add -Wl,-bind_at_load to oggvorbis ld flags on Darwin.
Andre Noll [Thu, 15 Feb 2007 16:34:00 +0000 (17:34 +0100)]
configure.ac: Detect os type, add -Wl,-bind_at_load to oggvorbis ld flags on Darwin.

This gets rid of zillions of warnings of the kind

ld: warning suggest use of -bind_at_load, as lazy binding may result in errors or different symbols being used

on Mac OS X (10.4.6)

13 years agorc4.h: add doxygen file comment
Andre Noll [Wed, 14 Feb 2007 19:42:18 +0000 (20:42 +0100)]
rc4.h: add doxygen file comment

13 years agofix client args info memory leak
Andre Noll [Tue, 13 Feb 2007 18:25:17 +0000 (19:25 +0100)]
fix client args info memory leak

13 years agofilter_chain.c, recv_common.c: Fix another memory leak
Andre Noll [Sun, 11 Feb 2007 23:18:14 +0000 (00:18 +0100)]
filter_chain.c, recv_common.c: Fix another memory leak

There was still one leak left: argv[0] gets strdupped, but never freed.

13 years agodccp_recv.c: Fix memory leak in dccp_recv_open()
Andre Noll [Sun, 11 Feb 2007 23:11:09 +0000 (00:11 +0100)]
dccp_recv.c: Fix memory leak in dccp_recv_open()

Missing freeaddrinfo().

13 years agoaudiod.c: fix memory leak in audiod_status_dump()
Andre Noll [Sun, 11 Feb 2007 23:03:25 +0000 (00:03 +0100)]
audiod.c: fix memory leak in audiod_status_dump()

missing free() for decoder flags. Quite serious: We leaked some bytes on each
status change.

13 years agofilter_chain(): Fix memory leak in parse_filter_args
Andre Noll [Sun, 11 Feb 2007 22:47:57 +0000 (23:47 +0100)]
filter_chain(): Fix memory leak in parse_filter_args

Same bug as in parse_receiver_args(): argv must be freed (see previous patch).

13 years agorecv_common: fix memory leak and invalid free in error path
Andre Noll [Sun, 11 Feb 2007 22:45:52 +0000 (23:45 +0100)]
recv_common: fix memory leak and invalid free in error path

As split_args() returns pointers that point within the given string,
it is wrong to free the individual pieces. However, the array of
substrings must be freed. parse_receiver_args() got both of these
wrong :(

13 years agocosmetics
Andre Noll [Sun, 11 Feb 2007 22:41:36 +0000 (23:41 +0100)]
cosmetics

13 years agocrypt.c: fix memory leak in para_decrypt_buffer()
Andre Noll [Sun, 11 Feb 2007 22:11:28 +0000 (23:11 +0100)]
crypt.c: fix memory leak in para_decrypt_buffer()

The client side had more or less the same memory leak as the server side:
The rsa structure wasn't freed.

13 years agofix a memory leak in the RSA key handling
Andre Noll [Sun, 11 Feb 2007 21:37:49 +0000 (22:37 +0100)]
fix a memory leak in the RSA key handling

RSA keys must be freed by using openssl's RSA_free() rather than the
usual free(). This leak turns out to be more serious as the amount
of leaked memory increased by about 300 bytes every time para_server
reread the user list (i.e. the hup command was executed or para_server
received SIGHUP).

13 years agouser_list.c: Fix a memory leak
Andre Noll [Sun, 11 Feb 2007 21:09:06 +0000 (22:09 +0100)]
user_list.c: Fix a memory leak

get_rsa_key() already allocates space for the rsa key pointer. Moreover,
u->perms was set to zero twice. Kill one instance.

13 years agosimplify lookup_user()
Andre Noll [Sun, 11 Feb 2007 20:57:49 +0000 (21:57 +0100)]
simplify lookup_user()

It's easier to just pass the name of the user to be looked up. This
fixes a memory leak btw. because u.name was strdupped and never freed.
That leak wasn't serious though as is happened in the child process.

13 years agolist.h, ortp.h: Add missing documentation
Andre Noll [Sun, 11 Feb 2007 19:29:15 +0000 (20:29 +0100)]
list.h, ortp.h: Add missing documentation