Ticket #11264: fix-11264.patch

File fix-11264.patch, 784 bytes (added by epilys, 6 years ago)

switch result string to NULL

  • src/or/policies.c

    From fa1bab0b4277e69366b56874514747375124195e Mon Sep 17 00:00:00 2001
    From: sycamore <el13635@mail.ntua.gr>
    Date: Sun, 27 Jul 2014 11:14:11 +0300
    Subject: [PATCH] switched policy_summarized() result to NULL if all ports
     rejected
    
    ---
     src/or/policies.c |    2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/src/or/policies.c b/src/or/policies.c
    index 8a91509..71110f6 100644
    a b policy_summarize(smartlist_t *policy, sa_family_t family) 
    13991399   * that to build the result
    14001400   */
    14011401  if (smartlist_len(accepts) == 0) { /* no exits at all */
    1402     result = tor_strdup("reject 1-65535");
     1402    result = NULL;
    14031403    goto cleanup;
    14041404  }
    14051405  if (smartlist_len(rejects) == 0) { /* no rejects at all */