Blame SOURCES/libproxy-0.4.11-crash.patch

12b35c
diff -up libproxy-0.4.11/libproxy/extension_pacrunner.cpp.crash libproxy-0.4.11/libproxy/extension_pacrunner.cpp
12b35c
--- libproxy-0.4.11/libproxy/extension_pacrunner.cpp.crash	2010-07-29 08:14:59.000000000 -0400
12b35c
+++ libproxy-0.4.11/libproxy/extension_pacrunner.cpp	2013-11-11 15:23:56.987266457 -0500
12b35c
@@ -22,20 +22,10 @@ using namespace libproxy;
12b35c
 
12b35c
 pacrunner::pacrunner(string, const url&) {}
12b35c
 
12b35c
-pacrunner_extension::pacrunner_extension() {
12b35c
-	this->pr = NULL;
12b35c
-}
12b35c
+pacrunner_extension::pacrunner_extension() {}
12b35c
 
12b35c
-pacrunner_extension::~pacrunner_extension() {
12b35c
-	if (this->pr) delete this->pr;
12b35c
-}
12b35c
+pacrunner_extension::~pacrunner_extension() {}
12b35c
 
12b35c
 pacrunner* pacrunner_extension::get(string pac, const url& pacurl) throw (bad_alloc) {
12b35c
-	if (this->pr) {
12b35c
-		if (this->last == pac)
12b35c
-			return this->pr;
12b35c
-		delete this->pr;
12b35c
-	}
12b35c
-
12b35c
-	return this->pr = this->create(pac, pacurl);
12b35c
+	return this->create(pac, pacurl);
12b35c
 }
12b35c
diff -up libproxy-0.4.11/libproxy/proxy.cpp.crash libproxy-0.4.11/libproxy/proxy.cpp
12b35c
--- libproxy-0.4.11/libproxy/proxy.cpp.crash	2013-11-11 15:25:27.309271353 -0500
12b35c
+++ libproxy-0.4.11/libproxy/proxy.cpp	2013-11-11 15:25:31.569271584 -0500
12b35c
@@ -416,7 +416,9 @@ void proxy_factory::run_pac(url &realurl
12b35c
 
12b35c
 		/* Run the PAC, but only try one PACRunner */
12b35c
 		if (debug) cerr << "Using pacrunner: " << typeid(*pacrunners[0]).name() << endl;
12b35c
-		string pacresp = pacrunners[0]->get(this->pac, this->pacurl->to_string())->run(realurl);
12b35c
+		pacrunner* runner = pacrunners[0]->get(this->pac, this->pacurl->to_string());
12b35c
+		string pacresp = runner->run(realurl);
12b35c
+		delete runner;
12b35c
 		if (debug) cerr << "Pacrunner returned: " << pacresp << endl;
12b35c
 		format_pac_response(pacresp, response);
12b35c
 	}