[tor-commits] [flashproxy/master] First cookie value wins, like parse_query_string.

dcf at torproject.org dcf at torproject.org
Fri Dec 28 14:13:54 UTC 2012


commit a41614bf46ad4093c448f891f6f9a2174539c33c
Author: David Fifield <david at bamsoftware.com>
Date:   Mon Dec 24 18:03:28 2012 -0800

    First cookie value wins, like parse_query_string.
---
 proxy/flashproxy.js |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/proxy/flashproxy.js b/proxy/flashproxy.js
index 86ecfab..caa3a31 100644
--- a/proxy/flashproxy.js
+++ b/proxy/flashproxy.js
@@ -121,7 +121,8 @@ function parse_cookie_string(cookies) {
         name = string.substr(0, j).trim();
         value = string.substr(j + 1).trim();
 
-        result[name] = value;
+        if (!(name in result))
+             result[name] = value;
     }
 
     return result;





More information about the tor-commits mailing list