Граф коммитов

62 Коммитов

Автор SHA1 Сообщение Дата
Robert Strong 6c7cf8b65e Bug 1502681 - Always use ProgramData\Mozilla\updates for the updates directory. r=bytesized
Changes GetCommonUpdateDirectory to always return a directory under ProgramData\Mozilla\updates on Windows
Changes getMockUpdRootDWin to always return ProgramData\Mozilla\updates for the new updates dir location
Removed code that is no longer used in getMockUpdRootDWin
Fixes a build time warning that get_relative_path is not used in updater.cpp
2018-10-29 11:21:49 -07:00
Jeff Gilbert 02e6ff5ccb Bug 1499587 - Fix win64 clang-cl -Wwritable-strings. r=ted
Differential Revision: https://phabricator.services.mozilla.com/D9031

--HG--
extra : moz-landing-system : lando
2018-10-25 14:16:27 +00:00
Kirk Steuber 19c8368ea5 Bug 1458314 - Move the update directory to an installation specific location r=rstrong
This change applies to Windows only.
Firefox will need to migrate the directory from the old location to the new location. This will be done only once by setting the pref `app.update.migrated.updateDir2.<install path hash>` to `true` once migration has completed.

Note: The pref name app.update.migrated.updateDir has already been used, thus the '2' suffix. It can be found in ESR24.

This also removes the old handling fallback for generating the update directory path. Since xulrunner is no longer supported, this should no longer be needed. If neither the vendor nor app name are defined, it falls back to the literal string "Mozilla".

The code to generate the update directory path and the installation hash have been moved to the updatecommon library. This will allow those functions to be used in Firefox, the Mozilla Maintenance Service, the Mozilla Maintenance Service Installer, and TestAUSHelper.

Additionally, the function that generates the update directory path now has extra functionality. It creates the update directory, sets the permissions on it and, optionally, recursively sets the permissions on everything within.

This patch adds functionality that allows Firefox to set permissions on the new update directory on write failure. It attempts to set the permissions itself and, if that fails and the maintenance service is enabled, it calls into the maintenance service to try from there. If a write fails and the permissions cannot be fixed, the user is prompted to reinstall.

Differential Revision: https://phabricator.services.mozilla.com/D4249

--HG--
rename : toolkit/mozapps/update/updater/win_dirent.cpp => toolkit/mozapps/update/common/win_dirent.cpp
rename : toolkit/mozapps/update/tests/unit_aus_update/cleanupSuccessLogMove.js => toolkit/mozapps/update/tests/unit_aus_update/updateDirectoryMigrate.js
extra : moz-landing-system : lando
2018-10-23 21:41:04 +00:00
Jeff Gilbert de3080c204 Bug 1499870 - Fix -Wlogical-op-parentheses. r=mhowell
Differential Revision: https://phabricator.services.mozilla.com/D9033

