cancel
Showing results for 
Search instead for 
Did you mean: 

PATCH 8788. Hunk #1 FAILED at 373.

PATCH 8788. Hunk #1 FAILED at 373.

Hello,

i tried to apply the Patch 8788. But it does not work. Here is the log of the patch:

 

Checking if patch can be applied/reverted successfully...
ERROR: Patch can't be applied/reverted successfully.

patching file app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php
patching file app/code/core/Mage/Adminhtml/Block/Cms/Wysiwyg/Images/Content/Uploader.php
patching file app/code/core/Mage/Adminhtml/Block/Media/Uploader.php
patching file app/code/core/Mage/Adminhtml/Block/Urlrewrite/Category/Tree.php
patching file app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Serialized.php
patching file app/code/core/Mage/Adminhtml/controllers/DashboardController.php
patching file app/code/core/Mage/Adminhtml/controllers/IndexController.php
patching file app/code/core/Mage/Adminhtml/controllers/Media/UploaderController.php
patching file app/code/core/Mage/Catalog/Helper/Image.php
patching file app/code/core/Mage/Catalog/etc/config.xml
patching file app/code/core/Mage/Catalog/etc/system.xml
patching file app/code/core/Mage/Centinel/Model/Api.php
patching file app/code/core/Mage/Centinel/Model/Api/Client.php
patching file app/code/core/Mage/Core/Block/Abstract.php
patching file app/code/core/Mage/Core/Helper/Url.php
patching file app/code/core/Mage/Core/Model/Encryption.php
patching file app/code/core/Mage/Core/Model/Input/Filter/MaliciousCode.php
patching file app/code/core/Mage/Core/functions.php
patching file app/code/core/Mage/Customer/Block/Address/Book.php
patching file app/code/core/Mage/Customer/controllers/AddressController.php
patching file app/code/core/Mage/Dataflow/Model/Profile.php
patching file app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php
patching file app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php
patching file app/code/core/Mage/Downloadable/Helper/File.php
patching file app/code/core/Mage/Oauth/Model/Server.php
patching file app/code/core/Mage/Paygate/Model/Authorizenet.php
patching file app/code/core/Mage/Payment/Block/Info/Checkmo.php
patching file app/code/core/Mage/Paypal/Model/Express/Checkout.php
patching file app/code/core/Mage/Paypal/Model/Resource/Payment/Transaction.php
patching file app/code/core/Mage/Sales/Model/Resource/Order/Payment.php
patching file app/code/core/Mage/Sales/Model/Resource/Order/Payment/Transaction.php
patching file app/code/core/Mage/Sales/Model/Resource/Quote/Payment.php
patching file app/code/core/Mage/Sales/Model/Resource/Recurring/Profile.php
patching file app/code/core/Mage/Uploader/Block/Abstract.php
patching file app/code/core/Mage/Uploader/Block/Multiple.php
patching file app/code/core/Mage/Uploader/Block/Single.php
patching file app/code/core/Mage/Uploader/Helper/Data.php
patching file app/code/core/Mage/Uploader/Helper/File.php
patching file app/code/core/Mage/Uploader/Model/Config/Abstract.php
patching file app/code/core/Mage/Uploader/Model/Config/Browsebutton.php
patching file app/code/core/Mage/Uploader/Model/Config/Misc.php
patching file app/code/core/Mage/Uploader/Model/Config/Uploader.php
patching file app/code/core/Mage/Uploader/etc/config.xml
patching file app/code/core/Mage/Uploader/etc/jstranslator.xml
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Dhl.php
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Dhl/International.php
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Fedex.php
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Ups.php
patching file app/code/core/Mage/Usa/etc/config.xml
patching file app/code/core/Mage/Usa/etc/system.xml
patching file app/code/core/Mage/Wishlist/Helper/Data.php
patching file app/code/core/Mage/Wishlist/controllers/IndexController.php
patching file app/code/core/Mage/XmlConnect/Block/Adminhtml/Mobile/Edit/Tab/Design.php
patching file app/code/core/Mage/XmlConnect/Block/Adminhtml/Mobile/Edit/Tab/Design/Images.php
patching file app/code/core/Mage/XmlConnect/controllers/Adminhtml/MobileController.php
patching file app/design/adminhtml/default/default/layout/cms.xml
patching file app/design/adminhtml/default/default/layout/main.xml
patching file app/design/adminhtml/default/default/layout/xmlconnect.xml
patching file app/design/adminhtml/default/default/template/catalog/product/helper/gallery.phtml
patching file app/design/adminhtml/default/default/template/cms/browser/content/uploader.phtml
patching file app/design/adminhtml/default/default/template/downloadable/product/edit/downloadable.phtml
patching file app/design/adminhtml/default/default/template/downloadable/product/edit/downloadable/links.phtml
patching file app/design/adminhtml/default/default/template/downloadable/product/edit/downloadable/samples.phtml
patching file app/design/adminhtml/default/default/template/media/uploader.phtml
patching file app/design/adminhtml/default/default/template/xmlconnect/edit/tab/design.phtml
patching file app/etc/modules/Mage_All.xml
patching file app/locale/en_US/Mage_Media.csv
patching file app/locale/en_US/Mage_Uploader.csv
patching file downloader/lib/Mage/HTTP/Client/Curl.php
Hunk #1 FAILED at 373.
1 out of 1 hunk FAILED -- saving rejects to file downloader/lib/Mage/HTTP/Client/Curl.php.rej
patching file js/lib/uploader/flow.min.js
patching file js/lib/uploader/fusty-flow-factory.js
patching file js/lib/uploader/fusty-flow.js
patching file js/mage/adminhtml/product.js
patching file js/mage/adminhtml/uploader/instance.js
patching file skin/adminhtml/default/default/boxes.css
patching file skin/adminhtml/default/default/media/flex.swf
patching file skin/adminhtml/default/default/media/uploader.swf
patching file skin/adminhtml/default/default/media/uploaderSingle.swf
Reversed (or previously applied) patch detected!  Assume -R? [n]
Apply anyway? [n]
Skipping patch.
1 out of 1 hunk ignored -- saving rejects to file skin/adminhtml/default/default/media/uploaderSingle.swf.rej
patching file skin/adminhtml/default/default/xmlconnect/boxes.css

  Does someone know how to fix this issue?

