aboutsummaryrefslogtreecommitdiffstats
path: root/src/update.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* all: Update copyright header.Avuton Olrich2009-03-131-7/+7
| | | | | | | | This updates the copyright header to all be the same, which is pretty much an update of where to mail request for a copy of the GPL and the years of the MPD project. This also puts all committers under 'The Music Player Project' umbrella. These entries should go individually in the AUTHORS file, for consistancy.
* event_pipe: added pipe_event enum and callbacksMax Kellermann2009-01-011-2/+0
| | | | | | | | | Make the event_pipe (formerly main_notify) send/receive a set of events, with a callback for each one. The default event PIPE_EVENT_SIGNAL does not have a callback. It is still there for waking up the main thread, when it is waiting for the player thread.
* update: added update_global_init() and update_global_finish()Max Kellermann2008-11-271-0/+4
| | | | | | Those two functions are called when MPD starts and exits. It allows the update library to perform global initialization and deinitialization. The implementations are currently empty.
* added prefix to header macrosMax Kellermann2008-10-311-2/+2
| | | | | | | "LOG_H" is a macro which is also used by ffmpeg/log.h. This is ffmpeg's fault, because short macros should be reserved for applications, but since it's always a good idea to choose prefixed macro names, even for applications, we are going to do that in MPD.
* update: make the job id unsignedMax Kellermann2008-10-091-2/+4
| | | | Since the return value cannot be -1 anymore, we can make it unsigned.
* update: job ID must be positiveMax Kellermann2008-10-091-2/+2
| | | | | | | The documentation for directory_update_init() was incorrect: a job ID must be positive, not non-negative. If the update queue is full and no job was created, it makes more sense to return 0 instead of -1, because it is more consistent with the return value of isUpdatingDB().
* update: don't export updateDirectory()Max Kellermann2008-10-091-11/+0
| | | | | | | | If the user requests database update during startup, call directory_update_init(). This should be changed to fully asynchronous update later. For this to work, main_notify has to be initialized before db_init().
* directory: converted typedef Directory to struct directoryMax Kellermann2008-10-081-2/+2
| | | | | The struct can be forward-declared by other headers, which relaxes the header dependencies.
* update: merged exploreDirectory() into updateDirectory()Max Kellermann2008-10-081-1/+1
| | | | | | exploreDirectory() duplicates some code in updateDirectory(). Merge both functions, and use directory_is_empty() to determine whether update or explore mode should be used.
* directory: moved code to update.cMax Kellermann2008-10-081-0/+45
The source directory.c mixes several libraries: directory object management, database management and database update, resulting in a 1000+ line monster. Move the whole database update code to update.c.