anchor.diff:      try vmq_queue:start_link(SubscriberId, Clean) of
           {ok, Pid} ->
               ets:insert(QueueTab, {SubscriberId, Pid}),
  -            put(Pid, true),
               reply(Caller, {ok, false, Pid}),
               NrOfChildren + 1;
           Ret ->
  
positive.code: %% Kill all children and then exit. We unlink first to avoid
  %% getting a message for each child getting killed.
  terminate(#state{shutdown=brutal_kill, queue_tab = QueueTab}, _, Reason) ->
      ets:delete_all_objects(QueueTab),
      _ = [begin
               unlink(P),
               exit(P, kill)
           end || P <- get_keys(true)],
      exit(Reason);
  %% Attemsupervisor.htmlpt to gracefully shutdown all children.
  terminate(#state{shutdown=Shutdown, queue_tab = QueueTab}, NrOfChildren, Reason) ->
      ets:delete_all_objects(QueueTab),
      shutdown_children(),
      case Shutdown of
          infinity ->
              ok;
          _ ->
              erlang:send_after(Shutdown, self(), kill)
      end,
      wait_children(NrOfChildren),
      exit(Reason).
  
  shutdown_children() ->
      _ = [begin
               monitor(process, P),
               unlink(P),
               exit(P, shutdown)
           end || P <- get_keys(true)],
      ok.
  
  wait_children(0) -> ok;
  wait_children(NrOfChildren) ->
      receive
          {'DOWN', _, process, Pid, _} ->
              _ = erase(Pid),
              wait_children(NrOfChildren - 1);
          kill ->
              _ = [exit(P, kill) || P <- get_keys(true)],
              ok
      end.
  
  
negative.code: 			sys:handle_system_msg(Request, From, Parent, ?MODULE, [],
                                    {State, NrOfChildren});
          %% Calls from the supervisor module.
          {'$gen_call', {To, Tag}, which_children} ->
              Children =
                  ets:foldl(
                    fun({_,Pid}, Acc) ->
                            [{vmq_queue, Pid, worker, [vmq_queue]} | Acc]
                    end,
                    [],
                    QueueTab),
              To ! {Tag, Children},
              loop(State, NrOfChildren);
          {'$gen_call', {To, Tag}, count_children} ->
              Counts =
                  [{specs, 1}, {active, NrOfChildren},
                   {supervisors, 0}, {workers, NrOfChildren}],
              To ! {Tag, Counts},
              loop(State, NrOfChildren);
          {'$gen_call', {To, Tag}, _} ->
              To ! {Tag, {error, ?MODULE}},
              loop(State, NrOfChildren);
          Msg ->
              lager:error("vmq_queue_sup received unexpected message ~p", [Msg])
      end.
  