We are using CE1.9.2.0

Thanks at all!

7 REPLIES 7

Re: PATCH 8788. Hunk #1 FAILED at 373.

Hi @MKpalazzo

 

Do you have downloader folder available in the Magento root?

If no then from the copy the downloader folder supplied with the default Magento 1.9.2.0 and try to apply the patch.

---
Problem Solved Click Accept as Solution!:Magento Community India Forum

Re: PATCH 8788. Hunk #1 FAILED at 373.

Yeah downlaoder folder is available. Also the file with the the correct path and permissions is available. Dont know where the problem actually is.

Re: PATCH 8788. Hunk #1 FAILED at 373.

Hi i have the magento 1.9.2.4 and i receive this message, why?

 

sh PATCH_SUPEE-8788_CE_1.9.2.4_v1-2016-10-11-07-03-46.shChecking if patch can be applied/reverted successfully...


ERROR: Patch can't be applied/reverted successfully.


patching file app/code/core/Mage/Adminhtml/Block/Catalog/Product/Helper/Form/Gallery/Content.php
patching file app/code/core/Mage/Adminhtml/Block/Cms/Wysiwyg/Images/Content/Uploader.php
patching file app/code/core/Mage/Adminhtml/Block/Media/Uploader.php
patching file app/code/core/Mage/Adminhtml/Block/Urlrewrite/Category/Tree.php
patching file app/code/core/Mage/Adminhtml/Model/System/Config/Backend/Serialized.php
patching file app/code/core/Mage/Adminhtml/controllers/DashboardController.php
patching file app/code/core/Mage/Adminhtml/controllers/IndexController.php
patching file app/code/core/Mage/Adminhtml/controllers/Media/UploaderController.php
patching file app/code/core/Mage/Catalog/Helper/Image.php
patching file app/code/core/Mage/Catalog/etc/config.xml
patching file app/code/core/Mage/Catalog/etc/system.xml
patching file app/code/core/Mage/Centinel/Model/Api.php
patching file app/code/core/Mage/Centinel/Model/Api/Client.php
patching file app/code/core/Mage/Core/Block/Abstract.php
patching file app/code/core/Mage/Core/Helper/Url.php
patching file app/code/core/Mage/Core/Model/Encryption.php
patching file app/code/core/Mage/Core/Model/Input/Filter/MaliciousCode.php
patching file app/code/core/Mage/Core/functions.php
patching file app/code/core/Mage/Customer/Block/Address/Book.php
patching file app/code/core/Mage/Customer/controllers/AddressController.php
patching file app/code/core/Mage/Dataflow/Model/Profile.php
patching file app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php
patching file app/code/core/Mage/Downloadable/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php
patching file app/code/core/Mage/Downloadable/Helper/File.php
patching file app/code/core/Mage/Oauth/Model/Server.php
patching file app/code/core/Mage/Paygate/Model/Authorizenet.php
patching file app/code/core/Mage/Payment/Block/Info/Checkmo.php
patching file app/code/core/Mage/Paypal/Model/Express/Checkout.php
patching file app/code/core/Mage/Paypal/Model/Resource/Payment/Transaction.php
patching file app/code/core/Mage/Sales/Model/Resource/Order/Payment.php
patching file app/code/core/Mage/Sales/Model/Resource/Order/Payment/Transaction.php
patching file app/code/core/Mage/Sales/Model/Resource/Quote/Payment.php
patching file app/code/core/Mage/Sales/Model/Resource/Recurring/Profile.php
patching file app/code/core/Mage/Uploader/Block/Abstract.php
patching file app/code/core/Mage/Uploader/Block/Multiple.php
patching file app/code/core/Mage/Uploader/Block/Single.php
patching file app/code/core/Mage/Uploader/Helper/Data.php
patching file app/code/core/Mage/Uploader/Helper/File.php
patching file app/code/core/Mage/Uploader/Model/Config/Abstract.php
patching file app/code/core/Mage/Uploader/Model/Config/Browsebutton.php
patching file app/code/core/Mage/Uploader/Model/Config/Misc.php
patching file app/code/core/Mage/Uploader/Model/Config/Uploader.php
patching file app/code/core/Mage/Uploader/etc/config.xml
patching file app/code/core/Mage/Uploader/etc/jstranslator.xml
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Dhl.php
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Dhl/International.php
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Fedex.php
patching file app/code/core/Mage/Usa/Model/Shipping/Carrier/Ups.php
patching file app/code/core/Mage/Usa/etc/config.xml
patching file app/code/core/Mage/Usa/etc/system.xml
patching file app/code/core/Mage/Wishlist/Helper/Data.php
patching file app/code/core/Mage/Wishlist/controllers/IndexController.php
patching file app/code/core/Mage/XmlConnect/Block/Adminhtml/Mobile/Edit/Tab/Design.php
patching file app/code/core/Mage/XmlConnect/Block/Adminhtml/Mobile/Edit/Tab/Design/Images.php
patching file app/code/core/Mage/XmlConnect/controllers/Adminhtml/MobileController.php
patching file app/design/adminhtml/default/default/layout/cms.xml
patching file app/design/adminhtml/default/default/layout/main.xml
patching file app/design/adminhtml/default/default/layout/xmlconnect.xml
patching file app/design/adminhtml/default/default/template/catalog/product/helper/gallery.phtml
patching file app/design/adminhtml/default/default/template/cms/browser/content/uploader.phtml
patching file app/design/adminhtml/default/default/template/downloadable/product/edit/downloadable.phtml
patching file app/design/adminhtml/default/default/template/downloadable/product/edit/downloadable/links.phtml
patching file app/design/adminhtml/default/default/template/downloadable/product/edit/downloadable/samples.phtml
patching file app/design/adminhtml/default/default/template/media/uploader.phtml
patching file app/design/adminhtml/default/default/template/xmlconnect/edit/tab/design.phtml
patching file app/etc/modules/Mage_All.xml
patching file app/locale/en_US/Mage_Media.csv
patching file app/locale/en_US/Mage_Uploader.csv
patching file downloader/lib/Mage/HTTP/Client/Curl.php
Hunk #1 FAILED at 373.
1 out of 1 hunk FAILED -- saving rejects to file downloader/lib/Mage/HTTP/Client/Curl.php.rej
patching file js/lib/uploader/flow.min.js
patching file js/lib/uploader/fusty-flow-factory.js
patching file js/lib/uploader/fusty-flow.js
patching file js/mage/adminhtml/product.js
patching file js/mage/adminhtml/uploader/instance.js
patching file skin/adminhtml/default/default/boxes.css
patching file skin/adminhtml/default/default/media/flex.swf
patching file skin/adminhtml/default/default/media/uploader.swf
patching file skin/adminhtml/default/default/media/uploaderSingle.swf
patching file skin/adminhtml/default/default/xmlconnect/boxes.css

