Handle HAVE_ALL and HAVE_NONE. Cleanup the BITFIELD message.
[etorrent.git] / lib / etorrent-1.0 / src / etorrent_dirwatcher_sup.erl
blob4a7335e365bbf0d8253c85376a2f803187472e7c
1 %%%-------------------------------------------------------------------
2 %%% File : dirwatcher_sup.erl
3 %%% Author : Jesper Louis Andersen <jlouis@succubus.local.domain>
4 %%% License : See COPYING
5 %%% Description : Supervise the dirwatcher.
6 %%%
7 %%% Created : 11 Jul 2007 by Jesper Louis Andersen <jlouis@succubus.local.domain>
8 %%%-------------------------------------------------------------------
9 -module(etorrent_dirwatcher_sup).
11 -behaviour(supervisor).
13 %% API
14 -export([start_link/0]).
16 %% Supervisor callbacks
17 -export([init/1]).
19 -define(SERVER, ?MODULE).
21 %%====================================================================
22 %% API functions
23 %%====================================================================
24 %%--------------------------------------------------------------------
25 %% Function: start_link() -> {ok,Pid} | ignore | {error,Error}
26 %% Description: Starts the supervisor
27 %%--------------------------------------------------------------------
28 start_link() ->
29 supervisor:start_link({local, ?SERVER}, ?MODULE, []).
31 init([]) ->
32 DirWatcher = {etorrent_dirwatcher,
33 {etorrent_dirwatcher, start_link, []},
34 permanent, 2000, worker, [etorrent_dirwatcher]},
35 {ok,{{one_for_one,1,60}, [DirWatcher]}}.
37 %%====================================================================
38 %% Internal functions
39 %%====================================================================