Added patches for mozbz#1427700 and mozbz#1463809
This commit is contained in:
parent
54a2ce11f0
commit
35295a20e5
@ -103,7 +103,7 @@
|
||||
Summary: Mozilla Firefox Web browser
|
||||
Name: firefox
|
||||
Version: 61.0.2
|
||||
Release: 2%{?pre_tag}%{?dist}
|
||||
Release: 3%{?pre_tag}%{?dist}
|
||||
URL: https://www.mozilla.org/firefox/
|
||||
License: MPLv1.1 or GPLv2+ or LGPLv2+
|
||||
Source0: https://hg.mozilla.org/releases/mozilla-release/archive/firefox-%{version}%{?pre_version}.source.tar.xz
|
||||
@ -160,6 +160,8 @@ Patch415: Bug-1238661---fix-mozillaSignalTrampoline-to-work-.patch
|
||||
Patch416: mozilla-1424422.patch
|
||||
Patch417: bug1375074-save-restore-x28.patch
|
||||
Patch418: mozilla-1436242.patch
|
||||
Patch419: rb244676.patch
|
||||
Patch420: rb246462.patch
|
||||
|
||||
Patch421: complete-csd-window-offset-mozilla-1457691.patch
|
||||
|
||||
@ -369,6 +371,8 @@ This package contains results of tests executed during build.
|
||||
#%patch416 -p1 -b .1424422
|
||||
#%patch417 -p1 -b .bug1375074-save-restore-x28
|
||||
%patch418 -p1 -b .mozilla-1436242
|
||||
%patch419 -p1 -b .rb244676
|
||||
%patch420 -p1 -b .rb246462
|
||||
|
||||
#%patch421 -p1 -b .mozilla-1457691
|
||||
|
||||
@ -932,6 +936,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
|
||||
#---------------------------------------------------------------------
|
||||
|
||||
%changelog
|
||||
* Wed Aug 15 2018 Ondrej Zoder <ozoder@redhat.com> - 61.0.2-3
|
||||
- Added patches for mozbz#1427700 and mozbz#1463809
|
||||
|
||||
* Mon Aug 13 2018 Ondrej Zoder <ozoder@redhat.com> - 61.0.2-2
|
||||
- Updated symbolic icon
|
||||
|
||||
|
27
rb244676.patch
Normal file
27
rb244676.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff --git a/toolkit/system/gnome/nsGIOService.cpp b/toolkit/system/gnome/nsGIOService.cpp
|
||||
--- a/toolkit/system/gnome/nsGIOService.cpp
|
||||
+++ b/toolkit/system/gnome/nsGIOService.cpp
|
||||
@@ -521,16 +521,22 @@ nsGIOService::GetAppForMimeType(const ns
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
char *content_type =
|
||||
g_content_type_from_mime_type(PromiseFlatCString(aMimeType).get());
|
||||
if (!content_type)
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
+ // GIO returns "unknown" appinfo for the application/octet-stream, which is
|
||||
+ // useless. It's better to fallback to create appinfo from file extension later.
|
||||
+ if (g_content_type_is_unknown(content_type)) {
|
||||
+ return NS_ERROR_NOT_AVAILABLE;
|
||||
+ }
|
||||
+
|
||||
GAppInfo *app_info = g_app_info_get_default_for_type(content_type, false);
|
||||
if (app_info) {
|
||||
nsGIOMimeApp *mozApp = new nsGIOMimeApp(app_info);
|
||||
NS_ENSURE_TRUE(mozApp, NS_ERROR_OUT_OF_MEMORY);
|
||||
NS_ADDREF(*aApp = mozApp);
|
||||
} else {
|
||||
g_free(content_type);
|
||||
return NS_ERROR_FAILURE;
|
||||
|
80
rb246462.patch
Normal file
80
rb246462.patch
Normal file
@ -0,0 +1,80 @@
|
||||
diff --git a/uriloader/exthandler/nsExternalHelperAppService.cpp b/uriloader/exthandler/nsExternalHelperAppService.cpp
|
||||
--- a/uriloader/exthandler/nsExternalHelperAppService.cpp
|
||||
+++ b/uriloader/exthandler/nsExternalHelperAppService.cpp
|
||||
@@ -2590,26 +2590,21 @@ NS_IMETHODIMP nsExternalHelperAppService
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// (3) No match yet. Ask extras.
|
||||
if (!found) {
|
||||
rv = NS_ERROR_FAILURE;
|
||||
-#ifdef XP_WIN
|
||||
- /* XXX Gross hack to wallpaper over the most common Win32
|
||||
- * extension issues caused by the fix for bug 116938. See bug
|
||||
- * 120327, comment 271 for why this is needed. Not even sure we
|
||||
- * want to remove this once we have fixed all this stuff to work
|
||||
- * right; any info we get from extras on this type is pretty much
|
||||
- * useless....
|
||||
- */
|
||||
+ // Getting info for application/octet-stream content-type from extras
|
||||
+ // does not make a sense because this tends to open all octet-streams
|
||||
+ // as Binary file with exe, com or bin extension regardless the real
|
||||
+ // extension.
|
||||
if (!typeToUse.Equals(APPLICATION_OCTET_STREAM, nsCaseInsensitiveCStringComparator()))
|
||||
-#endif
|
||||
rv = FillMIMEInfoForMimeTypeFromExtras(typeToUse, *_retval);
|
||||
LOG(("Searched extras (by type), rv 0x%08" PRIX32 "\n", static_cast<uint32_t>(rv)));
|
||||
// If that didn't work out, try file extension from extras
|
||||
if (NS_FAILED(rv) && !aFileExt.IsEmpty()) {
|
||||
rv = FillMIMEInfoForExtensionFromExtras(aFileExt, *_retval);
|
||||
LOG(("Searched extras (by ext), rv 0x%08" PRIX32 "\n", static_cast<uint32_t>(rv)));
|
||||
}
|
||||
// If that still didn't work, set the file description to "ext File"
|
||||
diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
|
||||
--- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp
|
||||
+++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
|
||||
@@ -26,16 +26,17 @@
|
||||
#include "nsISupportsPrimitives.h"
|
||||
#include "nsCRT.h"
|
||||
#include "nsDirectoryServiceDefs.h"
|
||||
#include "nsDirectoryServiceUtils.h"
|
||||
#include "ContentHandlerService.h"
|
||||
#include "prenv.h" // for PR_GetEnv()
|
||||
#include "nsAutoPtr.h"
|
||||
#include "mozilla/Preferences.h"
|
||||
+#include "nsMimeTypes.h"
|
||||
|
||||
using namespace mozilla;
|
||||
|
||||
#define LOG(args) MOZ_LOG(mLog, mozilla::LogLevel::Debug, args)
|
||||
#define LOG_ENABLED() MOZ_LOG_TEST(mLog, mozilla::LogLevel::Debug)
|
||||
|
||||
static nsresult
|
||||
FindSemicolon(nsAString::const_iterator& aSemicolon_iter,
|
||||
@@ -1445,17 +1446,22 @@ nsOSHelperAppService::GetFromType(const
|
||||
}
|
||||
|
||||
|
||||
already_AddRefed<nsIMIMEInfo>
|
||||
nsOSHelperAppService::GetMIMEInfoFromOS(const nsACString& aType,
|
||||
const nsACString& aFileExt,
|
||||
bool *aFound) {
|
||||
*aFound = true;
|
||||
- RefPtr<nsMIMEInfoBase> retval = GetFromType(PromiseFlatCString(aType));
|
||||
+ RefPtr<nsMIMEInfoBase> retval;
|
||||
+ // Fallback to lookup by extension when generic 'application/octet-stream'
|
||||
+ // content type is received.
|
||||
+ if (!aType.EqualsLiteral(APPLICATION_OCTET_STREAM)) {
|
||||
+ retval = GetFromType(PromiseFlatCString(aType));
|
||||
+ }
|
||||
bool hasDefault = false;
|
||||
if (retval)
|
||||
retval->GetHasDefaultHandler(&hasDefault);
|
||||
if (!retval || !hasDefault) {
|
||||
RefPtr<nsMIMEInfoBase> miByExt = GetFromExtension(PromiseFlatCString(aFileExt));
|
||||
// If we had no extension match, but a type match, use that
|
||||
if (!miByExt && retval)
|
||||
return retval.forget();
|
||||
|
Loading…
Reference in New Issue
Block a user