Re: PATCH 8788. Hunk #1 FAILED at 373.

I resolved this very simple

 

In file downloader/lib/Mage/HTTP/Client/Curl.php I changed the code

$this->curlOption(CURLOPT_SSL_CIPHER_LIST, 'TLSv1');

 

to

 

if(isset($var)){ $this->curlOption(CURLOPT_SSL_CIPHER_LIST, 'TLSv1'); }

 

and problem will be solved for now.

http://magento.stackexchange.com/questions/73748/magento-1-9-2-unknown-cipher-in-list-tlsv1/73957#73...

 

Eu consegui resolver assim:

Na epoca estava tentando instalar um plugin, mas o sistema não estava permitindo.

Lendo posts eu alterei o Curl.php, para que ele pudesse se conectar e instalar plugins..

 

Bom como eu ja tive o site derrubado 2 vezes esse tipo de instalação de path e a melhor forma para se previnir contra ataques.

 

Estou estudando para ver como devo migrar da plataforma 1.x para a 2x

Heart

Re: PATCH 8788. Hunk #1 FAILED at 373.

getting a new copy from a fresh 1.9.2.0 fixed it for me. But after patching i got next Problem. The Amdin Page keeps blank and shows:

Fatal error: Class 'Unserialize_Reader_Null' not found in ***/lib/Unserialize/Reader/Arr.php on line 105

