Ticket #10849: 0002-fixup-TunnelDirConns-0-no-longer-breaks-hidden-servi.patch

File 0002-fixup-TunnelDirConns-0-no-longer-breaks-hidden-servi.patch, 1.4 KB (added by rransom, 5 years ago)

Pass dir_purpose to directory_command_should_use_begindir

  • src/or/directory.c

    From f12cf2537eb6a38a86b88e923c8767cdae1389a9 Mon Sep 17 00:00:00 2001
    From: Robert Ransom <rransom.8774@gmail.com>
    Date: Tue, 11 Feb 2014 22:33:25 -0800
    Subject: [PATCH 2/2] fixup! TunnelDirConns=0 no longer breaks hidden services
    
    Pass dir_purpose to directory_command_should_use_begindir
    ---
     src/or/directory.c |    4 +++-
     1 file changed, 3 insertions(+), 1 deletion(-)
    
    diff --git a/src/or/directory.c b/src/or/directory.c
    index 672bc67..72f72bd 100644
    a b static int 
    911911directory_command_should_use_begindir(const or_options_t *options,
    912912                                      const tor_addr_t *addr,
    913913                                      int or_port, uint8_t router_purpose,
     914                                      uint8_t dir_purpose,
    914915                                      dir_indirection_t indirection)
    915916{
    916917  if (!or_port)
    directory_initiate_command_rend(const char *address, const tor_addr_t *_addr, 
    981982  const or_options_t *options = get_options();
    982983  int socket_error = 0;
    983984  int use_begindir = directory_command_should_use_begindir(options, _addr,
    984                                      or_port, router_purpose, indirection);
     985                                     or_port, router_purpose, dir_purpose,
     986                                     indirection);
    985987  const int anonymized_connection = dirind_is_anon(indirection);
    986988  tor_addr_t addr;
    987989