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