Someone know why?

 

cleared cache (Magento var/cache/)
browser cache
cookies

 

Thanks !

Re: PATCH 8788. Hunk #1 FAILED at 373.

Can anyone else verify that this has worked for them with v2 of the 8788 patch?

 

In file downloader/lib/Mage/HTTP/Client/Curl.php I changed the code

$this->curlOption(CURLOPT_SSL_CIPHER_LIST, 'TLSv1');

 

to

 

if(isset($var)){ $this->curlOption(CURLOPT_SSL_CIPHER_LIST, 'TLSv1'); }

Re: PATCH 8788. Hunk #1 FAILED at 373.

The above fix most likely on fixed the poster's particular issue. Below is an explanation of what the patch is doing with the Curl.php file, FOLLOW THE BELOW ONLY IF YOU KNOW WHAT YOU ARE DOING. I had the same error "Hunk #1 FAILED at 373", and this was the only error for me while applying this patch. I am running CE 1.9.2.3

 

If you open the .sh patch in a text editor, I can see that it is looking for the below section of code in Curl.php that looks EXACTLY like the below so that it can delete one line and replace it with another line (that is what the + and the - on the left side of the file means).

 

diff --git downloader/lib/Mage/HTTP/Client/Curl.php downloader/lib/Mage/HTTP/Client/Curl.php
index 7c2773b..ed96236 100644
--- downloader/lib/Mage/HTTP/Client/Curl.php
+++ downloader/lib/Mage/HTTP/Client/Curl.php
@@ -373,7 +373,7 @@ implements Mage_HTTP_IClient
         $uriModified = $this->getModifiedUri($uri, $https);
         $this->_ch = curl_init();
         $this->curlOption(CURLOPT_URL, $uriModified);
-        $this->curlOption(CURLOPT_SSL_VERIFYPEER, false);
+        $this->curlOption(CURLOPT_SSL_VERIFYPEER, true);
         $this->curlOption(CURLOPT_SSL_CIPHER_LIST, 'TLSv1');
         $this->getCurlMethodSettings($method, $params, $isAuthorizationRequired);

So, the patch is replacing this:

$this->curlOption(CURLOPT_SSL_VERIFYPEER, false);

with this:

$this->curlOption(CURLOPT_SSL_VERIFYPEER, true);

And the patch is written such that it must find the EXACT SAME LINES before and after the changed line. So, somehow your Curl.php got changed along the way (maybe a bad hack to make a particular payment gateway work.) So, if you want the patch to apply, go and make a backup copy of your downloader/lib/Mage/HTTP/Client/Curl.php file, then open the original, and find the above-referenced section, change it to look exactly like what the patch is looking for:

$uriModified = $this->getModifiedUri($uri, $https);
         $this->_ch = curl_init();
         $this->curlOption(CURLOPT_URL, $uriModified);
         $this->curlOption(CURLOPT_SSL_VERIFYPEER, false);
         $this->curlOption(CURLOPT_SSL_CIPHER_LIST, 'TLSv1');
         $this->getCurlMethodSettings($method, $params, $isAuthorizationRequired);

Save the file, and then re-run the patch and see if it succeeds. Then figure out if any Curl commands for your site have stopped working because you changed what was in this file from what the original was. Especially check any payment gateways and see if they are still working.