--HG--
extra : moz-landing-system : lando
2018-10-17 21:11:27 +00:00
Tom Ritter 7e0fefeaa0 Bug 1475566 Disable #pragma comments for MinGW Builds r=glandium
In the MinGW browser build job, we're going to use -fms-extensions,
which will tell clang to start processing these comments. Clang
cannot process them correctly (it's an upstream bug) but it doesn't
need to, because we include the libs we need in moz.build files.

So we exclude them for MinGW builds. mingw-clang gets them wrong and
mingw-gcc (which doesn't even work anymore on -central) ignored them.

In the future, with a llvm fix, we could clean up the moz.build
files and re-enable these comments.

Differential Revision: https://phabricator.services.mozilla.com/D3527

--HG--
extra : moz-landing-system : lando
2018-08-29 03:50:39 +00:00
Aaron Klotz c6740bdbdb Bug 1457999: Part 2 - Update the updater and maintenance service with changes made in part 1; r=mhowell 2018-04-19 17:23:31 -06:00
Aaron Klotz fc0ccc0ce0 Bug 1457999: Backed out changeset fc8e373f027c for Linux bustage; r=backout CLOSED TREE
--HG--
extra : histedit_source : 854dd111964c26015bfc99ae9cc2c75cfd7a182e
2018-05-07 11:21:32 -06:00
Aaron Klotz 7afbb5cc1c Bug 1457999: Part 2 - Update the updater and maintenance service with changes made in part 1; r=mhowell 2018-04-19 17:23:31 -06:00
Aaron Klotz 700a2481d1 Bug 1457999: Backed out changeset 5d72ee6c1126 due to Linux preprocessor errors; r=backout CLOSED TREE
--HG--
extra : histedit_source : 14f72513d6023289f4b19cf1349a34c386c4658b
2018-05-07 11:00:22 -06:00
Aaron Klotz f1af8f8365 Bug 1457999: Part 2 - Update the updater and maintenance service with changes made in part 1; r=mhowell
--HG--
extra : rebase_source : 2bdc418c2639323529973ecc5ab3f68b72b301ea
2018-04-19 17:23:31 -06:00
Matt Howell 6ecac8dcbe Bug 1454448 - Properly handle an allocation failure. r=rstrong
--HG--
extra : source : 2ffab631254168fa26ceddd56480b72eb936d633
2018-04-19 14:14:53 -07:00
Robert Strong 35aaed5fff Client code - Bug 1234401 - check that the patch dir subdirectory is valid. r=mhowell 2017-04-28 16:37:37 -07:00
Robert Strong 0de416e483 Client code - Bug 1342742 - check that the app update patch dir, install dir, and working dir paths are valid. r=mhowell
--HG--
rename : toolkit/mozapps/update/common/updatelogging.cpp => toolkit/mozapps/update/common/updatecommon.cpp
rename : toolkit/mozapps/update/common/updatelogging.h => toolkit/mozapps/update/common/updatecommon.h
2017-04-28 16:36:45 -07:00
Robert Strong d760090512 Bug 1336979 - Remove unnecessary logging of the update.status contents in the maintenance service. r=mhowell 2017-04-19 22:59:30 -07:00
Daniel Holbert 95a650ec1b Bug 1343975: Get rid of all dos/windows linebreaks in Mozilla C++ code. r=ehsan
This is an automated patch, generated by the following command:
find . -name "*.h" -exec fromdos {} \; && \
  find . -name "*.cpp" -exec fromdos {} \; && \
  hg revert -C gfx/angle \
               gfx/sfntly \
               media/webrtc \
               media/libstagefright \
               media/openmax_il \
               other-licenses

MozReview-Commit-ID: Gunlz3vE3h6
2017-03-02 13:08:29 -08:00
Matt Howell f80a68c7d5 Bug 1247239 - Allow the maintenance service to copy updater.exe only from the installation directory, and verify it first; r=rstrong
MozReview-Commit-ID: 68tbdamvFf0

--HG--
extra : rebase_source : 3523dd7e04ada5246cdc275ce704ede39103d8c8
2016-07-08 10:58:21 -07:00
Ryan VanderMeulen 59d32bcab0 Backed out changeset 0712c02d259e (bug 1247239) because it regressed update staging.
--HG--
extra : rebase_source : ec4834ba5bb4904f4c6037655eb69bff589faac5
2016-04-08 12:13:09 -04:00
Matt Howell b194792316 Bug 1247239 - Remove copying of updater.exe for service updates; r=rstrong
MozReview-Commit-ID: 1Nz2v1d51nk
2016-04-01 15:53:04 -07:00
Robert Strong b7924a4a24 Bug 1177861 - remove remaining unused declarations and cleanup update staging. r=spohl
--HG--
rename : toolkit/components/maintenanceservice/certificatecheck.cpp => toolkit/mozapps/update/common/certificatecheck.cpp
rename : toolkit/components/maintenanceservice/certificatecheck.h => toolkit/mozapps/update/common/certificatecheck.h
rename : toolkit/components/maintenanceservice/registrycertificates.cpp => toolkit/mozapps/update/common/registrycertificates.cpp
rename : toolkit/components/maintenanceservice/registrycertificates.h => toolkit/mozapps/update/common/registrycertificates.h
2015-08-11 14:30:35 -07:00
Robert Strong 478a8e47e2 Bug 1138282 - Extend telemetry for large number of SERVICE_STILL_APPLYING_ON_FAILURE errors. r=bbondy 2015-04-03 11:19:01 -07:00
Brian Smith 713ef86ae7 Bug 1119072, Part 14: Fix prototype of MakeCommandLine to match definition, r=rstrong
--HG--
extra : rebase_source : c75cdd915684b715a2cc70b193edd6f309b2abce
2015-01-08 15:36:24 -08:00
Robert Strong 1960e60eb0 Mac v2 signing - Bug 1072722 - With older clients the new maintenance service checks the updated directory's updater.exe when verifying the updater.exe for replace requests. r=spohl 2014-09-29 11:53:07 -07:00
Robert Strong 076224aff0 Mac v2 signing - Bug 1064523 - Create staging directory outside of the Mac bundle. r=bbondy 2014-09-29 11:52:08 -07:00
Brian R. Bondy 2175404bac Backout bug 945192 for intermittent failures. r=rstrong 2014-09-15 20:29:35 -04:00
Brian R. Bondy c581ce9932 Bug 945192. r=rstrong 2014-05-25 21:58:53 -04:00
Ehsan Akhgari 1b83407ce9 Bug 927728 - Part 1: Replace PRUnichar with char16_t; r=roc
This patch was automatically generated by the following script:

#!/bin/bash
# Command to convert PRUnichar to char16_t

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*modules/libmar*" \
       ! -wholename "*/.hg*" \
       ! -wholename "obj-ff-dbg*" \
       ! -name prtypes.h \
       ! -name Char16.h \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert PRUnichar char16_t
2014-01-04 10:02:17 -05:00
Birunthan Mohanathas 72f11bcb4b Bug 784739 - Switch from NULL to nullptr in toolkit/components/ (1/2); r=ehsan 2013-10-10 16:38:05 -04:00
Robert O'Callahan db46dd4baf Bug 898946. Avoid #including XPCOM headers within maintenanceservice. r=bbondy
--HG--
extra : rebase_source : b19663967f7af21daf8f3cf123701a79e295f4b3
2013-08-02 21:30:06 +12:00
Brian R. Bondy bcb7b85ead Bug 888361. r=rstrong 2013-07-01 19:11:52 -04:00
Brian R. Bondy d49fae1093 Bug 867056. r=rstrong 2013-05-23 13:26:44 -04:00
Brian R. Bondy 543399ef0c Bug 850492. r=rstrong. 2013-04-04 13:32:47 -04:00
Stephen Pohl ee782cf10f Bug 848417 - Use wcsncpy instead of wcscpy. r=bbondy 2013-03-07 13:41:37 -08:00
Brian R. Bondy df1c8174b6 Bug 790496 - Make maintenance service errors stand out more. r=ehsan 2012-10-25 22:34:03 -04:00
Brian R. Bondy 6e0f9911b0 Bug 789743 - Ensure bgupdates executes PostUpdate successfully. r=ehsan 2012-09-20 15:40:45 -04:00
gliuwr@gmail.com 46b4e0d157 Bug 788430 - Fix a minor bug in the MozillaMaintenanceService error handling. r=bbondy 2012-09-06 17:58:47 -04:00
Brian R. Bondy 0ab020b460 Bug 770911 - Remove all prefetch clearing code. r=taras. 2012-08-02 10:50:29 -04:00
Brian R. Bondy 67fa1f590b Bug 770899 - Prefetch clearing should be repurposed to delete 0 sized read only .pf files only. r=taras 2012-07-09 19:00:03 -04:00
Brian R. Bondy f08be271cc Bug 770883 - Disable functionality for clearing prefetch. r=taras 2012-07-06 07:41:41 -04:00
Ehsan Akhgari 51fe3d51f6 Bug 765227 - Avoid attempting to update the maintenance service when an update is being staged; r=bbondy 2012-06-18 16:06:01 -04:00
Ehsan Akhgari e52d047f9d Bug 759615 - Avoid running the PostUpdate step when only staging the update in the background; r=rstrong 2012-05-30 18:09:59 -04:00
Ehsan Akhgari 84a34d8b3f Bug 758998 - Use the correct installation directory when attempting to upgrade the maintenance service; r=bbondy 2012-05-29 17:31:04 -04:00
Brian R. Bondy 4ae600a9d9 Bug 692255 - Get rid of prefetch files on Windows for faster startup. r=rstrong 2012-05-27 22:40:48 -04:00
Ehsan Akhgari 2362f4b5ee Bug 307181 - Stage Firefox updates in the background after they're downloaded, and replace the application directory on restart; r=rstrong,bbondy
When Firefox downloads an update, it previously kept the update around to apply
it on the next restart.  This patch changes this so that the updater program
is launched in the background as soon as the update has finished downloading
in order to stage the updated version of the application by copying the
existing installation directory to a temporary location and applying the update
on top of it, and replace the existing installation directory with the staged
directory on the next restart.

Because the replacing step is typically very fast, this patch eliminates the
wait for the update to be applied on restart, making it unnecessary to show a
progress dialog when restarting.

--HG--
rename : toolkit/mozapps/update/test/chrome/test_0092_finishedBackground.xul => toolkit/mozapps/update/test/chrome/test_0093_stagedBackground.xul
rename : toolkit/mozapps/update/test/unit/test_0110_general.js => toolkit/mozapps/update/test/unit/test_0113_general.js
rename : toolkit/mozapps/update/test/unit/test_0111_general.js => toolkit/mozapps/update/test/unit/test_0114_general.js
rename : toolkit/mozapps/update/test/unit/test_0112_general.js => toolkit/mozapps/update/test/unit/test_0115_general.js
rename : toolkit/mozapps/update/test/unit/test_0170_fileLocked_xp_win_complete.js => toolkit/mozapps/update/test/unit/test_0172_fileLocked_xp_win_complete.js
rename : toolkit/mozapps/update/test/unit/test_0171_fileLocked_xp_win_partial.js => toolkit/mozapps/update/test/unit/test_0173_fileLocked_xp_win_partial.js
rename : toolkit/mozapps/update/test/unit/test_0110_general.js => toolkit/mozapps/update/test_svc/unit/test_0113_general_svc.js
rename : toolkit/mozapps/update/test/unit/test_0111_general.js => toolkit/mozapps/update/test_svc/unit/test_0114_general_svc.js
rename : toolkit/mozapps/update/test/unit/test_0112_general.js => toolkit/mozapps/update/test_svc/unit/test_0115_general_svc.js
rename : toolkit/mozapps/update/test/unit/test_0170_fileLocked_xp_win_complete.js => toolkit/mozapps/update/test_svc/unit/test_0172_fileLocked_xp_win_complete_svc.js
rename : toolkit/mozapps/update/test/unit/test_0171_fileLocked_xp_win_partial.js => toolkit/mozapps/update/test_svc/unit/test_0173_fileLocked_xp_win_partial_svc.js
2012-05-22 10:50:04 -04:00
Gervase Markham 82ff7027aa Bug 716478 - update licence to MPL 2. 2012-05-21 12:12:37 +01:00
Brian R. Bondy 7686976dbe Bug 748948 - Possible race condition when launching updates from service after security checks. r=rstrong, a=ehsan. 2012-05-02 15:40:33 -04:00
Brian R. Bondy 6eb331a4e3 Bug 748764 - LoadlibraryEx and quoted string fix for service. r=rstrong, a=ehsan. 2012-05-02 15:40:28 -04:00
Brian R. Bondy 7812985d9c Bug 711054 - Stop using readstrings errors for updater. r=rstrong
--HG--
rename : toolkit/mozapps/readstrings/errors.h => toolkit/mozapps/update/common/errors.h
rename : toolkit/mozapps/readstrings/readstrings.cpp => toolkit/mozapps/update/common/readstrings.cpp
rename : toolkit/mozapps/readstrings/readstrings.h => toolkit/mozapps/update/common/readstrings.h
2012-03-05 15:47:46 -05:00
Brian R. Bondy de905e6af5 Bug 725568 - Maintenance service can crashes after applying updates. r=rstrong 2012-02-11 17:38:37 -05:00
Brian R. Bondy 056fcab476 Bug 716126 - Include update.status contents inside maintenanceservice.log file on failed updates. r=rstrong 2012-01-10 11:28:50 -05:00
Brian R. Bondy 6829b31d89 Bug 711692 - Various fixes for intermittent failures. r=rstrong. 2011-12-28 21:08:37 -05:00